# Path: pyvx/types.py
# SCALE_PYRAMID_HALF = 0.5
# SCALE_PYRAMID_ORB = 0.8408964
# FMT_REF = ffi.string(lib._get_FMT_REF())
# FMT_SIZE = ffi.string(lib._get_FMT_SIZE())
# def KERNEL_BASE(vendor, libid):
# def imagepatch_addressing_t(dim_x=0, dim_y=0, stride_x=0, stride_y=0, scale_x=0, scale_y=0, step_x=0, step_y=0):
# def perf_t(tmp=0, beg=0, end=0, sum=0, avg=0, min=0, num=0, max=0):
# def kernel_info_t(enumeration, name):
# def border_mode_t(mode, constant_value=0):
# def keypoint_t(x, y, strength, scale, orientation, tracking_status, error):
# def rectangle_t(start_x, start_y, end_x, end_y):
# def delta_rectangle_t(delta_start_x, delta_start_y, delta_end_x, delta_end_y):
# def coordinates2d_t(x, y):
# def coordinates3d_t(x, y, z):
# 
# Path: pyvx/types.py
# SCALE_PYRAMID_HALF = 0.5
# SCALE_PYRAMID_ORB = 0.8408964
# FMT_REF = ffi.string(lib._get_FMT_REF())
# FMT_SIZE = ffi.string(lib._get_FMT_SIZE())
# def KERNEL_BASE(vendor, libid):
# def imagepatch_addressing_t(dim_x=0, dim_y=0, stride_x=0, stride_y=0, scale_x=0, scale_y=0, step_x=0, step_y=0):
# def perf_t(tmp=0, beg=0, end=0, sum=0, avg=0, min=0, num=0, max=0):
# def kernel_info_t(enumeration, name):
# def border_mode_t(mode, constant_value=0):
# def keypoint_t(x, y, strength, scale, orientation, tracking_status, error):
# def rectangle_t(start_x, start_y, end_x, end_y):
# def delta_rectangle_t(delta_start_x, delta_start_y, delta_end_x, delta_end_y):
# def coordinates2d_t(x, y):
# def coordinates3d_t(x, y, z):


from pyvx.inc import vx
from pyvx.types import VxError
from pyvx import types
    from pyvx.optimized_backend import Context
    import traceback
            fn.apis = []
        fn.apis.append(self)
        return fn


class capi(object):

    def __init__(self, cdecl):
        self.cdecl = cdecl

    def __call__(self, fn):
        if not hasattr(fn, 'capis'):
            fn.capis = []
        fn.capis.append(self)
        return fn

##############################################################################


class Reference(VxObject):
    _type = vx.TYPE_REFERENCE

    count = attribute(vx.REF_ATTRIBUTE_COUNT, vx.TYPE_UINT32, 1)
    type = attribute(vx.REF_ATTRIBUTE_TYPE, vx.TYPE_ENUM, vx.TYPE_REFERENCE)

    def query(self, attribute): # xxx: move implementation to backend
        try:
            return getattr(self, self._attributes[attribute].name)
        except KeyError:
            msg = 'Attribute %s does not exist' % attribute

# Path: pyvx/types.py
# SCALE_PYRAMID_HALF = 0.5
# SCALE_PYRAMID_ORB = 0.8408964
# FMT_REF = ffi.string(lib._get_FMT_REF())
# FMT_SIZE = ffi.string(lib._get_FMT_SIZE())
# def KERNEL_BASE(vendor, libid):
# def imagepatch_addressing_t(dim_x=0, dim_y=0, stride_x=0, stride_y=0, scale_x=0, scale_y=0, step_x=0, step_y=0):
# def perf_t(tmp=0, beg=0, end=0, sum=0, avg=0, min=0, num=0, max=0):
# def kernel_info_t(enumeration, name):
# def border_mode_t(mode, constant_value=0):
# def keypoint_t(x, y, strength, scale, orientation, tracking_status, error):
# def rectangle_t(start_x, start_y, end_x, end_y):
# def delta_rectangle_t(delta_start_x, delta_start_y, delta_end_x, delta_end_y):
# def coordinates2d_t(x, y):
# def coordinates3d_t(x, y, z):
# 
# Path: pyvx/types.py
# SCALE_PYRAMID_HALF = 0.5
# SCALE_PYRAMID_ORB = 0.8408964
# FMT_REF = ffi.string(lib._get_FMT_REF())
# FMT_SIZE = ffi.string(lib._get_FMT_SIZE())
# def KERNEL_BASE(vendor, libid):
# def imagepatch_addressing_t(dim_x=0, dim_y=0, stride_x=0, stride_y=0, scale_x=0, scale_y=0, step_x=0, step_y=0):
# def perf_t(tmp=0, beg=0, end=0, sum=0, avg=0, min=0, num=0, max=0):
# def kernel_info_t(enumeration, name):
# def border_mode_t(mode, constant_value=0):
# def keypoint_t(x, y, strength, scale, orientation, tracking_status, error):
# def rectangle_t(start_x, start_y, end_x, end_y):
# def delta_rectangle_t(delta_start_x, delta_start_y, delta_end_x, delta_end_y):
# def coordinates2d_t(x, y):
# def coordinates3d_t(x, y, z):


# Path: old/pyvx/model.py
from pyvx.inc import vx
from pyvx.types import VxError
from pyvx import types
    from pyvx.optimized_backend import Context
    import traceback

            fn.apis = []
        fn.apis.append(self)
        return fn


class capi(object):

    def __init__(self, cdecl):
        self.cdecl = cdecl

    def __call__(self, fn):
        if not hasattr(fn, 'capis'):
            fn.capis = []
        fn.capis.append(self)
        return fn

##############################################################################


class Reference(VxObject):
    _type = vx.TYPE_REFERENCE

    count = attribute(vx.REF_ATTRIBUTE_COUNT, vx.TYPE_UINT32, 1)
    type = attribute(vx.REF_ATTRIBUTE_TYPE, vx.TYPE_ENUM, vx.TYPE_REFERENCE)

    def query(self, attribute): # xxx: move implementation to backend
        try:
            return getattr(self, self._attributes[attribute].name)
        except KeyError:
            msg = 'Attribute %s does not exist' % attribute

            raise types.InvalidParametersError(msg, self)