# theRNG z = sb.mb.free_fun('theRNG') z.include() z.call_policies = CP.return_value_policy(CP.reference_existing_object) # fillConvexPoly z = sb.mb.free_fun('fillConvexPoly') z.include() z._transformer_creators.append(FT.input_array1d('pts', 'npts')) # fillPoly for t in ('fillPoly', 'polylines'): z = sb.mb.free_fun(t) z.include() z._transformer_creators.append(FT.input_array2d('pts', 'npts', 'ncontours')) z._transformer_kwds['alias'] = t # getTextSize z = sb.mb.free_fun('getTextSize') z.include() z._transformer_creators.append(FT.output_type1('baseLine')) # MemStorage -- exposed in cxtypes_h_gen # cvCreateMemStorage sb.mb.free_fun('cvCreateMemStorage').exclude() sb.mb.add_declaration_code(''' cv::MemStorage createMemStorage(int block_size CV_DEFAULT(0)) { return cv::MemStorage(cvCreateMemStorage(block_size));
transformer_creators=[FT.arg_output('lines')]) # getOptimalNewCameraMatrix FT.expose_func(sb.mb.free_fun('getOptimalNewCameraMatrix'), return_pointee=False, transformer_creators=[FT.output_type1('validPixROI')]) # calcHist for z in sb.mb.free_funs('calcHist'): FT.expose_func(z, return_pointee=False, transformer_creators=[ FT.input_array1d('images', 'nimages'), FT.input_array1d('channels'), FT.input_array1d('histSize', 'dims'), FT.input_array2d('ranges') ]) z._transformer_kwds['alias'] = 'calcHist' # calcBackProject for z in sb.mb.free_funs('calcBackProject'): FT.expose_func(z, return_pointee=False, transformer_creators=[ FT.input_array1d('images', 'nimages'), FT.input_array1d('channels'), FT.input_array2d('ranges') ]) z._transformer_kwds['alias'] = 'calcBackProject' # floodFill
FT.expose_func(sb.mb.free_fun('HoughCircles'), return_pointee=False, transformer_creators=[FT.arg_output('circles')]) FT.expose_func(sb.mb.free_fun('HoughLines'), return_pointee=False, transformer_creators=[FT.arg_output('lines')]) FT.expose_func(sb.mb.free_fun('HoughLinesP'), return_pointee=False, transformer_creators=[FT.arg_output('lines')]) # getOptimalNewCameraMatrix FT.expose_func(sb.mb.free_fun('getOptimalNewCameraMatrix'), return_pointee=False, transformer_creators=[FT.output_type1('validPixROI')]) # calcHist for z in sb.mb.free_funs('calcHist'): FT.expose_func(z, return_pointee=False, transformer_creators=[ FT.input_array1d('images', 'nimages'), FT.input_array1d('channels'), FT.input_array1d('histSize', 'dims'), FT.input_array2d('ranges')]) z._transformer_kwds['alias'] = 'calcHist' # calcBackProject for z in sb.mb.free_funs('calcBackProject'): FT.expose_func(z, return_pointee=False, transformer_creators=[ FT.input_array1d('images', 'nimages'), FT.input_array1d('channels'), FT.input_array2d('ranges')]) z._transformer_kwds['alias'] = 'calcBackProject' # floodFill for z in sb.mb.free_funs('floodFill'): FT.expose_func(z, return_pointee=False, transformer_creators=[FT.output_type1('rect')]) z._transformer_kwds['alias'] = 'floodFill'