MvCameraControl.h 172 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922
  1. #ifndef _MV_CAMERA_CTRL_H_
  2. #define _MV_CAMERA_CTRL_H_
  3. #include "MvErrorDefine.h"
  4. #include "CameraParams.h"
  5. /**
  6. * @brief 动态库导入导出定义
  7. * @brief Import and export definition of the dynamic library
  8. */
  9. #ifndef MV_CAMCTRL_API
  10. #if (defined (_WIN32) || defined(WIN64))
  11. #if defined(MV_CAMCTRL_EXPORTS)
  12. #define MV_CAMCTRL_API __declspec(dllexport)
  13. #else
  14. #define MV_CAMCTRL_API __declspec(dllimport)
  15. #endif
  16. #else
  17. #ifndef __stdcall
  18. #define __stdcall
  19. #endif
  20. #ifndef MV_CAMCTRL_API
  21. #define MV_CAMCTRL_API
  22. #endif
  23. #endif
  24. #endif
  25. #ifndef IN
  26. #define IN
  27. #endif
  28. #ifndef OUT
  29. #define OUT
  30. #endif
  31. #ifdef __cplusplus
  32. extern "C" {
  33. #endif
  34. /************************************************************************/
  35. /* 相机的基本指令和操作 */
  36. /* Camera basic instructions and operations */
  37. /************************************************************************/
  38. /************************************************************************
  39. * @fn MV_CC_GetSDKVersion()
  40. * @brief 获取SDK版本号
  41. * @param
  42. * @return 始终返回4字节版本号 |主 |次 |修正 | 测试|
  43. 8bits 8bits 8bits 8bits
  44. * @fn MV_CC_GetSDKVersion()
  45. * @brief Get SDK Version
  46. * @param
  47. * @return Always return 4 Bytes of version number |Main |Sub |Rev | Test|
  48. 8bits 8bits 8bits 8bits
  49. ************************************************************************/
  50. MV_CAMCTRL_API unsigned int __stdcall MV_CC_GetSDKVersion();
  51. /************************************************************************
  52. * @fn MV_CC_EnumerateTls()
  53. * @brief 获取支持的传输层
  54. * @return 支持的传输层编号
  55. * @fn MV_CC_EnumerateTls()
  56. * @brief Get supported Transport Layer
  57. * @return Supported Transport Layer number
  58. ************************************************************************/
  59. MV_CAMCTRL_API int __stdcall MV_CC_EnumerateTls();
  60. /************************************************************************
  61. * @fn MV_CC_EnumDevices()
  62. * @brief 枚举设备
  63. * @param nTLayerType [IN] 枚举传输层
  64. * @param pstDevList [OUT] 设备列表
  65. * @return 成功,返回MV_OK;错误,返回错误码
  66. * @fn MV_CC_EnumDevices()
  67. * @brief Enumerate Device
  68. * @param nTLayerType [IN] Enumerate TLs
  69. * @param pstDevList [OUT] Device List
  70. * @return Success, return MV_OK. Failure, return error code
  71. ************************************************************************/
  72. MV_CAMCTRL_API int __stdcall MV_CC_EnumDevices(IN unsigned int nTLayerType, IN OUT MV_CC_DEVICE_INFO_LIST* pstDevList);
  73. /************************************************************************
  74. * @fn MV_CC_EnumDevicesEx()
  75. * @brief 根据厂商名字枚举设备
  76. * @param nTLayerType [IN] 枚举传输层
  77. * @param pstDevList [OUT] 设备列表
  78. * @param pManufacturerName [IN] 厂商名字
  79. * @return 成功,返回MV_OK;错误,返回错误码
  80. * @fn MV_CC_EnumDevicesEx()
  81. * @brief Enumerate device according to manufacture name
  82. * @param nTLayerType [IN] Transmission layer of enumeration
  83. * @param pstDevList [OUT] Device list
  84. * @param pManufacturerName [IN] Manufacture Name
  85. * @return Success, return MV_OK. Failure, return error code
  86. ************************************************************************/
  87. MV_CAMCTRL_API int __stdcall MV_CC_EnumDevicesEx(IN unsigned int nTLayerType, IN OUT MV_CC_DEVICE_INFO_LIST* pstDevList, IN const char* pManufacturerName);
  88. /************************************************************************
  89. * @fn MV_CC_IsDeviceAccessible()
  90. * @brief 设备是否可达
  91. * @param pstDevInfo [IN] 设备信息结构体
  92. * @param nAccessMode [IN] 访问权限
  93. * @return 可达,返回true;不可达,返回false
  94. * @fn MV_CC_IsDeviceAccessible()
  95. * @brief Is the device accessible
  96. * @param pstDevInfo [IN] Device Information Structure
  97. * @param nAccessMode [IN] Access Right
  98. * @return Access, return true. Not access, return false
  99. ************************************************************************/
  100. MV_CAMCTRL_API bool __stdcall MV_CC_IsDeviceAccessible(IN MV_CC_DEVICE_INFO* pstDevInfo, IN unsigned int nAccessMode);
  101. /************************************************************************
  102. * @fn MV_CC_SetSDKLogPath()
  103. * @brief 设置SDK日志路径(如果日志服务MvLogServer已启用,则该接口无效)
  104. * @param pSDKLogPath [IN] SDK日志路径
  105. * @return 成功,返回MV_OK;错误,返回错误码
  106. * @fn MV_CC_SetSDKLogPath()
  107. * @brief Set SDK log path
  108. * @param pSDKLogPath [IN] SDK log path
  109. * @return Access, return true. Not access, return false
  110. ************************************************************************/
  111. MV_CAMCTRL_API int __stdcall MV_CC_SetSDKLogPath(IN const char * pSDKLogPath);
  112. /************************************************************************
  113. * @fn MV_CC_CreateHandle()
  114. * @brief 创建设备句柄
  115. * @param handle [OUT] 句柄地址
  116. * @param pstDevInfo [IN] 设备信息结构体
  117. * @return 成功,返回MV_OK;错误,返回错误码
  118. * @fn MV_CC_CreateHandle()
  119. * @brief Create Device Handle
  120. * @param handle [OUT] Handle Address
  121. * @param pstDevInfo [IN] Device Information Structure
  122. * @return Success, return MV_OK. Failure, return error code
  123. ************************************************************************/
  124. MV_CAMCTRL_API int __stdcall MV_CC_CreateHandle(OUT void ** handle, IN const MV_CC_DEVICE_INFO* pstDevInfo);
  125. /************************************************************************
  126. * @fn MV_CC_CreateHandleWithoutLog
  127. * @brief 创建设备句柄,不生成日志
  128. * @param handle [OUT] 句柄地址
  129. * @param pstDevInfo [IN] 设备信息结构体
  130. * @return 成功,返回MV_OK;错误,返回错误码
  131. * @fn MV_CC_CreateHandleWithoutLog
  132. * @brief Create Device Handle without log
  133. * @param handle [OUT] Handle Address
  134. * @param pstDevInfo [IN] Device Information Structure
  135. * @return Success, return MV_OK. Failure, return error code
  136. ************************************************************************/
  137. MV_CAMCTRL_API int __stdcall MV_CC_CreateHandleWithoutLog(OUT void ** handle, IN const MV_CC_DEVICE_INFO* pstDevInfo);
  138. /************************************************************************
  139. * @fn MV_CC_DestroyHandle()
  140. * @brief 销毁设备句柄
  141. * @param handle [IN] 句柄
  142. * @return 成功,返回MV_OK;错误,返回错误码
  143. * @fn MV_CC_DestroyHandle()
  144. * @brief Destroy Device Handle
  145. * @param handle [IN] Handle
  146. * @return Success, return MV_OK. Failure, return error code
  147. ************************************************************************/
  148. MV_CAMCTRL_API int __stdcall MV_CC_DestroyHandle(IN void * handle);
  149. /************************************************************************
  150. * @fn MV_CC_OpenDevice()
  151. * @brief 打开设备
  152. * @param handle [IN] 句柄
  153. * @param nAccessMode [IN] 访问权限
  154. * @param nSwitchoverKey [IN] 切换访问权限时的密钥
  155. * @return 成功,返回MV_OK;错误,返回错误码
  156. * @fn MV_CC_OpenDevice()
  157. * @brief Open Device
  158. * @param handle [IN] Handle
  159. * @param nAccessMode [IN] Access Right
  160. * @param nSwitchoverKey [IN] Switch key of access right
  161. * @return Success, return MV_OK. Failure, return error code
  162. ************************************************************************/
  163. #ifndef __cplusplus
  164. MV_CAMCTRL_API int __stdcall MV_CC_OpenDevice(IN void* handle, IN unsigned int nAccessMode, IN unsigned short nSwitchoverKey);
  165. #else
  166. MV_CAMCTRL_API int __stdcall MV_CC_OpenDevice(IN void* handle, IN unsigned int nAccessMode = MV_ACCESS_Exclusive, IN unsigned short nSwitchoverKey = 0);
  167. #endif
  168. /***********************************************************************
  169. * @fn MV_CC_CloseDevice
  170. * @brief 关闭相机
  171. * @param handle [IN] 句柄
  172. * @return 成功,返回MV_OK;错误,返回错误码
  173. * @fn MV_CC_CloseDevice
  174. * @brief Close Device
  175. * @param handle [IN] Handle
  176. * @return Success, return MV_OK. Failure, return error code
  177. ***********************************************************************/
  178. MV_CAMCTRL_API int __stdcall MV_CC_CloseDevice(IN void* handle);
  179. /***********************************************************************
  180. * @fn MV_CC_IsDeviceConnected
  181. * @brief 判断相机是否处于连接状态
  182. * @param handle [IN] 句柄
  183. * @return 设备处于连接状态,返回true;没连接或失去连接,返回false
  184. * @fn MV_CC_IsDeviceConnected
  185. * @brief Is The Device Connected
  186. * @param handle [IN] Handle
  187. * @return Connected, return true. Not Connected or DIsconnected, return false
  188. ***********************************************************************/
  189. MV_CAMCTRL_API bool __stdcall MV_CC_IsDeviceConnected(IN void* handle);
  190. /***********************************************************************
  191. * @fn MV_CC_RegisterImageCallBackEx
  192. * @brief 注册图像数据回调,chunk
  193. * @param handle [IN] 句柄
  194. * @param cbOutput [IN] 回调函数指针
  195. * @param pUser [IN] 用户自定义变量
  196. * @return 成功,返回MV_OK;错误,返回错误码
  197. * @fn MV_CC_RegisterImageCallBackEx
  198. * @brief register image data callback, chunk
  199. * @param handle [IN] Handle
  200. * @param cbOutput [IN] Callback function pointer
  201. * @param pUser [IN] User defined variable
  202. * @return Success, return MV_OK. Failure, return error code
  203. ***********************************************************************/
  204. MV_CAMCTRL_API int __stdcall MV_CC_RegisterImageCallBackEx(void* handle,
  205. void(__stdcall* cbOutput)(unsigned char * pData, MV_FRAME_OUT_INFO_EX* pFrameInfo, void* pUser),
  206. void* pUser);
  207. /***********************************************************************
  208. * @fn MV_CC_RegisterImageCallbackForRGB
  209. * @brief 注册图像数据回调,RGB
  210. * @param handle [IN] 句柄
  211. * @param cbOutput [IN] 回调函数指针
  212. * @param pUser [IN] 用户自定义变量
  213. * @return 成功,返回MV_OK;错误,返回错误码
  214. * @fn MV_CC_RegisterImageCallbackForRGB
  215. * @brief register image data callback, RGB
  216. * @param handle [IN] Handle
  217. * @param cbOutput [IN] Callback function pointer
  218. * @param pUser [IN] User defined variable
  219. * @return Success, return MV_OK. Failure, return error code
  220. ***********************************************************************/
  221. MV_CAMCTRL_API int __stdcall MV_CC_RegisterImageCallBackForRGB(void* handle,
  222. void(__stdcall* cbOutput)(unsigned char * pData, MV_FRAME_OUT_INFO_EX* pFrameInfo, void* pUser),
  223. void* pUser);
  224. /***********************************************************************
  225. * @fn MV_CC_RegisterImageCallbackForBGR
  226. * @brief 注册图像数据回调,BGR
  227. * @param handle [IN] 句柄
  228. * @param cbOutput [IN] 回调函数指针
  229. * @param pUser [IN] 用户自定义变量
  230. * @return 成功,返回MV_OK;错误,返回错误码
  231. * @fn MV_CC_RegisterImageCallbackForBGR
  232. * @brief register image data callback, BGR
  233. * @param handle [IN] Handle
  234. * @param cbOutput [IN] Callback function pointer
  235. * @param pUser [IN] User defined variable
  236. * @return Success, return MV_OK. Failure, return error code
  237. ***********************************************************************/
  238. MV_CAMCTRL_API int __stdcall MV_CC_RegisterImageCallBackForBGR(void* handle,
  239. void(__stdcall* cbOutput)(unsigned char * pData, MV_FRAME_OUT_INFO_EX* pFrameInfo, void* pUser),
  240. void* pUser);
  241. /***********************************************************************
  242. * @fn MV_CC_StartGrabbing
  243. * @brief 开始取流
  244. * @param handle [IN] 句柄
  245. * @return 成功,返回MV_OK;错误,返回错误码
  246. * @fn MV_CC_StartGrabbing
  247. * @brief Start Grabbing
  248. * @param handle [IN] Handle
  249. * @return Success, return MV_OK. Failure, return error code
  250. ***********************************************************************/
  251. MV_CAMCTRL_API int __stdcall MV_CC_StartGrabbing(IN void* handle);
  252. /***********************************************************************
  253. * @fn MV_CC_StopGrabbing
  254. * @brief 停止取流
  255. * @param handle [IN] 句柄
  256. * @return 成功,返回MV_OK;错误,返回错误码
  257. * @fn MV_CC_StopGrabbing
  258. * @brief Stop Grabbing
  259. * @param handle [IN] Handle
  260. * @return Success, return MV_OK. Failure, return error code
  261. ***********************************************************************/
  262. MV_CAMCTRL_API int __stdcall MV_CC_StopGrabbing(IN void* handle);
  263. /***********************************************************************
  264. * @fn MV_CC_GetImageForRGB
  265. * @brief 获取一帧RGB数据,此函数为查询式获取,每次调用查询内部
  266. 缓存有无数据,有数据则范围数据,无数据返回错误码
  267. * @param handle [IN] 句柄
  268. * @param pData [OUT] 图像数据接收指针
  269. * @param nDataSize [IN] 接收缓存大小
  270. * @param pFrameInfo [OUT] 图像信息结构体
  271. * @param nMsec [IN] 等待超时时间
  272. * @return 成功,返回MV_OK;错误,返回错误码
  273. * @fn MV_CC_GetImageForRGB
  274. * @brief Get one frame of RGB data, this function is using query to get data,
  275. query whether the internal cache has data, return data if there has, return error code if no data
  276. * @param handle [IN] Handle
  277. * @param pData [OUT] Recevied image data pointer
  278. * @param nDataSize [IN] Recevied buffer size
  279. * @param pFrameInfo [OUT] Image information structure
  280. * @param nMsec [IN] Waiting timeout
  281. * @return Success, return MV_OK. Failure, return error code
  282. ***********************************************************************/
  283. MV_CAMCTRL_API int __stdcall MV_CC_GetImageForRGB(IN void* handle, IN OUT unsigned char * pData , IN unsigned int nDataSize, IN OUT MV_FRAME_OUT_INFO_EX* pFrameInfo, int nMsec);
  284. /***********************************************************************
  285. * @fn MV_CC_GetImageForBGR
  286. * @brief 获取一帧BGR数据,此函数为查询式获取,每次调用查询内部
  287. 缓存有无数据,有数据则范围数据,无数据返回错误码
  288. * @param handle [IN] 句柄
  289. * @param pData [OUT] 图像数据接收指针
  290. * @param nDataSize [IN] 接收缓存大小
  291. * @param pFrameInfo [OUT] 图像信息结构体
  292. * @param nMsec [IN] 等待超时时间
  293. * @return 成功,返回MV_OK;错误,返回错误码
  294. * @fn MV_CC_GetImageForBGR
  295. * @brief Get one frame of BGR data, this function is using query to get data,
  296. query whether the internal cache has data, return data if there has, return error code if no data
  297. * @param handle [IN] Handle
  298. * @param pData [OUT] Recevied image data pointer
  299. * @param nDataSize [IN] Recevied buffer size
  300. * @param pFrameInfo [OUT] Image information structure
  301. * @param nMsec [IN] Waiting timeout
  302. * @return Success, return MV_OK. Failure, return error code
  303. ***********************************************************************/
  304. MV_CAMCTRL_API int __stdcall MV_CC_GetImageForBGR(IN void* handle, IN OUT unsigned char * pData , IN unsigned int nDataSize, IN OUT MV_FRAME_OUT_INFO_EX* pFrameInfo, int nMsec);
  305. /***********************************************************************
  306. * @fn MV_CC_GetImageBuffer
  307. * @brief 采用超时机制获取一帧图片,SDK内部等待直到有数据时返回,
  308. 此接口可以增加取流平稳性,适合用于对平稳性要求较高的场合(与MV_CC_Display不能同时使用)
  309. * @param handle [IN] 句柄
  310. * @param pFrame [OUT] 图像数据首地址和图像信息
  311. * @param nMsec [IN] 等待超时时间,输入INFINITE时表示无限等待,直到收到一帧数据或者停止取流
  312. * @return 成功,返回MV_OK;错误,返回错误码
  313. * @fn MV_CC_GetImageBuffer
  314. * @brief Timeout mechanism is used to get image, and the SDK waits inside until the data is returned,
  315. this interface can increase the flow stability, and is suitable for occasions with higher stability requirements
  316. * @param handle [IN] Handle
  317. * @param pFrame [OUT] Pointer of recevied image data and info
  318. * @param nMsec [IN] Waiting timeout
  319. * @return Success, return MV_OK. Failure, return error code
  320. ***********************************************************************/
  321. MV_CAMCTRL_API int __stdcall MV_CC_GetImageBuffer(IN void* handle, OUT MV_FRAME_OUT* pFrame, IN unsigned int nMsec);
  322. /***********************************************************************
  323. * @fn MV_CC_FreeImageBuffer
  324. * @brief 释放图像缓存(此接口用于释放不再使用的图像缓存,与MV_CC_GetImageBuffer配套使用)
  325. * @param handle [IN] 句柄
  326. * @param pFrame [IN] 图像数据和信息接收指针
  327. * @return 成功,返回MV_OK;错误,返回错误码
  328. * @fn MV_CC_FreeImageBuffer
  329. * @brief Free image buffer(this interface can free image buffer, used with MV_CC_GetImageBuffer)
  330. * @param handle [IN] Handle
  331. * @param pFrame [IN] Pointer of recevied image data and info
  332. * @return Success, return MV_OK. Failure, return error code
  333. ***********************************************************************/
  334. MV_CAMCTRL_API int __stdcall MV_CC_FreeImageBuffer(IN void* handle, IN MV_FRAME_OUT* pFrame);
  335. /***********************************************************************
  336. * @fn MV_CC_GetOneFrameTimeout
  337. * @brief 采用超时机制获取一帧图片,SDK内部等待直到有数据时返回,
  338. 此接口可以增加取流平稳性,适合用于对平稳性要求较高的场合
  339. * @param handle [IN] 句柄
  340. * @param pData [OUT] 图像数据接收指针
  341. * @param nDataSize [IN] 接收缓存大小
  342. * @param pFrameInfo [OUT] 图像信息结构体
  343. * @param nMsec [IN] 等待超时时间
  344. * @return 成功,返回MV_OK;错误,返回错误码
  345. * @fn MV_CC_GetOneFrameTimeout
  346. * @brief Timeout mechanism is used to get image, and the SDK waits inside until the data is returned,
  347. this interface can increase the flow stability, and is suitable for occasions with higher stability requirements
  348. * @param handle [IN] Handle
  349. * @param pData [OUT] Recevied image data pointer
  350. * @param nDataSize [IN] Recevied buffer size
  351. * @param pFrameInfo [OUT] Image information structure
  352. * @param nMsec [IN] Waiting timeout
  353. * @return Success, return MV_OK. Failure, return error code
  354. ***********************************************************************/
  355. MV_CAMCTRL_API int __stdcall MV_CC_GetOneFrameTimeout(IN void* handle, IN OUT unsigned char * pData , IN unsigned int nDataSize, IN OUT MV_FRAME_OUT_INFO_EX* pFrameInfo, unsigned int nMsec);
  356. /***********************************************************************
  357. * @fn MV_CC_Display
  358. * @brief 显示图像,注册显示窗口,内部自动显示(与MV_CC_GetImageBuffer不能同时使用)
  359. * @param handle [IN] 句柄
  360. * @param hWnd [IN] 显示窗口句柄
  361. * @return 成功,返回MV_OK;错误,返回错误码
  362. * @fn MV_CC_Display
  363. * @brief Display one frame image, register display window, automatic display internally
  364. * @param handle [IN] Handle
  365. * @param hWnd [IN] Display Window Handle
  366. * @return Success, return MV_OK. Failure, return error code
  367. ***********************************************************************/
  368. MV_CAMCTRL_API int __stdcall MV_CC_Display(IN void* handle, void* hWnd);
  369. /***********************************************************************
  370. * @fn MV_CC_DisplayOneFrame
  371. * @brief 显示一帧图像
  372. * @param handle [IN] 句柄
  373. * @param pDisplayInfo [IN] 图像信息
  374. * @return 成功,返回MV_OK;错误,返回错误码
  375. * @fn MV_CC_DisplayOneFrame
  376. * @brief Display one frame image
  377. * @param handle [IN] Handle
  378. * @param pDisplayInfo [IN] Frame Info
  379. * @return Success, return MV_OK. Failure, return error code
  380. ***********************************************************************/
  381. MV_CAMCTRL_API int __stdcall MV_CC_DisplayOneFrame(IN void* handle, IN MV_DISPLAY_FRAME_INFO* pDisplayInfo);
  382. /***********************************************************************
  383. * @fn MV_CC_SetImageNodeNum
  384. * @brief 设置SDK内部图像缓存节点个数,范围[1, 30],在抓图前调用
  385. * @param handle [IN] 句柄
  386. * @param nNum [IN] 缓存节点个数
  387. * @return 成功,返回MV_OK;错误,返回错误码
  388. * @fn MV_CC_SetImageNodeNum
  389. * @brief Set the number of the internal image cache nodes in SDK, in the range [1, 30], to be called before the capture
  390. * @param handle [IN] Handle
  391. * @param nNum [IN] Image Node Number
  392. * @return Success, return MV_OK. Failure, return error code
  393. ***********************************************************************/
  394. MV_CAMCTRL_API int __stdcall MV_CC_SetImageNodeNum(IN void* handle, unsigned int nNum);
  395. /************************************************************************
  396. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetImageInfo(IN void* handle, IN OUT MV_IMAGE_BASIC_INFO* pstInfo);
  397. * @brief 获取图像基本信息
  398. * @param void* handle [IN] 相机句柄
  399. * @param MV_IMAGE_BASIC_INFO* pstInfo [IN][OUT] 返回给调用者有关相机图像基本信息结构体指针
  400. * @return 成功,返回MV_OK,失败,返回错误码
  401. *
  402. * 参考 CameraParam.h 中的 MV_IMAGE_BASIC_INFO 定义
  403. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetImageInfo(IN void* handle, IN OUT MV_IMAGE_BASIC_INFO* pstInfo);
  404. * @brief Get basic information of image
  405. * @param void* handle [IN] Handle
  406. * @param MV_IMAGE_BASIC_INFO* pstInfo [IN][OUT] Structure pointer of image basic information
  407. * @return Success, return MV_OK. Failure, return error code
  408. *
  409. * Refer to the definition of MV_IMAGE_BASIC_INFO in CameraParam.h
  410. ************************************************************************/
  411. MV_CAMCTRL_API int __stdcall MV_CC_GetImageInfo(IN void* handle, IN OUT MV_IMAGE_BASIC_INFO* pstInfo);
  412. /************************************************************************
  413. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetDeviceInfo(IN void* handle, IN OUT MV_CC_DEVICE_INFO* pstDevInfo);
  414. * @brief 获取设备信息
  415. * @param void* handle [IN] 相机句柄
  416. * @param MV_CC_DEVICE_INFO* pstDevInfo [IN][OUT] 返回给调用者有关相机设备信息结构体指针
  417. * @return 成功,返回MV_OK,失败,返回错误码
  418. *
  419. * 参考 CameraParam.h 中的 MV_CC_DEVICE_INFO 定义
  420. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetDeviceInfo(IN void* handle, IN OUT MV_CC_DEVICE_INFO* pstDevInfo);
  421. * @brief Get device information
  422. * @param void* handle [IN] Handle
  423. * @param MV_CC_DEVICE_INFO* pstDevInfo [IN][OUT] Structure pointer of device information
  424. * @return Success, return MV_OK. Failure, return error code
  425. *
  426. * Refer to the definition of MV_CC_DEVICE_INFO in CameraParam.h
  427. ************************************************************************/
  428. MV_CAMCTRL_API int __stdcall MV_CC_GetDeviceInfo(IN void * handle, IN OUT MV_CC_DEVICE_INFO* pstDevInfo);
  429. /************************************************************************
  430. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetAllMatchInfo(IN void* handle, IN OUT MV_ALL_MATCH_INFO* pstInfo);
  431. * @brief 获取各种类型的信息
  432. * @param void* handle [IN] 相机句柄
  433. * @param MV_ALL_MATCH_INFO* pstInfo [IN][OUT] 返回给调用者有关相机各种类型的信息结构体指针
  434. * @return 成功,返回MV_OK,失败,返回错误码
  435. *
  436. * 参考 CameraParam.h 中的 MV_ALL_MATCH_INFO 定义
  437. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetAllMatchInfo(IN void* handle, IN OUT MV_ALL_MATCH_INFO* pstInfo);
  438. * @brief Get various type of information
  439. * @param void* handle [IN] Handle
  440. * @param MV_ALL_MATCH_INFO* pstInfo [IN][OUT] Structure pointer of various type of information
  441. * @return Success, return MV_OK. Failure, return error code
  442. *
  443. * Refer to the definition of MV_ALL_MATCH_INFO in CameraParam.h
  444. ************************************************************************/
  445. MV_CAMCTRL_API int __stdcall MV_CC_GetAllMatchInfo(IN void* handle, IN OUT MV_ALL_MATCH_INFO* pstInfo);
  446. /************************************************************************/
  447. /* 设置和获取相机参数的万能接口 */
  448. /* General interface for getting and setting camera parameters */
  449. /************************************************************************/
  450. /************************************************************************
  451. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetIntValue(IN void* handle,
  452. IN const char* strKey,
  453. OUT MVCC_INTVALUE *pIntValue);
  454. * @brief 获取Integer属性值
  455. * @param void* handle [IN] 相机句柄
  456. * @param char* strKey [IN] 属性键值,如获取宽度信息则为"Width"
  457. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机属性结构体指针
  458. * @return 成功,返回MV_OK,失败,返回错误码
  459. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetIntValue(IN void* handle,
  460. IN const char* strKey,
  461. OUT MVCC_INTVALUE *pIntValue);
  462. * @brief Get Integer value
  463. * @param void* handle [IN] Handle
  464. * @param char* strKey [IN] Key value, for example, using "Width" to get width
  465. * @param MVCC_INTVALUE* pstValue [IN][OUT] Structure pointer of camera features
  466. * @return Success, return MV_OK. Failure, return error code
  467. ************************************************************************/
  468. MV_CAMCTRL_API int __stdcall MV_CC_GetIntValue(IN void* handle,IN const char* strKey,OUT MVCC_INTVALUE *pIntValue);
  469. /************************************************************************/
  470. /* 设置和获取相机参数的万能接口 */
  471. /* General interface for getting and setting camera parameters */
  472. /************************************************************************/
  473. /************************************************************************
  474. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetIntValueEx(IN void* handle,
  475. IN const char* strKey,
  476. OUT MVCC_INTVALUE *pIntValue);
  477. * @brief 获取Integer属性值
  478. * @param void* handle [IN] 相机句柄
  479. * @param char* strKey [IN] 属性键值,如获取宽度信息则为"Width"
  480. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机属性结构体指针
  481. * @return 成功,返回MV_OK,失败,返回错误码
  482. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetIntValueEx(IN void* handle,
  483. IN const char* strKey,
  484. OUT MVCC_INTVALUE *pIntValue);
  485. * @brief Get Integer value
  486. * @param void* handle [IN] Handle
  487. * @param char* strKey [IN] Key value, for example, using "Width" to get width
  488. * @param MVCC_INTVALUE* pstValue [IN][OUT] Structure pointer of camera features
  489. * @return Success, return MV_OK. Failure, return error code
  490. ************************************************************************/
  491. MV_CAMCTRL_API int __stdcall MV_CC_GetIntValueEx(IN void* handle,IN const char* strKey,OUT MVCC_INTVALUE_EX *pIntValue);
  492. /************************************************************************
  493. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetIntValue(IN void* handle,
  494. IN const char* strKey,
  495. IN unsigned int nValue);
  496. * @brief 设置Integer型属性值
  497. * @param void* handle [IN] 相机句柄
  498. * @param char* strKey [IN] 属性键值,如获取宽度信息则为"Width"
  499. * const unsigned int nValue [IN] 想要设置的相机的属性值
  500. * @return 成功,返回MV_OK,失败,返回错误码
  501. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetIntValue(IN void* handle,
  502. IN const char* strKey,
  503. IN unsigned int nValue);
  504. * @brief Set Integer value
  505. * @param void* handle [IN] Handle
  506. * @param char* strKey [IN] Key value, for example, using "Width" to set width
  507. * const unsigned int nValue [IN] Feature value to set
  508. * @return Success, return MV_OK. Failure, return error code
  509. ************************************************************************/
  510. MV_CAMCTRL_API int __stdcall MV_CC_SetIntValue(IN void* handle,IN const char* strKey,IN unsigned int nValue);
  511. /************************************************************************
  512. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetIntValueEx(IN void* handle,
  513. IN const char* strKey,
  514. IN int64_t nValue);
  515. * @brief 设置Integer型属性值
  516. * @param void* handle [IN] 相机句柄
  517. * @param char* strKey [IN] 属性键值,如获取宽度信息则为"Width"
  518. * const int64_t nValue [IN] 想要设置的相机的属性值
  519. * @return 成功,返回MV_OK,失败,返回错误码
  520. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetIntValueEx(IN void* handle,
  521. IN const char* strKey,
  522. IN int64_t nValue);
  523. * @brief Set Integer value
  524. * @param void* handle [IN] Handle
  525. * @param char* strKey [IN] Key value, for example, using "Width" to set width
  526. * const int64_t nValue [IN] Feature value to set
  527. * @return Success, return MV_OK. Failure, return error code
  528. ************************************************************************/
  529. MV_CAMCTRL_API int __stdcall MV_CC_SetIntValueEx(IN void* handle,IN const char* strKey,IN int64_t nValue);
  530. /************************************************************************
  531. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetEnumValue(IN void* handle,
  532. IN const char* strKey,
  533. OUT MVCC_ENUMVALUE *pEnumValue);
  534. * @brief 获取Enum属性值
  535. * @param void* handle [IN] 相机句柄
  536. * @param char* strKey [IN] 属性键值,如获取像素格式信息则为"PixelFormat"
  537. * @param MVCC_ENUMVALUE* pEnumValue [IN][OUT] 返回给调用者有关相机属性结构体指针
  538. * @return 成功,返回MV_OK,失败,返回错误码
  539. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetEnumValue(IN void* handle,
  540. IN const char* strKey,
  541. OUT MVCC_ENUMVALUE *pEnumValue);
  542. * @brief Get Enum value
  543. * @param void* handle [IN] Handle
  544. * @param char* strKey [IN] Key value, for example, using "PixelFormat" to get pixel format
  545. * @param MVCC_ENUMVALUE* pEnumValue [IN][OUT] Structure pointer of camera features
  546. * @return Success, return MV_OK. Failure, return error code
  547. ************************************************************************/
  548. MV_CAMCTRL_API int __stdcall MV_CC_GetEnumValue(IN void* handle,IN const char* strKey,OUT MVCC_ENUMVALUE *pEnumValue);
  549. /************************************************************************
  550. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetEnumValue(IN void* handle,
  551. IN const char* strKey,
  552. IN unsigned int nValue);
  553. * @brief 设置Enum型属性值
  554. * @param void* handle [IN] 相机句柄
  555. * @param char* strKey [IN] 属性键值,如获取像素格式信息则为"PixelFormat"
  556. * const unsigned int nValue [IN] 想要设置的相机的属性值
  557. * @return 成功,返回MV_OK,失败,返回错误码
  558. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetEnumValue(IN void* handle,
  559. IN const char* strKey,
  560. IN unsigned int nValue);
  561. * @brief Set Enum value
  562. * @param void* handle [IN] Handle
  563. * @param char* strKey [IN] Key value, for example, using "PixelFormat" to set pixel format
  564. * const unsigned int nValue [IN] Feature value to set
  565. * @return Success, return MV_OK. Failure, return error code
  566. ************************************************************************/
  567. MV_CAMCTRL_API int __stdcall MV_CC_SetEnumValue(IN void* handle,IN const char* strKey,IN unsigned int nValue);
  568. /************************************************************************
  569. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetEnumValueByString(IN void* handle,
  570. IN const char* strKey,
  571. IN const char* sValue);
  572. * @brief 设置Enum型属性值
  573. * @param void* handle [IN] 相机句柄
  574. * @param char* strKey [IN] 属性键值,如获取像素格式信息则为"PixelFormat"
  575. * char* sValue [IN] 想要设置的相机的属性字符串
  576. * @return 成功,返回MV_OK,失败,返回错误码
  577. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetEnumValue(IN void* handle,
  578. IN const char* strKey,
  579. IN const char* sValue);
  580. * @brief Set Enum value
  581. * @param void* handle [IN] Handle
  582. * @param char* strKey [IN] Key value, for example, using "PixelFormat" to set pixel format
  583. * char* sValue [IN] Feature String to set
  584. * @return Success, return MV_OK. Failure, return error code
  585. ************************************************************************/
  586. MV_CAMCTRL_API int __stdcall MV_CC_SetEnumValueByString(IN void* handle,IN const char* strKey,IN const char* sValue);
  587. /************************************************************************
  588. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetFloatValue(IN void* handle,
  589. IN const char* strKey,
  590. OUT MVCC_FLOATVALUE *pFloatValue);
  591. * @brief 获取Float属性值
  592. * @param void* handle [IN] 相机句柄
  593. * @param char* strKey [IN] 属性键值
  594. * @param MVCC_FLOATVALUE *pFloatValue [IN][OUT] 返回给调用者有关相机属性结构体指针
  595. * @return 成功,返回MV_OK,失败,返回错误码
  596. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetFloatValue(IN void* handle,
  597. IN const char* strKey,
  598. OUT MVCC_FLOATVALUE *pFloatValue);
  599. * @brief Get Float value
  600. * @param void* handle [IN] Handle
  601. * @param char* strKey [IN] Key value
  602. * @param MVCC_FLOATVALUE *pFloatValue [IN][OUT] Structure pointer of camera features
  603. * @return Success, return MV_OK. Failure, return error code
  604. ************************************************************************/
  605. MV_CAMCTRL_API int __stdcall MV_CC_GetFloatValue(IN void* handle,IN const char* strKey,OUT MVCC_FLOATVALUE *pFloatValue);
  606. /************************************************************************
  607. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetFloatValue(IN void* handle,
  608. IN const char* strKey,
  609. IN float fValue);
  610. * @brief 设置float型属性值
  611. * @param void* handle [IN] 相机句柄
  612. * @param char* strKey [IN] 属性键值
  613. * float fValue [IN] 想要设置的相机的属性值
  614. * @return 成功,返回MV_OK,失败,返回错误码
  615. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetFloatValue(IN void* handle,
  616. IN const char* strKey,
  617. IN float fValue);
  618. * @brief Set float value
  619. * @param void* handle [IN] Handle
  620. * @param char* strKey [IN] Key value
  621. * float fValue [IN] Feature value to set
  622. * @return Success, return MV_OK. Failure, return error code
  623. ************************************************************************/
  624. MV_CAMCTRL_API int __stdcall MV_CC_SetFloatValue(IN void* handle,IN const char* strKey,IN float fValue);
  625. /************************************************************************
  626. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetBoolValue(IN void* handle,
  627. IN const char* strKey,
  628. OUT bool *pBoolValue);
  629. * @brief 获取Boolean属性值
  630. * @param void* handle [IN] 相机句柄
  631. * @param char* strKey [IN] 属性键值
  632. * @param bool *pBoolValue [IN][OUT] 返回给调用者有关相机属性值
  633. * @return 成功,返回MV_OK,失败,返回错误码
  634. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetBoolValue(IN void* handle,
  635. IN const char* strKey,
  636. OUT bool *pBoolValue);
  637. * @brief Get Boolean value
  638. * @param void* handle [IN] Handle
  639. * @param char* strKey [IN] Key value
  640. * @param bool *pBoolValue [IN][OUT] Structure pointer of camera features
  641. * @return Success, return MV_OK. Failure, return error code
  642. ************************************************************************/
  643. MV_CAMCTRL_API int __stdcall MV_CC_GetBoolValue(IN void* handle,IN const char* strKey,OUT bool *pBoolValue);
  644. /************************************************************************
  645. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetBoolValue(IN void* handle,
  646. IN const char* strKey,
  647. IN bool bValue);
  648. * @brief 设置Boolean型属性值
  649. * @param void* handle [IN] 相机句柄
  650. * @param char* strKey [IN] 属性键值
  651. * bool bValue [IN] 想要设置的相机的属性值
  652. * @return 成功,返回MV_OK,失败,返回错误码
  653. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetBoolValue(IN void* handle,
  654. IN const char* strKey,
  655. IN bool bValue);
  656. * @brief Set Boolean value
  657. * @param void* handle [IN] Handle
  658. * @param char* strKey [IN] Key value
  659. * bool bValue [IN] Feature value to set
  660. * @return Success, return MV_OK. Failure, return error code
  661. ************************************************************************/
  662. MV_CAMCTRL_API int __stdcall MV_CC_SetBoolValue(IN void* handle,IN const char* strKey,IN bool bValue);
  663. /************************************************************************
  664. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetStringValue(IN void* handle,
  665. IN const char* strKey,
  666. OUT MVCC_STRINGVALUE *pStringValue);
  667. * @brief 获取String属性值
  668. * @param void* handle [IN] 相机句柄
  669. * @param char* strKey [IN] 属性键值
  670. * @param MVCC_STRINGVALUE *pStringValue [IN][OUT] 返回给调用者有关相机属性结构体指针
  671. * @return 成功,返回MV_OK,失败,返回错误码
  672. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetStringValue(IN void* handle,
  673. IN const char* strKey,
  674. OUT MVCC_STRINGVALUE *pStringValue);
  675. * @brief Get String value
  676. * @param void* handle [IN] Handle
  677. * @param char* strKey [IN] Key value
  678. * @param MVCC_STRINGVALUE *pStringValue [IN][OUT] Structure pointer of camera features
  679. * @return Success, return MV_OK. Failure, return error code
  680. ************************************************************************/
  681. MV_CAMCTRL_API int __stdcall MV_CC_GetStringValue(IN void* handle,IN const char* strKey,OUT MVCC_STRINGVALUE *pStringValue);
  682. /************************************************************************
  683. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetStringValue(IN void* handle,
  684. IN const char* strKey,
  685. IN const char * sValue);
  686. * @brief 设置String型属性值
  687. * @param void* handle [IN] 相机句柄
  688. * @param char* strKey [IN] 属性键值
  689. * char * sValue [IN] 想要设置的相机的属性值
  690. * @return 成功,返回MV_OK,失败,返回错误码
  691. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetStringValue(IN void* handle,
  692. IN const char* strKey,
  693. IN const char * sValue);
  694. * @brief Set String value
  695. * @param void* handle [IN] Handle
  696. * @param char* strKey [IN] Key value
  697. * char * sValue [IN] Feature value to set
  698. * @return Success, return MV_OK. Failure, return error code
  699. ************************************************************************/
  700. MV_CAMCTRL_API int __stdcall MV_CC_SetStringValue(IN void* handle,IN const char* strKey,IN const char * sValue);
  701. /************************************************************************
  702. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetCommandValue(IN void* handle,
  703. IN const char* strKey);
  704. * @brief 设置Command型属性值
  705. * @param void* handle [IN] 相机句柄
  706. * @param char* strKey [IN] 属性键值
  707. * @return 成功,返回MV_OK,失败,返回错误码
  708. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetCommandValue(IN void* handle,
  709. IN const char* strKey);
  710. * @brief Set Command value
  711. * @param void* handle [IN] Handle
  712. * @param char* strKey [IN] Key value
  713. * @return Success, return MV_OK. Failure, return error code
  714. ************************************************************************/
  715. MV_CAMCTRL_API int __stdcall MV_CC_SetCommandValue(IN void* handle,IN const char* strKey);
  716. /************************************************************************
  717. * @fn MV_CC_InvalidateNodes
  718. * @brief 清除GenICam节点缓存
  719. * @param handle [IN] 句柄地址
  720. * @return 成功,返回MV_OK;错误,返回错误码
  721. * @fn MV_CC_InvalidateNodes
  722. * @brief Invalidate GenICam Nodes
  723. * @param handle [IN] Handle
  724. * @return Success, return MV_OK. Failure, return error code
  725. ************************************************************************/
  726. MV_CAMCTRL_API int __stdcall MV_CC_InvalidateNodes(IN void* handle);
  727. /************************************************************************/
  728. /* 相机参数获取和设置,此模块的所有接口,将逐步废弃,建议用上面的万能接口代替 */
  729. /* Get and set camara parameters, all interfaces of this module will be replaced by general interface*/
  730. /************************************************************************/
  731. /************************************************************************
  732. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetWidth(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  733. * @brief 获取图像宽度
  734. * @param void* handle [IN] 相机句柄
  735. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机宽度的信息结构体指针
  736. * 返回的pstValue结构体的意义
  737. * unsigned int nCurValue; // 代表相机当前的宽度值
  738. * unsigned int nMax; // 表示相机允许的最大可设置的宽度值
  739. * unsigned int nMin; // 表示相机允许的最小可设置的宽度值
  740. * unsigned int nInc; // 表示相机设置的宽度增量必须是nInc的倍数,否则无效
  741. * @return 成功,返回MV_OK,并获得相应参数信息的结构体, 失败, 返回错误码
  742. *
  743. * 其他整型结构体参数的接口可参照此接口
  744. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetWidth(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  745. * @brief Get image width
  746. * @param void* handle [IN] Camera Handle
  747. * MVCC_INTVALUE* pstValue [IN][OUT] Returns the information structure pointer about the camera's width for the caller
  748. * The meaning of returns pstValue structure
  749. * unsigned int nCurValue; // Represents the current width value of the camera
  750. * unsigned int nMax; // Indicates the maximum settable width value allowed by the camera
  751. * unsigned int nMin; // Indicates the minimum settable width value allowed by the camera
  752. * unsigned int nInc; // Indicates that the width increment set by the camera must be a multiple of nInc, otherwise it is invalid
  753. * @return Success, return MV_OK, and get the structure of the corresponding parameters. Failure, return error code
  754. *
  755. * Other Integer structure parameters interface can refer to this interface
  756. ************************************************************************/
  757. MV_CAMCTRL_API int __stdcall MV_CC_GetWidth(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  758. /************************************************************************
  759. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetWidth(IN void* handle, IN const unsigned int nValue);
  760. * @brief 设置图像宽度
  761. * @param void* handle [IN] 相机句柄
  762. * const unsigned int nValue [IN] 想要设置的相机宽度的值,注意此宽度值必须是MV_CC_GetWidth接口返回的pstValue中的nInc的倍数才能设置成功
  763. * @return 成功,返回MV_OK,并且相机宽度将会更改为相应值,失败,返回错误码
  764. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetWidth(IN void* handle, IN const unsigned int nValue);
  765. * @brief Set image width
  766. * @param void* handle [IN] Camera Handle
  767. * const unsigned int nValue [IN] To set the value of the camera width, note that the width value must be a multiple of nInc in the pstValue returned by the MV_CC_GetWidth interface
  768. * @return Success, return MV_OK, and the camera width will change to the corresponding value. Failure, return error code
  769. ************************************************************************/
  770. MV_CAMCTRL_API int __stdcall MV_CC_SetWidth(IN void* handle, IN const unsigned int nValue);
  771. /************************************************************************
  772. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetHeight(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  773. * @brief 获取图像高度
  774. * @param void* handle [IN] 相机句柄
  775. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机高度的信息结构体指针
  776. * @return 成功,返回MV_OK,并将高度信息返回到结构体中,失败,返回错误码
  777. *
  778. * 可参照接口MV_CC_GetWidth
  779. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetHeight(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  780. * @brief Get image height
  781. * @param void* handle [IN] Camera handle
  782. * @param MVCC_INTVALUE* pstValue [IN][OUT] Return pointer of information structure related to camera height to user
  783. * @return Success, return MV_OK, and return height information to the structure. Failure, return error code
  784. *
  785. * Refer to MV_CC_GetWidth
  786. ************************************************************************/
  787. MV_CAMCTRL_API int __stdcall MV_CC_GetHeight(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  788. /************************************************************************
  789. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetHeight(IN void* handle, IN const unsigned int nValue);
  790. * @brief 设置图像高度
  791. * @param void* handle [IN] 相机句柄
  792. * const unsigned int nValue [IN] 想要设置的相机宽度的值,注意此宽度值必须是MV_CC_GetWidth接口返回的pstValue中的nInc的倍数才能设置成功
  793. * @return 成功,返回MV_OK,并且相机高度将会更改为相应值,失败,返回错误码
  794. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetHeight(IN void* handle, IN const unsigned int nValue);
  795. * @brief Set image height
  796. * @param void* handle [IN] Camera Handle
  797. * const unsigned int nValue [IN] Camera height value to set, note that this value must be times of nInc of pstValue returned by MV_CC_GetWidth
  798. * @return Success, return MV_OK, and the camera height will change to the corresponding value. Failure, return error code
  799. ************************************************************************/
  800. MV_CAMCTRL_API int __stdcall MV_CC_SetHeight(IN void* handle, IN const unsigned int nValue);
  801. /************************************************************************
  802. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetAOIoffsetX(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  803. * @brief 获取图像X偏移
  804. * @param void* handle [IN] 相机句柄
  805. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机X偏移的信息结构体指针
  806. * @return 成功,返回MV_OK,失败,返回错误码
  807. *
  808. * 可参照接口MV_CC_GetWidth
  809. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetAOIoffsetX(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  810. * @brief Get image X offset
  811. * @param void* handle [IN] Camera Handle
  812. * @param MVCC_INTVALUE* pstValue [IN][OUT] Return pointer of information structure related to camera X offset to user
  813. * @return Success, return MV_OK. Failure, return error code
  814. *
  815. * Refer to MV_CC_GetWidth
  816. ************************************************************************/
  817. MV_CAMCTRL_API int __stdcall MV_CC_GetAOIoffsetX(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  818. /************************************************************************
  819. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetAOIoffsetX(IN void* handle, IN const unsigned int nValue);
  820. * @brief 设置图像AOI偏移
  821. * @param void* handle [IN] 相机句柄
  822. * const unsigned int nValue [IN] 想要设置的相机AOI的值
  823. * @return 成功,返回MV_OK,并且相机AOI偏移将会更改为相应值,失败,返回错误码
  824. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetAOIoffsetX(IN void* handle, IN const unsigned int nValue);
  825. * @brief Set image X offset
  826. * @param void* handle [IN] Camera Handle
  827. * const unsigned int nValue [IN] Camera X offset value to set
  828. * @return Success, return MV_OK, and the camera X offset will change to the corresponding value. Failure, return error code
  829. ************************************************************************/
  830. MV_CAMCTRL_API int __stdcall MV_CC_SetAOIoffsetX(IN void* handle, IN const unsigned int nValue);
  831. /************************************************************************
  832. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetAOIoffsetY(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  833. * @brief 获取图像Y偏移
  834. * @param void* handle [IN] 相机句柄
  835. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机Y偏移的信息结构体指针
  836. * @return 成功,返回MV_OK,失败,返回错误码
  837. *
  838. * 可参照接口MV_CC_GetWidth
  839. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetAOIoffsetY(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  840. * @brief Get image Y offset
  841. * @param void* handle [IN] Camera Handle
  842. * @param MVCC_INTVALUE* pstValue [IN][OUT] Return pointer of information structure related to camera Y offset to user
  843. * @return Success, return MV_OK. Failure, return error code
  844. *
  845. * Refer to MV_CC_GetWidth
  846. ************************************************************************/
  847. MV_CAMCTRL_API int __stdcall MV_CC_GetAOIoffsetY(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  848. /************************************************************************
  849. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetAOIoffsetX(IN void* handle, IN const unsigned int nValue);
  850. * @brief 设置图像AOI偏移
  851. * @param void* handle [IN] 相机句柄
  852. * const unsigned int nValue [IN] 想要设置的相机AOI的值
  853. * @return 成功,返回MV_OK,并且相机AOI偏移将会更改为相应值,失败,返回错误码
  854. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetAOIoffsetY(IN void* handle, IN const unsigned int nValue);
  855. * @brief Set image Y offset
  856. * @param void* handle [IN] Camera Handle
  857. * const unsigned int nValue [IN] Camera Y offset value to set
  858. * @return Success, return MV_OK, and the camera Y offset will change to the corresponding value. Failure, return error code
  859. ************************************************************************/
  860. MV_CAMCTRL_API int __stdcall MV_CC_SetAOIoffsetY(IN void* handle, IN const unsigned int nValue);
  861. /************************************************************************
  862. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetAutoExposureTimeLower(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  863. * @brief 获取曝光下限
  864. * @param void* handle [IN] 相机句柄
  865. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机曝光值下限结构体指针
  866. * @return 成功,返回MV_OK,失败,返回错误码
  867. *
  868. * 可参照接口MV_CC_GetWidth
  869. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetAutoExposureTimeLower(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  870. * @brief Get exposure lower limit
  871. * @param void* handle [IN] Camera Handle
  872. * @param MVCC_INTVALUE* pstValue [IN][OUT] Return pointer of information structure related to camera exposure lower to user
  873. * @return Success, return MV_OK. Failure, return error code
  874. *
  875. * Refer to MV_CC_GetWidth
  876. ************************************************************************/
  877. MV_CAMCTRL_API int __stdcall MV_CC_GetAutoExposureTimeLower(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  878. /************************************************************************
  879. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetAutoExposureTimeLower(IN void* handle, IN const unsigned int nValue);
  880. * @brief 设置曝光值下限
  881. * @param void* handle [IN] 相机句柄
  882. * const unsigned int nValue [IN] 想要设置的曝光值下限
  883. * @return 成功,返回MV_OK,并且相机曝光下限将会更改为相应值,失败,返回错误码
  884. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetAutoExposureTimeLower(IN void* handle, IN const unsigned int nValue);
  885. * @brief Set exposure lower limit
  886. * @param void* handle [IN] Camera Handle
  887. * const unsigned int nValue [IN] Exposure lower to set
  888. * @return Success, return MV_OK, and the camera exposure time lower limit value will change to the corresponding value. Failure, return error code
  889. ************************************************************************/
  890. MV_CAMCTRL_API int __stdcall MV_CC_SetAutoExposureTimeLower(IN void* handle, IN const unsigned int nValue);
  891. /************************************************************************
  892. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetAutoExposureTimeUpper(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  893. * @brief 获取曝光上限
  894. * @param void* handle [IN] 相机句柄
  895. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机曝光值上限结构体指针
  896. * @return 成功,返回MV_OK,失败,返回错误码
  897. *
  898. * 可参照接口MV_CC_GetWidth
  899. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetAutoExposureTimeUpper(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  900. * @brief Get exposure upper limit
  901. * @param void* handle [IN] Camera Handle
  902. * @param MVCC_INTVALUE* pstValue [IN][OUT] Return pointer of information structure related to camera exposure upper to user
  903. * @return Success, return MV_OK. Failure, return error code
  904. *
  905. * Refer to MV_CC_GetWidth
  906. ************************************************************************/
  907. MV_CAMCTRL_API int __stdcall MV_CC_GetAutoExposureTimeUpper(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  908. /************************************************************************
  909. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetAutoExposureTimeUpper(IN void* handle, IN const unsigned int nValue);
  910. * @brief 设置曝光值上限
  911. * @param void* handle [IN] 相机句柄
  912. * const unsigned int nValue [IN] 想要设置的曝光值上限
  913. * @return 成功,返回MV_OK,并且相机曝光上限将会更改为相应值,失败,返回错误码
  914. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetAutoExposureTimeUpper(IN void* handle, IN const unsigned int nValue);
  915. * @brief Set exposure upper limit
  916. * @param void* handle [IN] Camera Handle
  917. * const unsigned int nValue [IN] Exposure upper to set
  918. * @return Success, return MV_OK, and the camera exposure time upper limit value will change to the corresponding value. Failure, return error code
  919. ************************************************************************/
  920. MV_CAMCTRL_API int __stdcall MV_CC_SetAutoExposureTimeUpper(IN void* handle, IN const unsigned int nValue);
  921. /************************************************************************
  922. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetBrightness(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  923. * @brief 获取亮度值
  924. * @param void* handle [IN] 相机句柄
  925. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机亮度结构体指针
  926. * @return 成功,返回MV_OK,失败,返回错误码
  927. *
  928. * 可参照接口MV_CC_GetWidth
  929. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetBrightness(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  930. * @brief Get brightness
  931. * @param void* handle [IN] Camera Handle
  932. * @param MVCC_INTVALUE* pstValue [IN][OUT] Return pointer of information structure related to camera brightness to user
  933. * @return Success, return MV_OK. Failure, return error code
  934. *
  935. * Refer to MV_CC_GetWidth
  936. ************************************************************************/
  937. MV_CAMCTRL_API int __stdcall MV_CC_GetBrightness(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  938. /************************************************************************
  939. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetBrightness(IN void* handle, IN const unsigned int nValue);
  940. * @brief 设置亮度值
  941. * @param void* handle [IN] 相机句柄
  942. * const unsigned int nValue [IN] 想要设置的亮度值
  943. * @return 成功,返回MV_OK,并且相机亮度将会更改为相应值,失败,返回错误码
  944. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetBrightness(IN void* handle, IN const unsigned int nValue);
  945. * @brief Set brightness
  946. * @param void* handle [IN] Camera Handle
  947. * const unsigned int nValue [IN] Brightness upper to set
  948. * @return Success, return MV_OK, and the camera brightness value will change to the corresponding value. Failure, return error code
  949. ************************************************************************/
  950. MV_CAMCTRL_API int __stdcall MV_CC_SetBrightness(IN void* handle, IN const unsigned int nValue);
  951. /************************************************************************
  952. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetFrameRate(IN void* handle, IN OUT MVCC_FLOATVALUE* pstValue);
  953. * @brief 获取帧率
  954. * @param void* handle [IN] 相机句柄
  955. * MVCC_FLOATVALUE* pstValue [IN][OUT] 返回给调用者有关相机帧率的信息结构体指针
  956. * 返回的pstValue结构体的意义
  957. * float fCurValue; // 表示相机当前的帧率
  958. * float fMax; // 表示相机允许设置的最大帧率
  959. * float fMin; // 表示相机允许设置的最小帧率
  960. * @return 成功,返回MV_OK,并获得相应参数信息的结构体, 失败, 返回错误码
  961. *
  962. * 其他浮点型结构体参数的接口可参照此接口
  963. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetFrameRate(IN void* handle, IN OUT MVCC_FLOATVALUE* pstValue);
  964. * @brief Get Frame Rate
  965. * @param void* handle [IN] Camera Handle
  966. * MVCC_FLOATVALUE* pstValue [IN][OUT] Return pointer of information structure related to camera frame rate to user
  967. * The meaning of returns pstValue structure
  968. * float fCurValue; // Indicates the current frame rate of the camera
  969. * float fMax; // Indicates the maximum frame rate allowed by the camera
  970. * float fMin; // Indicates the minimum frame rate allowed by the camera
  971. * @return Success, return MV_OK, and get the structure of the corresponding parameters. Failure, return error code
  972. *
  973. * Other interface of Float structure parameters can refer to this interface
  974. ************************************************************************/
  975. MV_CAMCTRL_API int __stdcall MV_CC_GetFrameRate(IN void* handle, IN OUT MVCC_FLOATVALUE* pstValue);
  976. /************************************************************************
  977. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetFrameRate(IN void* handle, IN const float fValue);
  978. * @brief 设置帧率
  979. * @param void* handle [IN] 相机句柄
  980. * const float fValue [IN] 想要设置的相机帧率
  981. * @return 成功,返回MV_OK,并且相机帧率将会更改为相应值,失败,返回错误码
  982. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetFrameRate(IN void* handle, IN const float fValue);
  983. * @brief Set frame rate
  984. * @param void* handle [IN] Camera Handle
  985. * const float fValue [IN] Camera frame rate to set
  986. * @return Success, return MV_OK, and camera frame rate will be changed to the corresponding value. Failure, return error code
  987. ************************************************************************/
  988. MV_CAMCTRL_API int __stdcall MV_CC_SetFrameRate(IN void* handle, IN const float fValue);
  989. /************************************************************************
  990. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetGain(IN void* handle, IN OUT MVCC_FLOATVALUE* pstValue);
  991. * @brief 获取增益
  992. * @param void* handle [IN] 相机句柄
  993. * MVCC_FLOATVALUE* pstValue [IN][OUT] 返回给调用者有关相机增益的信息结构体指针
  994. * 返回的pstValue结构体的意义
  995. * float fCurValue; // 表示相机当前的帧率
  996. * float fMax; // 表示相机允许设置的最大帧率
  997. * float fMin; // 表示相机允许设置的最小帧率
  998. * @return 成功,返回MV_OK,并获得相应参数信息的结构体, 失败, 返回错误码
  999. *
  1000. * 其他浮点型结构体参数的接口可参照此接口
  1001. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetGain(IN void* handle, IN OUT MVCC_FLOATVALUE* pstValue);
  1002. * @brief Get Gain
  1003. * @param void* handle [IN] Camera Handle
  1004. * MVCC_FLOATVALUE* pstValue [IN][OUT] Return pointer of information structure related to gain to user
  1005. * @return Success, return MV_OK, and get the structure of the corresponding parameters. Failure, return error code
  1006. * float fCurValue; // Camera current gain
  1007. * float fMax; // The maximum gain camera allowed
  1008. * float fMin; // The minimum gain camera allowed
  1009. * @return Success, return MV_OK, and get the structure of the corresponding parameters. Failure, return error code
  1010. *
  1011. * Other interface of Float structure parameters can refer to this interface
  1012. ************************************************************************/
  1013. MV_CAMCTRL_API int __stdcall MV_CC_GetGain(IN void* handle, IN OUT MVCC_FLOATVALUE* pstValue);
  1014. /************************************************************************
  1015. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetGain(IN void* handle, IN const float fValue);
  1016. * @brief 设置帧率
  1017. * @param void* handle [IN] 相机句柄
  1018. * const float fValue [IN] 想要设置的相机帧率
  1019. * @return 成功,返回MV_OK,并且相机帧率将会更改为相应值,失败,返回错误码
  1020. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetGain(IN void* handle, IN const float fValue);
  1021. * @brief Set Gain
  1022. * @param void* handle [IN] Camera Handle
  1023. * const float fValue [IN] Gain value to set
  1024. * @return Success, return MV_OK, and the camera gain value will change to the corresponding value. Failure, return error code
  1025. ************************************************************************/
  1026. MV_CAMCTRL_API int __stdcall MV_CC_SetGain(IN void* handle, IN const float fValue);
  1027. /************************************************************************
  1028. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetExposureTime(IN void* handle, IN OUT MVCC_FLOATVALUE* pstValue);
  1029. * @brief 获取曝光时间
  1030. * @param void* handle [IN] 相机句柄
  1031. * MVCC_FLOATVALUE* pstValue [IN][OUT] 返回给调用者有关相机曝光时间的信息结构体指针
  1032. * 返回的pstValue结构体的意义
  1033. * float fCurValue; // 表示相机当前的帧率
  1034. * float fMax; // 表示相机允许设置的最大帧率
  1035. * float fMin; // 表示相机允许设置的最小帧率
  1036. * @return 成功,返回MV_OK,并获得相应参数信息的结构体, 失败, 返回错误码
  1037. *
  1038. * 其他浮点型结构体参数的接口可参照此接口
  1039. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetExposureTime(IN void* handle, IN OUT MVCC_FLOATVALUE* pstValue);
  1040. * @brief Get exposure time
  1041. * @param void* handle [IN] Camera Handle
  1042. * MVCC_FLOATVALUE* pstValue [IN][OUT] Return pointer of information structure related to exposure time to user
  1043. * @return Success, return MV_OK, and get the structure of the corresponding parameters. Failure, return error code
  1044. * float fCurValue; // Camera current exposure time
  1045. * float fMax; // The maximum exposure time camera allowed
  1046. * float fMin; // The minimum exposure time camera allowed
  1047. * @return Success, return MV_OK, and get the structure of the corresponding parameters. Failure, return error code
  1048. *
  1049. * Other interface of Float structure parameters can refer to this interface
  1050. ************************************************************************/
  1051. MV_CAMCTRL_API int __stdcall MV_CC_GetExposureTime(IN void* handle, IN OUT MVCC_FLOATVALUE* pstValue);
  1052. /************************************************************************
  1053. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetExposureTime(IN void* handle, IN const float fValue);
  1054. * @brief 设置曝光时间
  1055. * @param void* handle [IN] 相机句柄
  1056. * const float fValue [IN] 想要设置的相机帧率
  1057. * @return 成功,返回MV_OK,并且相机帧率将会更改为相应值,失败,返回错误码
  1058. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetExposureTime(IN void* handle, IN const float fValue);
  1059. * @brief Set exposure time
  1060. * @param void* handle [IN] Camera Handle
  1061. * const float fValue [IN] Exposure time to set
  1062. * @return Success, return MV_OK, and the camera exposure time value will change to the corresponding value. Failure, return error code
  1063. ************************************************************************/
  1064. MV_CAMCTRL_API int __stdcall MV_CC_SetExposureTime(IN void* handle, IN const float fValue);
  1065. /************************************************************************
  1066. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetPixelFormat(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1067. * @brief 获取像素格式
  1068. * @param void* handle [IN] 相机句柄
  1069. * MVCC_ENUMVALUE* pstValue [IN][OUT] 返回给调用者的有关像素格式的信息结构体指针
  1070. * 返回的pstValue结构体的意义
  1071. * unsigned int nCurValue; // 相机当前的像素格式,是枚举类型,比如说PixelType_Gvsp_Mono8, 这里获得的是其整型值,具体数值参照PixelType.h的MvGvspPixelType枚举类型
  1072. * unsigned int nSupportedNum; // 相机支持的像素格式的个数
  1073. * unsigned int nSupportValue[MV_MAX_XML_SYMBOLIC_NUM]; // 相机所有支持的像素格式对应的整型值列表,后面要设置像素格式时,参数必须是这个数组中的一种,否则无效
  1074. * @return 成功,返回MV_OK,并获得相应参数信息的结构体, 失败, 返回错误码
  1075. *
  1076. 其他枚举类型参数接口可参照此接口,有关相应参数的枚举类型对应的整型值请查找PixelType.h 和 CameraParams.h中相应的定义
  1077. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetPixelFormat(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1078. * @brief Get Pixel Format
  1079. * @param void* handle [IN] Camera Handle
  1080. * MVCC_ENUMVALUE* pstValue [IN][OUT] Returns the information structure pointer about pixel format for the caller
  1081. * The meaning of returns pstValue structure
  1082. * unsigned int nCurValue; // The current pixel format of the camera, is the enumeration type, such as PixelType_Gvsp_Mono8, here is the integer value, the specific value please refer to MvGvspPixelType enumeration type in PixelType.h
  1083. * unsigned int nSupportedNum; // Number of pixel formats supported by the camera
  1084. * unsigned int nSupportValue[MV_MAX_XML_SYMBOLIC_NUM]; // The integer values list correspond to all supported pixel formats of the camera, followed by when set the pixel format, the parameter must be one of this list, otherwise invalid
  1085. * @return Success, return MV_OK, and get the structure of the corresponding parameters. Failure, return error code
  1086. *
  1087. Other interface of Enumeration structure parameters can refer to this interface, look for the corresponding definition in PixelType.h and CameraParams.h for the integer values of the enum type parameter
  1088. ************************************************************************/
  1089. MV_CAMCTRL_API int __stdcall MV_CC_GetPixelFormat(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1090. /************************************************************************
  1091. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetPixelFormat(IN void* handle, IN const unsigned int nValue);
  1092. * @brief 设置像素格式
  1093. * @param void* handle [IN] 相机句柄
  1094. * const unsigned int nValue [IN] 要设置的像素格式对应的整型值,调用此接口时可以直接填写枚举值,如MV_CC_SetPixelFormat(m_handle, PixelType_Gvsp_RGB8_Packed);
  1095. * @return 成功,返回MV_OK,并且相机像素格式将会更改为相应值,失败,返回错误码
  1096. *
  1097. * 要设置的枚举类型必须是Get接口返回的nSupportValue[MV_MAX_XML_SYMBOLIC_NUM]中的一种,否则会失败
  1098. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetPixelFormat(IN void* handle, IN const unsigned int nValue);
  1099. * @brief Set Pixel Format
  1100. * @param void* handle [IN] Camera Handle
  1101. * const unsigned int nValue [IN] The corresponding integer value for pixel format to be set, when calling this interface can be directly filled in enumeration values, such as MV_CC_SetPixelFormat(m_handle, PixelType_Gvsp_RGB8_Packed);
  1102. * @return Success, return MV_OK, and the camera pixel format will change to the corresponding value. Failure, return error code
  1103. *
  1104. * Other interface of Enumeration structure parameters can refer to this interface, the enumeration type to be set must be one of the nSupportValue [MV_MAX_XML_SYMBOLIC_NUM] returned by the Get interface, otherwise it will fail
  1105. ************************************************************************/
  1106. MV_CAMCTRL_API int __stdcall MV_CC_SetPixelFormat(IN void* handle, IN const unsigned int nValue);
  1107. /************************************************************************
  1108. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetAcquisitionMode(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1109. * @brief 获取采集模式
  1110. * @param void* handle [IN] 相机句柄
  1111. * MVCC_ENUMVALUE* pstValue [IN][OUT] 返回给调用者的有关采集模式的信息结构体指针
  1112. * @return 成功,返回MV_OK,并获得相应参数信息的结构体, 失败, 返回错误码
  1113. *
  1114. 可参照接口MV_CC_GetPixelFormat,参考 CameraParam.h 中的 MV_CAM_ACQUISITION_MODE 定义
  1115. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetAcquisitionMode(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1116. * @brief Get acquisition mode
  1117. * @param void* handle [IN] Handle
  1118. * MVCC_ENUMVALUE* pstValue [IN][OUT] Structure pointer of acquisition mode
  1119. * @return Success, return MV_OK, and get the structure of the corresponding parameters. Failure, return error code
  1120. *
  1121. Refer to MV_CC_GetPixelFormat and definition of MV_CAM_ACQUISITION_MODE in CameraParam.h
  1122. ************************************************************************/
  1123. MV_CAMCTRL_API int __stdcall MV_CC_GetAcquisitionMode(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1124. /************************************************************************
  1125. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetAcquisitionMode(IN void* handle, IN const unsigned int nValue);
  1126. * @brief 设置像素格式
  1127. * @param void* handle [IN] 相机句柄
  1128. * const unsigned int nValue [IN] 要设置的采集模式对应的整型值
  1129. * @return 成功,返回MV_OK,并且相机采集模式将会更改为相应值,失败,返回错误码
  1130. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetAcquisitionMode(IN void* handle, IN const unsigned int nValue);
  1131. * @brief Set acquisition mode
  1132. * @param void* handle [IN] Handle
  1133. * const unsigned int nValue [IN] Integer value to set corresponding to acquisition mode
  1134. * @return Success, return MV_OK, and the camera acquisition mode will change to the corresponding value. Failure, return error code
  1135. ************************************************************************/
  1136. MV_CAMCTRL_API int __stdcall MV_CC_SetAcquisitionMode(IN void* handle, IN const unsigned int nValue);
  1137. /************************************************************************
  1138. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetGainMode(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1139. * @brief 获取增益模式
  1140. * @param void* handle [IN] 相机句柄
  1141. * MVCC_ENUMVALUE* pstValue [IN][OUT] 返回给调用者的有关增益模式的信息结构体指针
  1142. * @return 成功,返回MV_OK,并获得相应参数信息的结构体, 失败, 返回错误码
  1143. *
  1144. 可参照接口MV_CC_GetPixelFormat,参考 CameraParam.h 中的 MV_CAM_GAIN_MODE 定义
  1145. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetGainMode(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1146. * @brief Get gain mode
  1147. * @param void* handle [IN] Handle
  1148. * MVCC_ENUMVALUE* pstValue [IN][OUT] Structure pointer of gain mode
  1149. * @return Success, return MV_OK, and get the structure of the corresponding parameters. Failure, return error code
  1150. *
  1151. Refer to MV_CC_GetPixelFormat and definition of MV_CAM_GAIN_MODE in CameraParam.h
  1152. ************************************************************************/
  1153. MV_CAMCTRL_API int __stdcall MV_CC_GetGainMode(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1154. /************************************************************************
  1155. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetGainMode(IN void* handle, IN const unsigned int nValue);
  1156. * @brief 设置增益模式
  1157. * @param void* handle [IN] 相机句柄
  1158. * const unsigned int nValue [IN] 要设置的增益模式对应的整型值
  1159. * @return 成功,返回MV_OK,并且相机增益模式将会更改为相应值,失败,返回错误码
  1160. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetGainMode(IN void* handle, IN const unsigned int nValue);
  1161. * @brief Set gain mode
  1162. * @param void* handle [IN] Handle
  1163. * const unsigned int nValue [IN] Integer value to set corresponding to gain mode
  1164. * @return Success, return MV_OK, and the camera gain mode will change to the corresponding value. Failure, return error code
  1165. ************************************************************************/
  1166. MV_CAMCTRL_API int __stdcall MV_CC_SetGainMode(IN void* handle, IN const unsigned int nValue);
  1167. /************************************************************************
  1168. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetExposureAutoMode(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1169. * @brief 获取自动曝光模式
  1170. * @param void* handle [IN] 相机句柄
  1171. * MVCC_ENUMVALUE* pstValue [IN][OUT] 返回给调用者的有关自动曝光模式的信息结构体指针
  1172. * @return 成功,返回MV_OK,并获得相应参数信息的结构体, 失败, 返回错误码
  1173. *
  1174. 可参照接口MV_CC_GetPixelFormat,参考 CameraParam.h 中的 MV_CAM_EXPOSURE_AUTO_MODE 定义
  1175. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetExposureAutoMode(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1176. * @brief Get auto exposure mode
  1177. * @param void* handle [IN] Handle
  1178. * MVCC_ENUMVALUE* pstValue [IN][OUT] Structure pointer of auto exposure mode
  1179. * @return Success, return MV_OK, and get the structure of the corresponding parameters. Failure, return error code
  1180. *
  1181. Refer to MV_CC_GetPixelFormat and definition of MV_CAM_EXPOSURE_AUTO_MODE in CameraParam.h
  1182. ************************************************************************/
  1183. MV_CAMCTRL_API int __stdcall MV_CC_GetExposureAutoMode(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1184. /************************************************************************
  1185. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetExposureAutoMode(IN void* handle, IN const unsigned int nValue);
  1186. * @brief 设置自动曝光模式
  1187. * @param void* handle [IN] 相机句柄
  1188. * const unsigned int nValue [IN] 要设置的自动曝光模式对应的整型值
  1189. * @return 成功,返回MV_OK,并且相机自动曝光模式将会更改为相应值,失败,返回错误码
  1190. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetExposureAutoMode(IN void* handle, IN const unsigned int nValue);
  1191. * @brief Set auto exposure mode
  1192. * @param void* handle [IN] Handle
  1193. * const unsigned int nValue [IN] Integer value to set corresponding to auto exposure mode
  1194. * @return Success, return MV_OK, and the camera auto exposure mode will change to the corresponding value. Failure, return error code
  1195. ************************************************************************/
  1196. MV_CAMCTRL_API int __stdcall MV_CC_SetExposureAutoMode(IN void* handle, IN const unsigned int nValue);
  1197. /************************************************************************
  1198. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetTriggerMode(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1199. * @brief 获取触发模式
  1200. * @param void* handle [IN] 相机句柄
  1201. * MVCC_ENUMVALUE* pstValue [IN][OUT] 返回给调用者的有关触发模式的信息结构体指针
  1202. * @return 成功,返回MV_OK,并获得相应参数信息的结构体, 失败, 返回错误码
  1203. *
  1204. 可参照接口MV_CC_GetPixelFormat,参考 CameraParam.h 中的 MV_CAM_TRIGGER_MODE 定义
  1205. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetTriggerMode(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1206. * @brief Get trigger mode
  1207. * @param void* handle [IN] Handle
  1208. * MVCC_ENUMVALUE* pstValue [IN][OUT] Structure pointer of trigger mode
  1209. * @return Success, return MV_OK, and get the structure of the corresponding parameters. Failure, return error code
  1210. *
  1211. Refer to MV_CC_GetPixelFormat and definition of MV_CAM_TRIGGER_MODE in CameraParam.h
  1212. ************************************************************************/
  1213. MV_CAMCTRL_API int __stdcall MV_CC_GetTriggerMode(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1214. /************************************************************************
  1215. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetTriggerMode(IN void* handle, IN const unsigned int nValue);
  1216. * @brief 设置触发模式
  1217. * @param void* handle [IN] 相机句柄
  1218. * const unsigned int nValue [IN] 要设置的触发模式对应的整型值
  1219. * @return 成功,返回MV_OK,并且相机触发模式将会更改为相应值,失败,返回错误码
  1220. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetTriggerMode(IN void* handle, IN const unsigned int nValue);
  1221. * @brief Set trigger mode
  1222. * @param void* handle [IN] Handle
  1223. * const unsigned int nValue [IN] Integer value to set corresponding to trigger mode
  1224. * @return Success, return MV_OK, and the camera trigger mode will change to the corresponding value. Failure, return error code
  1225. ************************************************************************/
  1226. MV_CAMCTRL_API int __stdcall MV_CC_SetTriggerMode(IN void* handle, IN const unsigned int nValue);
  1227. /************************************************************************
  1228. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetTriggerDelay(IN void* handle, IN OUT MVCC_FLOATVALUE* pstValue);
  1229. * @brief 获取触发延时
  1230. * @param void* handle [IN] 相机句柄
  1231. * MVCC_FLOATVALUE* pstValue [IN][OUT] 返回给调用者有关相机触发延时的信息结构体指针
  1232. * @return 成功,返回MV_OK,并获得相应参数信息的结构体, 失败, 返回错误码
  1233. *
  1234. * 可参照接口MV_CC_GetFrameRate
  1235. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetTriggerDelay(IN void* handle, IN OUT MVCC_FLOATVALUE* pstValue);
  1236. * @brief Get tigger delay
  1237. * @param void* handle [IN] Handle
  1238. * MVCC_FLOATVALUE* pstValue [IN][OUT] Structure pointer of trigger delay
  1239. * @return Success, return MV_OK, and get the structure of the corresponding parameters. Failure, return error code
  1240. *
  1241. * Refer to MV_CC_GetFrameRate
  1242. ************************************************************************/
  1243. MV_CAMCTRL_API int __stdcall MV_CC_GetTriggerDelay(IN void* handle, IN OUT MVCC_FLOATVALUE* pstValue);
  1244. /************************************************************************
  1245. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetTriggerDelay(IN void* handle, IN const float fValue);
  1246. * @brief 设置触发延时
  1247. * @param void* handle [IN] 相机句柄
  1248. * const float fValue [IN] 想要设置的相机触发延时
  1249. * @return 成功,返回MV_OK,并且相机触发延时将会更改为相应值,失败,返回错误码
  1250. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetTriggerDelay(IN void* handle, IN const float fValue);
  1251. * @brief Set tigger delay
  1252. * @param void* handle [IN] Handle
  1253. * const float fValue [IN] Trigger delay to set
  1254. * @return Success, return MV_OK, and the camera trigger delay will change to the corresponding value. Failure, return error code
  1255. ************************************************************************/
  1256. MV_CAMCTRL_API int __stdcall MV_CC_SetTriggerDelay(IN void* handle, IN const float fValue);
  1257. /************************************************************************
  1258. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetTriggerSource(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1259. * @brief 获取触发源
  1260. * @param void* handle [IN] 相机句柄
  1261. * MVCC_ENUMVALUE* pstValue [IN][OUT] 返回给调用者的有关触发源的信息结构体指针
  1262. * @return 成功,返回MV_OK,并获得相应参数信息的结构体, 失败, 返回错误码
  1263. *
  1264. 可参照接口MV_CC_GetPixelFormat,参考 CameraParam.h 中的 MV_CAM_TRIGGER_SOURCE 定义
  1265. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetTriggerSource(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1266. * @brief Get trigger source
  1267. * @param void* handle [IN] Handle
  1268. * MVCC_ENUMVALUE* pstValue [IN][OUT] Structure pointer of trigger source
  1269. * @return Success, return MV_OK, and get the structure of the corresponding parameters. Failure, return error code
  1270. *
  1271. Refer to MV_CC_GetPixelFormat and definition of MV_CAM_TRIGGER_SOURCE in CameraParam.h
  1272. ************************************************************************/
  1273. MV_CAMCTRL_API int __stdcall MV_CC_GetTriggerSource(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1274. /************************************************************************
  1275. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetTriggerSource(IN void* handle, IN const unsigned int nValue);
  1276. * @brief 设置触发源
  1277. * @param void* handle [IN] 相机句柄
  1278. * const unsigned int nValue [IN] 要设置的触发源对应的整型值
  1279. * @return 成功,返回MV_OK,并且相机触发源将会更改为相应值,失败,返回错误码
  1280. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetTriggerSource(IN void* handle, IN const unsigned int nValue);
  1281. * @brief Set trigger source
  1282. * @param void* handle [IN] Handle
  1283. * const unsigned int nValue [IN] Integer value to set corresponding to trigger source
  1284. * @return Success, return MV_OK, and the camera trigger source will change to the corresponding value. Failure, return error code
  1285. ************************************************************************/
  1286. MV_CAMCTRL_API int __stdcall MV_CC_SetTriggerSource(IN void* handle, IN const unsigned int nValue);
  1287. /************************************************************************
  1288. * @fn MV_CAMCTRL_API int __stdcall MV_CC_TriggerSoftwareExecute(IN void* handle);
  1289. * @brief 软触发一次(接口仅在已选择的触发源为软件触发时有效)
  1290. * @param void* handle [IN] 相机句柄
  1291. * @return 成功,返回MV_OK, 失败,返回错误码
  1292. * @fn MV_CAMCTRL_API int __stdcall MV_CC_TriggerSoftwareExecute(IN void* handle);
  1293. * @brief Execute software trigger once (this interface only valid when the trigger source is set to software)
  1294. * @param void* handle [IN] Handle
  1295. * @return Success, return MV_OK. Failure, return error code
  1296. ************************************************************************/
  1297. MV_CAMCTRL_API int __stdcall MV_CC_TriggerSoftwareExecute(IN void* handle);
  1298. /************************************************************************
  1299. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetGammaSelector(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1300. * @brief 获取Gamma类型
  1301. * @param void* handle [IN] 相机句柄
  1302. * MVCC_ENUMVALUE* pstValue [IN][OUT] 返回给调用者的有关Gamma类型的信息结构体指针
  1303. * @return 成功,返回MV_OK,并获得相应参数信息的结构体, 失败, 返回错误码
  1304. *
  1305. 可参照接口MV_CC_GetPixelFormat,参考 CameraParam.h 中的 MV_CAM_GAMMA_SELECTOR 定义
  1306. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetGammaSelector(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1307. * @brief Get Gamma mode
  1308. * @param void* handle [IN] Handle
  1309. * MVCC_ENUMVALUE* pstValue [IN][OUT] Structure pointer of gamma mode
  1310. * @return Success, return MV_OK, and get the structure of the corresponding parameters. Failure, return error code
  1311. *
  1312. Refer to MV_CC_GetPixelFormat and definition of MV_CAM_GAMMA_SELECTOR in CameraParam.h
  1313. ************************************************************************/
  1314. MV_CAMCTRL_API int __stdcall MV_CC_GetGammaSelector(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1315. /************************************************************************
  1316. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetGammaSelector(IN void* handle, IN const unsigned int nValue);
  1317. * @brief 设置Gamma类型
  1318. * @param void* handle [IN] 相机句柄
  1319. * const unsigned int nValue [IN] 要设置的Gamma类型对应的整型值
  1320. * @return 成功,返回MV_OK,并且相机Gamma类型将会更改为相应值,失败,返回错误码
  1321. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetGammaSelector(IN void* handle, IN const unsigned int nValue);
  1322. * @brief Set Gamma mode
  1323. * @param void* handle [IN] Handle
  1324. * const unsigned int nValue [IN] Integer value to set corresponding to gamma mode
  1325. * @return Success, return MV_OK, and the camera gamma mode will change to the corresponding value. Failure, return error code
  1326. ************************************************************************/
  1327. MV_CAMCTRL_API int __stdcall MV_CC_SetGammaSelector(IN void* handle, IN const unsigned int nValue);
  1328. /************************************************************************
  1329. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetGamma(IN void* handle, IN OUT MVCC_FLOATVALUE* pstValue);
  1330. * @brief 获取Gamma值
  1331. * @param void* handle [IN] 相机句柄
  1332. * MVCC_FLOATVALUE* pstValue [IN][OUT] 返回给调用者有关相机Gamma值的信息结构体指针
  1333. * @return 成功,返回MV_OK,并获得相应参数信息的结构体, 失败, 返回错误码
  1334. *
  1335. * 可参照接口MV_CC_GetFrameRate
  1336. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetGamma(IN void* handle, IN OUT MVCC_FLOATVALUE* pstValue);
  1337. * @brief Get Gamma value
  1338. * @param void* handle [IN] Handle
  1339. * MVCC_FLOATVALUE* pstValue [IN][OUT] Structure pointer of gamma value
  1340. * @return Success, return MV_OK, and get the structure of the corresponding parameters. Failure, return error code
  1341. *
  1342. * Refer to MV_CC_GetFrameRate
  1343. ************************************************************************/
  1344. MV_CAMCTRL_API int __stdcall MV_CC_GetGamma(IN void* handle, IN OUT MVCC_FLOATVALUE* pstValue);
  1345. /************************************************************************
  1346. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetGamma(IN void* handle, IN const float fValue);
  1347. * @brief 设置Gamma值
  1348. * @param void* handle [IN] 相机句柄
  1349. * const float fValue [IN] 想要设置的相机Gamma值
  1350. * @return 成功,返回MV_OK,并且相机Gamma值将会更改为相应值,失败,返回错误码
  1351. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetGamma(IN void* handle, IN const float fValue);
  1352. * @brief Set Gamma value
  1353. * @param void* handle [IN] Handle
  1354. * const float fValue [IN] Gamma value to set
  1355. * @return Success, return MV_OK, and the camera gamma value will change to the corresponding value. Failure, return error code
  1356. ************************************************************************/
  1357. MV_CAMCTRL_API int __stdcall MV_CC_SetGamma(IN void* handle, IN const float fValue);
  1358. /************************************************************************
  1359. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetSharpness(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1360. * @brief 获取锐度
  1361. * @param void* handle [IN] 相机句柄
  1362. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机锐度结构体指针
  1363. * @return 成功,返回MV_OK,失败,返回错误码
  1364. *
  1365. * 可参照接口MV_CC_GetWidth
  1366. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetSharpness(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1367. * @brief Get sharpness
  1368. * @param void* handle [IN] Handle
  1369. * @param MVCC_INTVALUE* pstValue [IN][OUT] Structure pointer of sharpness
  1370. * @return Success, return MV_OK. Failure, return error code
  1371. *
  1372. * Refer to MV_CC_GetWidth
  1373. ************************************************************************/
  1374. MV_CAMCTRL_API int __stdcall MV_CC_GetSharpness(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1375. /************************************************************************
  1376. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetSharpness(IN void* handle, IN const unsigned int nValue);
  1377. * @brief 设置锐度
  1378. * @param void* handle [IN] 相机句柄
  1379. * const unsigned int nValue [IN] 想要设置的锐度
  1380. * @return 成功,返回MV_OK,并且相机锐度将会更改为相应值,失败,返回错误码
  1381. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetSharpness(IN void* handle, IN const unsigned int nValue);
  1382. * @brief Set sharpness
  1383. * @param void* handle [IN] Handle
  1384. * const unsigned int nValue [IN] Sharpness to set
  1385. * @return Success, return MV_OK, and the camera sharpness will change to the corresponding value. Failure, return error code
  1386. ************************************************************************/
  1387. MV_CAMCTRL_API int __stdcall MV_CC_SetSharpness(IN void* handle, IN const unsigned int nValue);
  1388. /************************************************************************
  1389. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetHue(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1390. * @brief 获取灰度
  1391. * @param void* handle [IN] 相机句柄
  1392. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机灰度结构体指针
  1393. * @return 成功,返回MV_OK,失败,返回错误码
  1394. *
  1395. * 可参照接口MV_CC_GetWidth
  1396. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetHue(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1397. * @brief Get Hue
  1398. * @param void* handle [IN] Handle
  1399. * @param MVCC_INTVALUE* pstValue [IN][OUT] Structure pointer of Hue
  1400. * @return Success, return MV_OK. Failure, return error code
  1401. *
  1402. * Refer to MV_CC_GetWidth
  1403. ************************************************************************/
  1404. MV_CAMCTRL_API int __stdcall MV_CC_GetHue(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1405. /************************************************************************
  1406. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetHue(IN void* handle, IN const unsigned int nValue);
  1407. * @brief 设置灰度
  1408. * @param void* handle [IN] 相机句柄
  1409. * const unsigned int nValue [IN] 想要设置的灰度
  1410. * @return 成功,返回MV_OK,并且相机灰度将会更改为相应值,失败,返回错误码
  1411. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetHue(IN void* handle, IN const unsigned int nValue);
  1412. * @brief Set Hue
  1413. * @param void* handle [IN] Handle
  1414. * const unsigned int nValue [IN] Hue to set
  1415. * @return Success, return MV_OK, and the camera Hue will change to the corresponding value. Failure, return error code
  1416. ************************************************************************/
  1417. MV_CAMCTRL_API int __stdcall MV_CC_SetHue(IN void* handle, IN const unsigned int nValue);
  1418. /************************************************************************
  1419. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetSaturation(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1420. * @brief 获取饱和度
  1421. * @param void* handle [IN] 相机句柄
  1422. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机饱和度结构体指针
  1423. * @return 成功,返回MV_OK,失败,返回错误码
  1424. *
  1425. * 可参照接口MV_CC_GetWidth
  1426. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetSaturation(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1427. * @brief Get Saturation
  1428. * @param void* handle [IN] Handle
  1429. * @param MVCC_INTVALUE* pstValue [IN][OUT] Structure pointer of Saturation
  1430. * @return Success, return MV_OK. Failure, return error code
  1431. *
  1432. * Refer to MV_CC_GetWidth
  1433. ************************************************************************/
  1434. MV_CAMCTRL_API int __stdcall MV_CC_GetSaturation(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1435. /************************************************************************
  1436. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetSaturation(IN void* handle, IN const unsigned int nValue);
  1437. * @brief 设置饱和度
  1438. * @param void* handle [IN] 相机句柄
  1439. * const unsigned int nValue [IN] 想要设置的饱和度
  1440. * @return 成功,返回MV_OK,并且相机饱和度将会更改为相应值,失败,返回错误码
  1441. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetSaturation(IN void* handle, IN const unsigned int nValue);
  1442. * @brief Set Saturation
  1443. * @param void* handle [IN] Handle
  1444. * const unsigned int nValue [IN] Saturation to set
  1445. * @return Success, return MV_OK, and the camera Saturation will change to the corresponding value. Failure, return error code
  1446. ************************************************************************/
  1447. MV_CAMCTRL_API int __stdcall MV_CC_SetSaturation(IN void* handle, IN const unsigned int nValue);
  1448. /************************************************************************
  1449. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetBalanceWhiteAuto(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1450. * @brief 获取自动白平衡
  1451. * @param void* handle [IN] 相机句柄
  1452. * MVCC_ENUMVALUE* pstValue [IN][OUT] 返回给调用者的有关自动白平衡的信息结构体指针
  1453. * @return 成功,返回MV_OK,并获得相应参数信息的结构体, 失败, 返回错误码
  1454. *
  1455. 可参照接口MV_CC_GetPixelFormat,参考 CameraParam.h 中的 MV_CAM_BALANCEWHITE_AUTO 定义
  1456. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetBalanceWhiteAuto(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1457. * @brief Get Auto white balance
  1458. * @param void* handle [IN] Handle
  1459. * MVCC_ENUMVALUE* pstValue [IN][OUT] Structure pointer of auto white balance
  1460. * @return Success, return MV_OK, and get the structure of the corresponding parameters. Failure, return error code
  1461. *
  1462. Refer to MV_CC_GetPixelFormat and definition of MV_CAM_BALANCEWHITE_AUTO in CameraParam.h
  1463. ************************************************************************/
  1464. MV_CAMCTRL_API int __stdcall MV_CC_GetBalanceWhiteAuto(IN void* handle, IN OUT MVCC_ENUMVALUE* pstValue);
  1465. /************************************************************************
  1466. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetBalanceWhiteAuto(IN void* handle, IN const unsigned int nValue);
  1467. * @brief 设置自动白平衡
  1468. * @param void* handle [IN] 相机句柄
  1469. * const unsigned int nValue [IN] 要设置的自动白平衡对应的整型值
  1470. * @return 成功,返回MV_OK,并且相机自动白平衡将会更改为相应值,失败,返回错误码
  1471. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetBalanceWhiteAuto(IN void* handle, IN const unsigned int nValue);
  1472. * @brief Set Auto white balance
  1473. * @param void* handle [IN] Handle
  1474. * const unsigned int nValue [IN] Integer value to set corresponding to auto white balance
  1475. * @return Success, return MV_OK, and the camera auto white balance will change to the corresponding value. Failure, return error code
  1476. ************************************************************************/
  1477. MV_CAMCTRL_API int __stdcall MV_CC_SetBalanceWhiteAuto(IN void* handle, IN const unsigned int nValue);
  1478. /************************************************************************
  1479. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetBalanceRatioRed(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1480. * @brief 获取白平衡 红
  1481. * @param void* handle [IN] 相机句柄
  1482. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机白平衡 红结构体指针
  1483. * @return 成功,返回MV_OK,失败,返回错误码
  1484. *
  1485. * 可参照接口MV_CC_GetWidth
  1486. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetBalanceRatioRed(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1487. * @brief Get white balance red
  1488. * @param void* handle [IN] Handle
  1489. * @param MVCC_INTVALUE* pstValue [IN][OUT] Structure pointer of white balance red
  1490. * @return Success, return MV_OK. Failure, return error code
  1491. *
  1492. * Refer to MV_CC_GetWidth
  1493. ************************************************************************/
  1494. MV_CAMCTRL_API int __stdcall MV_CC_GetBalanceRatioRed(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1495. /************************************************************************
  1496. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetBalanceRatioRed(IN void* handle, IN const unsigned int nValue);
  1497. * @brief 设置白平衡 红
  1498. * @param void* handle [IN] 相机句柄
  1499. * const unsigned int nValue [IN] 想要设置的白平衡 红
  1500. * @return 成功,返回MV_OK,并且相机白平衡 红将会更改为相应值,失败,返回错误码
  1501. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetBalanceRatioRed(IN void* handle, IN const unsigned int nValue);
  1502. * @brief Set white balance red
  1503. * @param void* handle [IN] Handle
  1504. * const unsigned int nValue [IN] White balance red to set
  1505. * @return Success, return MV_OK, and the camera white balance red will change to the corresponding value. Failure, return error code
  1506. ************************************************************************/
  1507. MV_CAMCTRL_API int __stdcall MV_CC_SetBalanceRatioRed(IN void* handle, IN const unsigned int nValue);
  1508. /************************************************************************
  1509. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetBalanceRatioGreen(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1510. * @brief 获取白平衡 绿
  1511. * @param void* handle [IN] 相机句柄
  1512. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机白平衡 绿结构体指针
  1513. * @return 成功,返回MV_OK,失败,返回错误码
  1514. *
  1515. * 可参照接口MV_CC_GetWidth
  1516. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetBalanceRatioGreen(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1517. * @brief Get white balance green
  1518. * @param void* handle [IN] Handle
  1519. * @param MVCC_INTVALUE* pstValue [IN][OUT] Structure pointer of white balance green
  1520. * @return Success, return MV_OK. Failure, return error code
  1521. *
  1522. * Refer to MV_CC_GetWidth
  1523. ************************************************************************/
  1524. MV_CAMCTRL_API int __stdcall MV_CC_GetBalanceRatioGreen(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1525. /************************************************************************
  1526. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetBalanceRatioGreen(IN void* handle, IN const unsigned int nValue);
  1527. * @brief 设置白平衡 绿
  1528. * @param void* handle [IN] 相机句柄
  1529. * const unsigned int nValue [IN] 想要设置的白平衡 绿
  1530. * @return 成功,返回MV_OK,并且相机白平衡 绿将会更改为相应值,失败,返回错误码
  1531. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetBalanceRatioGreen(IN void* handle, IN const unsigned int nValue);
  1532. * @brief Set white balance green
  1533. * @param void* handle [IN] Handle
  1534. * const unsigned int nValue [IN] White balance green to set
  1535. * @return Success, return MV_OK, and the camera white balance green will change to the corresponding value. Failure, return error code
  1536. ************************************************************************/
  1537. MV_CAMCTRL_API int __stdcall MV_CC_SetBalanceRatioGreen(IN void* handle, IN const unsigned int nValue);
  1538. /************************************************************************
  1539. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetBalanceRatioBlue(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1540. * @brief 获取白平衡 蓝
  1541. * @param void* handle [IN] 相机句柄
  1542. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机白平衡 蓝结构体指针
  1543. * @return 成功,返回MV_OK,失败,返回错误码
  1544. *
  1545. * 可参照接口MV_CC_GetWidth
  1546. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetBalanceRatioBlue(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1547. * @brief Get white balance blue
  1548. * @param void* handle [IN] Handle
  1549. * @param MVCC_INTVALUE* pstValue [IN][OUT] Structure pointer of white balance blue
  1550. * @return Success, return MV_OK. Failure, return error code
  1551. *
  1552. * Refer to MV_CC_GetWidth
  1553. ************************************************************************/
  1554. MV_CAMCTRL_API int __stdcall MV_CC_GetBalanceRatioBlue(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1555. /************************************************************************
  1556. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetBalanceRatioBlue(IN void* handle, IN const unsigned int nValue);
  1557. * @brief 设置白平衡 蓝
  1558. * @param void* handle [IN] 相机句柄
  1559. * const unsigned int nValue [IN] 想要设置的白平衡 蓝
  1560. * @return 成功,返回MV_OK,并且相机白平衡 蓝将会更改为相应值,失败,返回错误码
  1561. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetBalanceRatioBlue(IN void* handle, IN const unsigned int nValue);
  1562. * @brief Set white balance blue
  1563. * @param void* handle [IN] Handle
  1564. * const unsigned int nValue [IN] White balance blue to set
  1565. * @return Success, return MV_OK, and the camera white balance blue will change to the corresponding value. Failure, return error code
  1566. ************************************************************************/
  1567. MV_CAMCTRL_API int __stdcall MV_CC_SetBalanceRatioBlue(IN void* handle, IN const unsigned int nValue);
  1568. /************************************************************************
  1569. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetFrameSpecInfoAbility(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1570. * @brief 获取水印信息内包含的信息类型
  1571. * @param void* handle [IN] 相机句柄
  1572. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机水印信息内包含的信息类型结构体指针
  1573. * @return 成功,返回MV_OK,失败,返回错误码
  1574. *
  1575. * 可参照接口MV_CC_GetWidth
  1576. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetFrameSpecInfoAbility(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1577. * @brief Get information type included by frame stamp
  1578. * @param void* handle [IN] Handle
  1579. * @param MVCC_INTVALUE* pstValue [IN][OUT] Structure pointer of information type included by frame stamp
  1580. * @return Success, return MV_OK. Failure, return error code
  1581. *
  1582. * Refer to MV_CC_GetWidth
  1583. ************************************************************************/
  1584. MV_CAMCTRL_API int __stdcall MV_CC_GetFrameSpecInfoAbility(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1585. /************************************************************************
  1586. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetFrameSpecInfoAbility(IN void* handle, IN const unsigned int nValue);
  1587. * @brief 设置水印信息内包含的信息类型
  1588. * @param void* handle [IN] 相机句柄
  1589. * const unsigned int nValue [IN] 想要设置的水印信息内包含的信息类型
  1590. * @return 成功,返回MV_OK,并且相机水印信息内包含的信息类型会更改为相应值,失败,返回错误码
  1591. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetFrameSpecInfoAbility(IN void* handle, IN const unsigned int nValue);
  1592. * @brief Set information type included by frame stamp
  1593. * @param void* handle [IN] Handle
  1594. * const unsigned int nValue [IN] Information type included by frame stamp to set
  1595. * @return Success, return MV_OK, and the camera information type included by frame stamp will change to the corresponding value. Failure, return error code
  1596. ************************************************************************/
  1597. MV_CAMCTRL_API int __stdcall MV_CC_SetFrameSpecInfoAbility(IN void* handle, IN const unsigned int nValue);
  1598. /************************************************************************
  1599. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetDeviceUserID(IN void* handle, IN OUT MVCC_STRINGVALUE* pstValue);
  1600. * @brief 获取设备自定义名字
  1601. * @param void* handle [IN] 相机句柄
  1602. * MVCC_STRINGVALUE* pstValue [IN OUT] 返回给调用者有关相机名字结构体指针
  1603. * @return 成功,返回MV_OK,并且获取到相机的自定义名字,失败,返回错误码
  1604. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetDeviceUserID(IN void* handle, IN OUT MVCC_STRINGVALUE* pstValue);
  1605. * @brief Get device user defined name
  1606. * @param void* handle [IN] Handle
  1607. * MVCC_STRINGVALUE* pstValue [IN OUT] Structure pointer of device name
  1608. * @return Success, return MV_OK, and get the camera user defined name. Failure, return error code
  1609. ************************************************************************/
  1610. MV_CAMCTRL_API int __stdcall MV_CC_GetDeviceUserID(IN void* handle, IN OUT MVCC_STRINGVALUE* pstValue);
  1611. /************************************************************************
  1612. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetDeviceUserID(IN void* handle, IN const char* chValue);
  1613. * @brief 设置设备自定义名字
  1614. * @param void* handle [IN] 相机句柄
  1615. * IN const char* chValue [IN] 设备名字
  1616. * @return 成功,返回MV_OK,并且设置设备自定义名字,失败,返回错误码
  1617. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetDeviceUserID(IN void* handle, IN const char* chValue);
  1618. * @brief Set device user defined name
  1619. * @param void* handle [IN] Handle
  1620. * IN const char* chValue [IN] Device name
  1621. * @return Success, return MV_OK, and set the camera user defined name. Failure, return error code
  1622. ************************************************************************/
  1623. MV_CAMCTRL_API int __stdcall MV_CC_SetDeviceUserID(IN void* handle, IN const char* chValue);
  1624. /************************************************************************
  1625. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetBurstFrameCount(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1626. * @brief 获取一次触发的帧数
  1627. * @param void* handle [IN] 相机句柄
  1628. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机一次触发的帧数结构体指针
  1629. * @return 成功,返回MV_OK,失败,返回错误码
  1630. *
  1631. * 可参照接口MV_CC_GetWidth
  1632. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetBurstFrameCount(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1633. * @brief Get frame number trigger by once
  1634. * @param void* handle [IN] Handle
  1635. * @param MVCC_INTVALUE* pstValue [IN][OUT] Structure pointer of frame number trigger by once
  1636. * @return Success, return MV_OK. Failure, return error code
  1637. *
  1638. * Refer to MV_CC_GetWidth
  1639. ************************************************************************/
  1640. MV_CAMCTRL_API int __stdcall MV_CC_GetBurstFrameCount(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1641. /************************************************************************
  1642. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetBurstFrameCount(IN void* handle, IN const unsigned int nValue);
  1643. * @brief 设置一次触发的帧数
  1644. * @param void* handle [IN] 相机句柄
  1645. * const unsigned int nValue [IN] 想要设置的一次触发的帧数
  1646. * @return 成功,返回MV_OK,并且相机一次触发的帧数会更改为相应值,失败,返回错误码
  1647. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetBurstFrameCount(IN void* handle, IN const unsigned int nValue);
  1648. * @brief Set frame number trigger by once
  1649. * @param void* handle [IN] Handle
  1650. * const unsigned int nValue [IN] Frame number trigger by once to set
  1651. * @return Success, return MV_OK, and the camera frame number trigger by once will change to the corresponding value. Failure, return error code
  1652. ************************************************************************/
  1653. MV_CAMCTRL_API int __stdcall MV_CC_SetBurstFrameCount(IN void* handle, IN const unsigned int nValue);
  1654. /************************************************************************
  1655. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetAcquisitionLineRate(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1656. * @brief 获取行频
  1657. * @param void* handle [IN] 相机句柄
  1658. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机行频结构体指针
  1659. * @return 成功,返回MV_OK,失败,返回错误码
  1660. *
  1661. * 可参照接口MV_CC_GetWidth
  1662. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetAcquisitionLineRate(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1663. * @brief Get line rate
  1664. * @param void* handle [IN] Handle
  1665. * @param MVCC_INTVALUE* pstValue [IN][OUT] Structure pointer of line rate
  1666. * @return Success, return MV_OK. Failure, return error code
  1667. *
  1668. * Refer to MV_CC_GetWidth
  1669. ************************************************************************/
  1670. MV_CAMCTRL_API int __stdcall MV_CC_GetAcquisitionLineRate(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1671. /************************************************************************
  1672. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetAcquisitionLineRate(IN void* handle, IN const unsigned int nValue);
  1673. * @brief 设置行频
  1674. * @param void* handle [IN] 相机句柄
  1675. * const unsigned int nValue [IN] 想要设置的行频
  1676. * @return 成功,返回MV_OK,并且相机行频会更改为相应值,失败,返回错误码
  1677. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetAcquisitionLineRate(IN void* handle, IN const unsigned int nValue);
  1678. * @brief Set line rate
  1679. * @param void* handle [IN] Handle
  1680. * const unsigned int nValue [IN] Line rate to set
  1681. * @return Success, return MV_OK, and the camera line rate will change to the corresponding value. Failure, return error code
  1682. ************************************************************************/
  1683. MV_CAMCTRL_API int __stdcall MV_CC_SetAcquisitionLineRate(IN void* handle, IN const unsigned int nValue);
  1684. /************************************************************************
  1685. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetHeartBeatTimeout(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1686. * @brief 获取心跳信息
  1687. * @param void* handle [IN] 相机句柄
  1688. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机心跳信息结构体指针
  1689. * @return 成功,返回MV_OK,失败,返回错误码
  1690. *
  1691. * 可参照接口MV_CC_GetWidth
  1692. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetHeartBeatTimeout(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1693. * @brief Get heartbeat information
  1694. * @param void* handle [IN] Handle
  1695. * @param MVCC_INTVALUE* pstValue [IN][OUT] Structure pointer of heartbeat information
  1696. * @return Success, return MV_OK. Failure, return error code
  1697. *
  1698. * Refer to MV_CC_GetWidth
  1699. ************************************************************************/
  1700. MV_CAMCTRL_API int __stdcall MV_CC_GetHeartBeatTimeout(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1701. /************************************************************************
  1702. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetHeartBeatTimeout(IN void* handle, IN const unsigned int nValue);
  1703. * @brief 设置心跳信息
  1704. * @param void* handle [IN] 相机句柄
  1705. * const unsigned int nValue [IN] 想要设置的心跳信息
  1706. * @return 成功,返回MV_OK,并且相机心跳信息会更改为相应值,失败,返回错误码
  1707. * @fn MV_CAMCTRL_API int __stdcall MV_CC_SetHeartBeatTimeout(IN void* handle, IN const unsigned int nValue);
  1708. * @brief Set heartbeat information
  1709. * @param void* handle [IN] Handle
  1710. * const unsigned int nValue [IN] Heartbeat information to set
  1711. * @return Success, return MV_OK, and the camera heartbeat information will change to the corresponding value. Failure, return error code
  1712. ************************************************************************/
  1713. MV_CAMCTRL_API int __stdcall MV_CC_SetHeartBeatTimeout(IN void* handle, IN const unsigned int nValue);
  1714. /************************************************************************/
  1715. /* 设备升级 和 寄存器读写 和异常、事件回调 */
  1716. /* Device upgrade, register read and write and exception callback */
  1717. /************************************************************************/
  1718. // 设备本地升级
  1719. // Device Local Upgrade
  1720. /************************************************************************
  1721. * @fn MV_CAMCTRL_API int __stdcall MV_CC_LocalUpgrade(IN void* handle,
  1722. const void *pFilePathName);
  1723. * @brief 设备本地升级
  1724. * @param void* handle [IN] 相机句柄
  1725. * @param void *pFilePathName [IN] 文件名
  1726. * @return 成功,返回MV_OK,失败,返回错误码
  1727. * @fn MV_CAMCTRL_API int __stdcall MV_CC_LocalUpgrade(IN void* handle,
  1728. const void *pFilePathName);
  1729. * @brief Device Local Upgrade
  1730. * @param void* handle [IN] Camera handle
  1731. * @param void *pFilePathName [IN] File name
  1732. * @return Success, return MV_OK. Failure, return error code
  1733. ************************************************************************/
  1734. MV_CAMCTRL_API int __stdcall MV_CC_LocalUpgrade(IN void* handle, const void *pFilePathName);
  1735. /************************************************************************
  1736. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetUpgradeProcess(IN void* handle,
  1737. unsigned int* pnProcess);
  1738. * @brief 获取升级进度
  1739. * @param void* handle [IN] 相机句柄
  1740. * @param unsigned int* pnProcess [OUT] 进度接收地址
  1741. * @return 成功,返回MV_OK,失败,返回错误码
  1742. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetUpgradeProcess(IN void* handle,
  1743. unsigned int* pnProcess);
  1744. * @brief Get Upgrade Progress
  1745. * @param void* handle [IN] Camera handle
  1746. * @param unsigned int* pnProcess [OUT] Progress receiving address
  1747. * @return Success, return MV_OK. Failure, return error code
  1748. ************************************************************************/
  1749. MV_CAMCTRL_API int __stdcall MV_CC_GetUpgradeProcess(IN void* handle, unsigned int* pnProcess);
  1750. /************************************************************************
  1751. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetOptimalPacketSize(IN void* handle);
  1752. * @brief 获取最佳的packet size,该接口目前只支持GigE相机
  1753. * @param void* handle [IN] 相机句柄
  1754. * @return 最佳packetsize
  1755. * @fn MV_CAMCTRL_API int __stdcall MV_CC_GetOptimalPacketSize(IN void* handle);
  1756. * @brief Get the optimal Packet Size, Only support GigE Camera
  1757. * @param void* handle [IN] Camera handle
  1758. * @return Optimal packetsize
  1759. ************************************************************************/
  1760. MV_CAMCTRL_API int __stdcall MV_CC_GetOptimalPacketSize(IN void* handle);
  1761. /************************************************************************
  1762. * @fn MV_CC_ReadMemory
  1763. * @brief 读内存
  1764. * @param handle:设备句柄
  1765. * @param pBuffer:作为返回值使用,保存读到的内存值(内存值是按照大端模式存储的)
  1766. * @param nAddress:待读取的内存地址,该地址可以从设备的Camera.xml文件中获取,形如xxx_RegAddr的xml节点值
  1767. (设备的Camera.xml文件会在设备打开之后自动生成在应用程序的当前目录中)
  1768. * @param nLength:待读取的内存长度
  1769. * @return 见返回错误码
  1770. * @fn MV_CC_ReadMemory
  1771. * @brief Read Memory
  1772. * @param handle: Device Handle
  1773. * @param pBuffer: Used as a return value, save the read-in memory value ( Memory value is stored in accordance with the big end model)
  1774. * @param nAddress: Memory address to be read, which can be obtained from the Camera.xml file of the device, the form xml node value of xxx_RegAddr
  1775. (Camera.xml file of device is automatically generated in the application's current directory after the device is opened)
  1776. * @param nLength: Length of the memory to be read
  1777. * @return Refer to the return error code
  1778. *************************************************************************/
  1779. MV_CAMCTRL_API int __stdcall MV_CC_ReadMemory(IN void* handle , void *pBuffer, int64_t nAddress, int64_t nLength);
  1780. /************************************************************************
  1781. * @fn MV_CC_WriteMemory
  1782. * @brief 写内存
  1783. * @param handle:设备句柄
  1784. * @param pBuffer:待写入的内存值(注意内存值要按照大端模式存储)
  1785. * @param nAddress:待写入的内存地址,该地址可以从设备的Camera.xml文件中获取,形如xxx_RegAddr的xml节点值
  1786. (设备的Camera.xml文件会在设备打开之后自动生成在应用程序的当前目录中)
  1787. * @param nLength:待写入的内存长度
  1788. * @return 见返回错误码
  1789. * @fn MV_CC_WriteMemory
  1790. * @brief Write Memory
  1791. * @param handle: Device Handle
  1792. * @param pBuffer: Memory value to be written ( Note the memory value to be stored in accordance with the big end model)
  1793. * @param nAddress: Memory address to be written, which can be obtained from the Camera.xml file of the device, the form xml node value of xxx_RegAddr
  1794. (Camera.xml file of device is automatically generated in the application's current directory after the device is opened)
  1795. * @param nLength: Length of the memory to be written
  1796. * @return Refer to the return error code
  1797. ************************************************************************/
  1798. MV_CAMCTRL_API int __stdcall MV_CC_WriteMemory(IN void* handle , const void *pBuffer, int64_t nAddress, int64_t nLength);
  1799. // 注册异常消息回调,在打开设备之后调用
  1800. // Register exception message callback, call after open device
  1801. /************************************************************************
  1802. * @fn MV_CC_RegisterExceptionCallBack
  1803. * @brief 注册异常消息回调,在打开设备之后调用
  1804. * @param handle:设备句柄
  1805. * @param cbException [IN] 异常回调函数指针
  1806. * @param pUser [IN] 用户自定义变量
  1807. * @return 见返回错误码
  1808. * @fn MV_CC_RegisterExceptionCallBack
  1809. * @brief Register Exception Message CallBack, call after open device
  1810. * @param handle: Device handle
  1811. * @param cbException [IN] Exception Message CallBack Function Pointer
  1812. * @param pUser [IN] User defined variable
  1813. * @return Refer to error code
  1814. ************************************************************************/
  1815. MV_CAMCTRL_API int __stdcall MV_CC_RegisterExceptionCallBack(IN void* handle,
  1816. void(__stdcall* cbException)(unsigned int nMsgType, void* pUser),
  1817. void* pUser);
  1818. /************************************************************************
  1819. * @fn MV_CC_RegisterAllEventCallBack
  1820. * @brief 注册全部事件回调,在打开设备之后调用,只支持GIGE
  1821. * @param handle:设备句柄
  1822. * @param cbEvent [IN] 异常回调函数指针
  1823. * @param pUser [IN] 用户自定义变量
  1824. * @return 见返回错误码
  1825. * @fn MV_CC_RegisterEventCallBack
  1826. * @brief Register event callback, which is called after the device is opened
  1827. * @param handle: Device handel
  1828. * @param cbEvent [IN] Exception CallBack Function Pointer
  1829. * @param pUser [IN] User defined variable
  1830. * @return Refer to error code
  1831. ************************************************************************/
  1832. MV_CAMCTRL_API int __stdcall MV_CC_RegisterAllEventCallBack(void* handle,
  1833. void(__stdcall* cbEvent)(MV_EVENT_OUT_INFO * pEventInfo, void* pUser),
  1834. void* pUser);
  1835. /************************************************************************
  1836. * @fn MV_CC_RegisterEventCallBackEx
  1837. * @brief 注册单个事件回调,在打开设备之后调用,只支持GIGE
  1838. * @param handle:设备句柄
  1839. * @param pEventName [IN] 事件名称
  1840. * @param cbEvent [IN] 异常回调函数指针
  1841. * @param pUser [IN] 用户自定义变量
  1842. * @return 见返回错误码
  1843. ************************************************************************/
  1844. MV_CAMCTRL_API int __stdcall MV_CC_RegisterEventCallBackEx(void* handle, const char* pEventName,
  1845. void(__stdcall* cbEvent)(MV_EVENT_OUT_INFO * pEventInfo, void* pUser),
  1846. void* pUser);
  1847. /************************************************************************/
  1848. /* GigEVision 设备独有的接口 */
  1849. /* GigEVision device specific interface */
  1850. /************************************************************************/
  1851. /************************************************************************
  1852. * @fn MV_GIGE_ForceIpEx
  1853. * @brief 强制IP
  1854. * @param handle:设备句柄
  1855. * @param nIP [IN] 设置的IP
  1856. * @param nSubNetMask [IN] 子网掩码
  1857. * @param nDefaultGateWay [IN] 默认网关
  1858. * @return 见返回错误码
  1859. * @fn MV_GIGE_ForceIpEx
  1860. * @brief Force IP
  1861. * @param handle: Device handel
  1862. * @param nIP [IN] IP to set
  1863. * @param nSubNetMask [IN] Subnet mask
  1864. * @param nDefaultGateWay [IN] Default gateway
  1865. * @return Refer to error code
  1866. ************************************************************************/
  1867. MV_CAMCTRL_API int __stdcall MV_GIGE_ForceIpEx(IN void* handle, unsigned int nIP, unsigned int nSubNetMask, unsigned int nDefaultGateWay);
  1868. /************************************************************************/
  1869. /* GigEVision 设备独有的接口 */
  1870. /************************************************************************/
  1871. /************************************************************************
  1872. * @fn MV_GIGE_SetIpConfig
  1873. * @brief 配置IP方式
  1874. * @param handle:设备句柄
  1875. * @param nType [IN] IP类型,见MV_IP_CFG_x
  1876. * @return 见返回错误码
  1877. * @fn MV_GIGE_SetIpConfig
  1878. * @brief IP configuration method
  1879. * @param handle: Device handel
  1880. * @param nType [IN] IP type, refer to MV_IP_CFG_x
  1881. * @return Refer to error code
  1882. ************************************************************************/
  1883. MV_CAMCTRL_API int __stdcall MV_GIGE_SetIpConfig(IN void* handle, unsigned int nType);
  1884. /************************************************************************
  1885. * @fn MV_GIGE_SetNetTransMode
  1886. * @brief 设置仅使用某种模式,type: MV_NET_TRANS_x,不设置时,默认优先使用driver
  1887. * @param handle:设备句柄
  1888. * @param nType [IN] 网络传输模式,见MV_NET_TRANS_x
  1889. * @return 见返回错误码
  1890. * @fn MV_GIGE_SetNetTransMode
  1891. * @brief Set to use only one mode,type: MV_NET_TRANS_x. When do not set, priority is to use driver by default
  1892. * @param handle: Device handel
  1893. * @param nType [IN] Net transmission mode, refer to MV_NET_TRANS_x
  1894. * @return Refer to error code
  1895. ************************************************************************/
  1896. MV_CAMCTRL_API int __stdcall MV_GIGE_SetNetTransMode(IN void* handle, unsigned int nType);
  1897. /************************************************************************
  1898. * @fn MV_GIGE_GetNetTransInfo
  1899. * @brief 获取网络传输信息
  1900. * @param handle:设备句柄
  1901. * @param pstInfo [OUT] 信息结构体
  1902. * @return 见返回错误码
  1903. * @fn MV_GIGE_GetNetTransInfo
  1904. * @brief Get net transmission information
  1905. * @param handle: Device handel
  1906. * @param pstInfo [OUT] Information Structure
  1907. * @return Refer to error code
  1908. ************************************************************************/
  1909. MV_CAMCTRL_API int __stdcall MV_GIGE_GetNetTransInfo(IN void* handle, MV_NETTRANS_INFO* pstInfo);
  1910. /************************************************************************
  1911. * @fn MV_GIGE_SetGvcpTimeout
  1912. * @brief 设置GVCP命令超时时间
  1913. * @param handle [IN] 句柄地址
  1914. * @param nMillisec [IN] 超时时间,以毫秒位单位,范围:0-10000
  1915. * @return 成功,返回MV_OK;错误,返回错误码
  1916. * @fn MV_GIGE_SetGvcpTimeout
  1917. * @brief Set GVCP cammand timeout
  1918. * @param handle [IN] Handle
  1919. * @param nMillisec [IN] Timeout, ms as unit, range: 0-10000
  1920. * @return Success, return MV_OK. Failure, return error code
  1921. ************************************************************************/
  1922. MV_CAMCTRL_API int __stdcall MV_GIGE_SetGvcpTimeout(void* handle, unsigned int nMillisec);
  1923. /************************************************************************
  1924. * @fn MV_GIGE_SetResend
  1925. * @brief 设置是否打开重发包支持,及重发包设置
  1926. * @param handle [IN] 句柄地址
  1927. * @param bEnable [IN] 是否支持重发包
  1928. * @param nMaxResendPercent [IN] 最大重发比
  1929. * @param nResendTimeout [IN] 重发超时时间
  1930. * @return 成功,返回MV_OK;错误,返回错误码
  1931. * @fn MV_GIGE_SetResend
  1932. * @brief Set whethe to enable resend, and set resend
  1933. * @param handle [IN] Handle
  1934. * @param bEnable [IN] enable resend
  1935. * @param nMaxResendPercent [IN] Max resend persent
  1936. * @param nResendTimeout [IN] Resend timeout
  1937. * @return Success, return MV_OK. Failure, return error code
  1938. ************************************************************************/
  1939. #ifndef __cplusplus
  1940. MV_CAMCTRL_API int __stdcall MV_GIGE_SetResend(void* handle, unsigned int bEnable, unsigned int nMaxResendPercent, unsigned int nResendTimeout);
  1941. #else
  1942. MV_CAMCTRL_API int __stdcall MV_GIGE_SetResend(void* handle, unsigned int bEnable, unsigned int nMaxResendPercent = 10, unsigned int nResendTimeout = 50);
  1943. #endif
  1944. /************************************************************************
  1945. * @fn MV_CAMCTRL_API int __stdcall MV_GIGE_GetGevSCPSPacketSize(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1946. * @brief 获取网络包大小
  1947. * @param void* handle [IN] 相机句柄
  1948. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机网络包大小结构体指针
  1949. * @return 成功,返回MV_OK,失败,返回错误码
  1950. *
  1951. * 可参照接口MV_CC_GetWidth
  1952. * @fn MV_CAMCTRL_API int __stdcall MV_GIGE_GetGevSCPSPacketSize(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1953. * @brief Get network packet size
  1954. * @param void* handle [IN] Handle
  1955. * @param MVCC_INTVALUE* pstValue [IN][OUT] Structure pointer of network packet size
  1956. * @return Success, return MV_OK. Failure, return error code
  1957. *
  1958. * Refer to MV_CC_GetWidth
  1959. ************************************************************************/
  1960. MV_CAMCTRL_API int __stdcall MV_GIGE_GetGevSCPSPacketSize(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1961. /************************************************************************
  1962. * @fn MV_CAMCTRL_API int __stdcall MV_GIGE_SetGevSCPSPacketSize(IN void* handle, IN const unsigned int nValue);
  1963. * @brief 设置网络包大小
  1964. * @param void* handle [IN] 相机句柄
  1965. * const unsigned int nValue [IN] 想要设置的网络包大小
  1966. * @return 成功,返回MV_OK,并且相机网络包大小会更改为相应值,失败,返回错误码
  1967. * @fn MV_CAMCTRL_API int __stdcall MV_GIGE_SetGevSCPSPacketSize(IN void* handle, IN const unsigned int nValue);
  1968. * @brief Set network packet size
  1969. * @param void* handle [IN] Handle
  1970. * const unsigned int nValue [IN] Packet size to set
  1971. * @return Success, return MV_OK, and change packet size to setting value. Failure, return error code
  1972. ************************************************************************/
  1973. MV_CAMCTRL_API int __stdcall MV_GIGE_SetGevSCPSPacketSize(IN void* handle, IN const unsigned int nValue);
  1974. /************************************************************************
  1975. * @fn MV_CAMCTRL_API int __stdcall MV_GIGE_GetGevSCPD(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1976. * @brief 获取网络包发送间隔
  1977. * @param void* handle [IN] 相机句柄
  1978. * @param MVCC_INTVALUE* pstValue [IN][OUT] 返回给调用者有关相机网络包发送间隔结构体指针
  1979. * @return 成功,返回MV_OK,失败,返回错误码
  1980. *
  1981. * 可参照接口MV_CC_GetWidth
  1982. * @fn MV_CAMCTRL_API int __stdcall MV_GIGE_GetGevSCPD(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1983. * @brief Get network packet sending delay
  1984. * @param void* handle [IN] Handle
  1985. * @param MVCC_INTVALUE* pstValue [IN][OUT] Structure pointer of network packet sending delay
  1986. * @return Success, return MV_OK. Failure, return error code
  1987. *
  1988. * Refer to MV_CC_GetWidth
  1989. ************************************************************************/
  1990. MV_CAMCTRL_API int __stdcall MV_GIGE_GetGevSCPD(IN void* handle, IN OUT MVCC_INTVALUE* pstValue);
  1991. /************************************************************************
  1992. * @fn MV_CAMCTRL_API int __stdcall MV_GIGE_SetGevSCPD(IN void* handle, IN const unsigned int nValue);
  1993. * @brief 设置网络包发送间隔
  1994. * @param void* handle [IN] 相机句柄
  1995. * const unsigned int nValue [IN] 想要设置的网络包发送间隔
  1996. * @return 成功,返回MV_OK,并且相机网络包发送间隔会更改为相应值,失败,返回错误码
  1997. * @fn MV_CAMCTRL_API int __stdcall MV_GIGE_SetGevSCPD(IN void* handle, IN const unsigned int nValue);
  1998. * @brief Set network packet sending delay
  1999. * @param void* handle [IN] Handle
  2000. * const unsigned int nValue [IN] Packet delay to set
  2001. * @return Success, return MV_OK, and change packet delay to setting value. Failure, return error code
  2002. ************************************************************************/
  2003. MV_CAMCTRL_API int __stdcall MV_GIGE_SetGevSCPD(IN void* handle, IN const unsigned int nValue);
  2004. /************************************************************************
  2005. * @fn MV_CAMCTRL_API int __stdcall MV_GIGE_GetGevSCDA(IN void* handle, unsigned int* pnIP);
  2006. * @brief 获取接收端IP地址,0xa9fe0102 表示 169.254.1.2
  2007. * @param void* handle [IN] 相机句柄
  2008. * @param unsigned int* pnIP [IN][OUT] 返回给调用者接收端IP地址
  2009. * @return 成功,返回MV_OK,失败,返回错误码
  2010. * @fn MV_CAMCTRL_API int __stdcall MV_GIGE_GetGevSCDA(IN void* handle, unsigned int* pnIP);
  2011. * @brief Get receiver IP address, 0xa9fe0102 indicates 169.254.1.2
  2012. * @param void* handle [IN] Handle
  2013. * @param unsigned int* pnIP [IN][OUT] Receiver IP address
  2014. * @return Success, return MV_OK. Failure, return error code
  2015. ************************************************************************/
  2016. MV_CAMCTRL_API int __stdcall MV_GIGE_GetGevSCDA(IN void* handle, unsigned int* pnIP);
  2017. /************************************************************************
  2018. * @fn MV_CAMCTRL_API int __stdcall MV_GIGE_SetGevSCDA(IN void* handle, unsigned int nIP);
  2019. * @brief 设置接收端IP地址
  2020. * @param void* handle [IN] 相机句柄
  2021. * unsigned int nIP [IN] 想要设置的接收端IP地址
  2022. * @return 成功,返回MV_OK,并且相机接收端IP地址会更改为相应值,失败,返回错误码
  2023. * @fn MV_CAMCTRL_API int __stdcall MV_GIGE_SetGevSCDA(IN void* handle, unsigned int nIP);
  2024. * @brief Set receiver IP address
  2025. * @param void* handle [IN] Handel
  2026. * unsigned int nIP [IN] Receiver IP address to set
  2027. * @return Success, return MV_OK, and change receiver IP address to setting value. Failure, return error code
  2028. ************************************************************************/
  2029. MV_CAMCTRL_API int __stdcall MV_GIGE_SetGevSCDA(IN void* handle, unsigned int nIP);
  2030. /************************************************************************
  2031. * @fn MV_CAMCTRL_API int __stdcall MV_GIGE_GetGevSCSP(IN void* handle, unsigned int* pnPort);
  2032. * @brief 获取发送端的端口号
  2033. * @param void* handle [IN] 相机句柄
  2034. * @param unsigned int* pnPort [IN][OUT] 返回给调用者发送端的端口号
  2035. * @return 成功,返回MV_OK,失败,返回错误码
  2036. * @fn MV_CAMCTRL_API int __stdcall MV_GIGE_GetGevSCSP(IN void* handle, unsigned int* pnPort);
  2037. * @brief Get transmitter port number
  2038. * @param void* handle [IN] Handle
  2039. * @param unsigned int* pnPort [IN][OUT] Transmitter port number
  2040. * @return Success, return MV_OK. Failure, return error code
  2041. ************************************************************************/
  2042. MV_CAMCTRL_API int __stdcall MV_GIGE_GetGevSCSP(IN void* handle, unsigned int* pnPort);
  2043. /************************************************************************
  2044. * @fn MV_CAMCTRL_API int __stdcall MV_GIGE_SetGevSCSP(IN void* handle, unsigned int nPort);
  2045. * @brief 设置发送端的端口号
  2046. * @param void* handle [IN] 相机句柄
  2047. * unsigned int nPort [IN] 想要设置的发送端的端口号
  2048. * @return 成功,返回MV_OK,并且相机发送端的端口号会更改为相应值,失败,返回错误码
  2049. * @fn MV_CAMCTRL_API int __stdcall MV_GIGE_SetGevSCSP(IN void* handle, unsigned int nPort);
  2050. * @brief Set transmitter port number
  2051. * @param void* handle [IN] Handle
  2052. * unsigned int nPort [IN] Transmitter port number to set
  2053. * @return Success, return MV_OK, and change transmitter port number to setting value. Failure, return error code
  2054. ************************************************************************/
  2055. MV_CAMCTRL_API int __stdcall MV_GIGE_SetGevSCSP(IN void* handle, unsigned int nPort);
  2056. /************************************************************************
  2057. * @fn MV_GIGE_SetTransmissionType
  2058. * @brief 设置传输模式,可以为单播模式、组播模式等
  2059. * @param handle [IN] 相机句柄
  2060. * @param stTransmissionType [IN] 传输模式结构体
  2061. * @return 返回成功或错误码
  2062. ************************************************************************/
  2063. MV_CAMCTRL_API int __stdcall MV_GIGE_SetTransmissionType(void* handle, MV_TRANSMISSION_TYPE * pstTransmissionType);
  2064. /************************************************************************
  2065. * @fn MV_GIGE_IssueActionCommand
  2066. * @brief 发出动作命令
  2067. * @param pstActionCmdInfo [IN] 动作命令信息 | en:Action Command
  2068. * @param MV_ACTION_CMD_RESULT_LIST [OUT] 动作命令返回信息列表 | en:Action Command Result List
  2069. * @return 返回成功或错误码
  2070. ************************************************************************/
  2071. MV_CAMCTRL_API int __stdcall MV_GIGE_IssueActionCommand(IN MV_ACTION_CMD_INFO* pstActionCmdInfo, OUT MV_ACTION_CMD_RESULT_LIST* pstActionCmdResults);
  2072. /************************************************************************/
  2073. /* CameraLink 设备独有的接口 */
  2074. /************************************************************************/
  2075. /************************************************************************
  2076. * @fn MV_CAML_SetDeviceBauderate
  2077. * @brief 设置设备波特率
  2078. * @param handle:设备句柄
  2079. * @param nBaudrate [IN] 设置的波特率值,数值参考CameraParams.h中宏定义,如#define MV_CAML_BAUDRATE_9600 0x00000001
  2080. * @return 见返回错误码
  2081. * @fn MV_CAML_SetDeviceBauderate
  2082. * @brief Set device bauderate using one of the CL_BAUDRATE_XXXX value
  2083. * @param handle Handle
  2084. * @param nBaudrate [IN] baud rate to set. Refer to the 'CameraParams.h' for parameter definitions, for example, #define MV_CAML_BAUDRATE_9600 0x00000001
  2085. * @return Refer to error code
  2086. ************************************************************************/
  2087. MV_CAMCTRL_API int __stdcall MV_CAML_SetDeviceBauderate(IN void* handle, unsigned int nBaudrate);
  2088. /************************************************************************
  2089. * @fn MV_CAML_GetDeviceBauderate
  2090. * @brief 获取设备波特率
  2091. * @param handle:设备句柄
  2092. * @param pnCurrentBaudrate [OUT] 波特率信息指针,数值参考CameraParams.h中宏定义,如#define MV_CAML_BAUDRATE_9600 0x00000001
  2093. * @return 见返回错误码
  2094. * @fn MV_CAML_GetDeviceBauderate
  2095. * @brief Returns the current device bauderate, using one of the CL_BAUDRATE_XXXX value
  2096. * @param handle Handle
  2097. * @param pnCurrentBaudrate [OUT] Return pointer of baud rate to user. Refer to the 'CameraParams.h' for parameter definitions, for example, #define MV_CAML_BAUDRATE_9600 0x00000001
  2098. * @return Refer to error code
  2099. ************************************************************************/
  2100. MV_CAMCTRL_API int __stdcall MV_CAML_GetDeviceBauderate(IN void* handle,unsigned int* pnCurrentBaudrate);
  2101. /************************************************************************
  2102. * @fn MV_CAML_GetSupportBauderates
  2103. * @brief 获取设备与主机间连接支持的波特率
  2104. * @param handle:设备句柄
  2105. * @param pnBaudrateAblity [OUT] 支持的波特率信息的指针。所支持波特率的或运算结果,单个数值参考CameraParams.h中宏定义,如#define MV_CAML_BAUDRATE_9600 0x00000001
  2106. * @return 见返回错误码
  2107. * @fn MV_CAML_GetSupportBauderates
  2108. * @brief Returns supported bauderates of the combined device and host interface
  2109. * @param handle Handle
  2110. * @param pnBaudrateAblity [OUT] Return pointer of the supported bauderates to user. 'OR' operation results of the supported bauderates. Refer to the 'CameraParams.h' for single value definitions, for example, #define MV_CAML_BAUDRATE_9600 0x00000001
  2111. * @return Refer to error code
  2112. ************************************************************************/
  2113. MV_CAMCTRL_API int __stdcall MV_CAML_GetSupportBauderates(IN void* handle,unsigned int* pnBaudrateAblity);
  2114. /************************************************************************
  2115. * @fn MV_CAML_SetGenCPTimeOut
  2116. * @brief 设置串口操作等待时长
  2117. * @param handle:设备句柄
  2118. * @param nMillisec [IN] 串口操作的等待时长, ms
  2119. * @return 见返回错误码
  2120. * @fn MV_CAML_SetGenCPTimeOut
  2121. * @brief Sets the timeout for operations on the serial port
  2122. * @param handle Handle
  2123. * @param nMillisec [IN] Timeout in [ms] for operations on the serial port.
  2124. * @return Refer to error code
  2125. ************************************************************************/
  2126. MV_CAMCTRL_API int __stdcall MV_CAML_SetGenCPTimeOut(IN void* handle, unsigned int nMillisec);
  2127. /************************************************************************/
  2128. /* XML解析树的生成 */
  2129. /* XML parse tree generation */
  2130. /************************************************************************/
  2131. /***********************************************************************
  2132. * @fn MV_XML_GetGenICamXML
  2133. * @brief 获取相机属性树XML
  2134. * @param handle [IN] 句柄
  2135. * @param pData [OUT] 图像数据接收指针
  2136. * @param nDataSize [IN] 接收缓存大小
  2137. * @param pnDataLen [OUT] 实际数据大小
  2138. * @return 成功,返回MV_OK;错误,返回错误码
  2139. * @fn MV_XML_GetGenICamXML
  2140. * @brief Get camera feature tree XML
  2141. * @param handle [IN] Handle
  2142. * @param pData [OUT] Recevied image buffer pointer
  2143. * @param nDataSize [IN] Recevied buffer size
  2144. * @param pnDataLen [OUT] Actual data size
  2145. * @return Success, return MV_OK. Failure, return error code
  2146. ***********************************************************************/
  2147. MV_CAMCTRL_API int __stdcall MV_XML_GetGenICamXML(IN void* handle, IN OUT unsigned char* pData, IN unsigned int nDataSize, OUT unsigned int* pnDataLen);
  2148. /***********************************************************************
  2149. * @fn MV_XML_GetRootNode
  2150. * @brief 获取根节点
  2151. * @param handle [IN] 句柄
  2152. * @param pstNode [OUT] 根节点信息结构体
  2153. * @return 成功,返回MV_OK;错误,返回错误码
  2154. * @fn MV_XML_GetRootNode
  2155. * @brief Get root node
  2156. * @param handle [IN] Handle
  2157. * @param pstNode [OUT] Root node information structure
  2158. * @return Success, return MV_OK. Failure, return error code
  2159. ***********************************************************************/
  2160. MV_CAMCTRL_API int __stdcall MV_XML_GetRootNode(IN void* handle, IN OUT MV_XML_NODE_FEATURE* pstNode);
  2161. /***********************************************************************
  2162. * @fn MV_XML_GetChildren
  2163. * @brief 从xml中获取指定节点的所有子节点,根节点为Root
  2164. * @param handle [IN] 句柄
  2165. * @param pstNode [IN] 根节点信息结构体
  2166. * @param pstNodesList [OUT] 节点列表结构体
  2167. * @return 成功,返回MV_OK;错误,返回错误码
  2168. * @fn MV_XML_GetChildren
  2169. * @brief Get all children node of specific node from xml, root node is Root
  2170. * @param handle [IN] Handle
  2171. * @param pstNode [IN] Root node information structure
  2172. * @param pstNodesList [OUT] Node information structure
  2173. * @return Success, return MV_OK. Failure, return error code
  2174. ***********************************************************************/
  2175. MV_CAMCTRL_API int __stdcall MV_XML_GetChildren(IN void* handle, IN MV_XML_NODE_FEATURE* pstNode, IN OUT MV_XML_NODES_LIST* pstNodesList);
  2176. /***********************************************************************
  2177. * @fn MV_XML_GetNodeFeature
  2178. * @brief 获得当前节点的属性
  2179. * @param handle [IN] 句柄
  2180. * @param pstNode [IN] 根节点信息结构体
  2181. * @param pstFeature [OUT] 当前节点属性结构体,
  2182. pstFeature 具体结构体内容参考 MV_XML_FEATURE_x
  2183. * @return 成功,返回MV_OK;错误,返回错误码
  2184. * @fn MV_XML_GetNodeFeature
  2185. * @brief Get current node feature
  2186. * @param handle [IN] Handle
  2187. * @param pstNode [IN] Root node information structure
  2188. * @param pstFeature [OUT] Current node feature structure
  2189. Details of pstFeature refer to MV_XML_FEATURE_x
  2190. * @return Success, return MV_OK. Failure, return error code
  2191. ***********************************************************************/
  2192. MV_CAMCTRL_API int __stdcall MV_XML_GetNodeFeature(IN void* handle, IN MV_XML_NODE_FEATURE* pstNode, IN OUT void* pstFeature);
  2193. /***********************************************************************
  2194. * @fn MV_XML_UpdateNodeFeature
  2195. * @brief 更新节点
  2196. * @param handle [IN] 句柄
  2197. * @param enType [IN] 节点类型
  2198. * @param pstFeature [OUT] 当前节点属性结构体
  2199. * @return 成功,返回MV_OK;错误,返回错误码
  2200. * @fn MV_XML_UpdateNodeFeature
  2201. * @brief Update node
  2202. * @param handle [IN] Handle
  2203. * @param enType [IN] Node type
  2204. * @param pstFeature [OUT] Current node feature structure
  2205. * @return Success, return MV_OK. Failure, return error code
  2206. ***********************************************************************/
  2207. MV_CAMCTRL_API int __stdcall MV_XML_UpdateNodeFeature(IN void* handle, IN enum MV_XML_InterfaceType enType, IN void* pstFeature);
  2208. // 有节点需要更新时的回调函数
  2209. // 当调用MV_XML_UpdateNodeFeature接口更新节点属性时,注册的回调函数cbUpdate会在pstNodesList中返回与之相关联的节点
  2210. /***********************************************************************
  2211. * @fn MV_XML_RegisterUpdateCallBack
  2212. * @brief 注册更新回调
  2213. * @param handle [IN] 句柄
  2214. * @param cbUpdate [IN] 回调函数指针
  2215. * @param pUser [IN] 用户自定义变量
  2216. * @return 成功,返回MV_OK;错误,返回错误码
  2217. * @fn MV_XML_RegisterUpdateCallBack
  2218. * @brief Register update callback
  2219. * @param handle [IN] Handle
  2220. * @param cbUpdate [IN] Callback function pointer
  2221. * @param pUser [IN] User defined variable
  2222. * @return Success, return MV_OK. Failure, return error code
  2223. ***********************************************************************/
  2224. MV_CAMCTRL_API int __stdcall MV_XML_RegisterUpdateCallBack(IN void* handle,
  2225. IN void(__stdcall* cbUpdate)(enum MV_XML_InterfaceType enType, void* pstFeature, MV_XML_NODES_LIST* pstNodesList, void* pUser),
  2226. IN void* pUser);
  2227. /************************************************************************/
  2228. /* 附加接口 */
  2229. /* Additional interface */
  2230. /************************************************************************/
  2231. /************************************************************************
  2232. * @fn MV_CC_SaveImageEx2
  2233. * @brief 保存图片,支持Bmp和Jpeg.编码质量在50-99之前
  2234. * @param handle [IN] 句柄地址
  2235. * @param pSaveParam [IN][OUT] 保存图片参数结构体
  2236. pData; // [IN] 输入数据缓存
  2237. nDataLen; // [IN] 输入数据大小
  2238. enPixelType; // [IN] 输入数据的像素格式
  2239. nWidth; // [IN] 图像宽
  2240. nHeight; // [IN] 图像高
  2241. pImageBuffer; // [OUT] 输出图片缓存
  2242. nImageLen; // [OUT] 输出图片大小
  2243. nBufferSize; // [IN] 提供的输出缓冲区大小
  2244. enImageType; // [IN] 输出图片格式
  2245. nJpgQuality; // [IN] 编码质量, (50-99]
  2246. iMethodValue // [IN] Bayer格式转为RGB24的插值方法
  2247. nReserved[4];
  2248. * @return 成功,返回MV_OK;错误,返回错误码
  2249. * @fn MV_CC_SaveImageEx2
  2250. * @brief Save image, support Bmp and Jpeg. Encoding quality, (50-99]
  2251. * @param handle [IN] Handle
  2252. * @param pSaveParam [IN][OUT] Save image parameters structure
  2253. pData; // [IN] Input data buffer
  2254. nDataLen; // [IN] Input data size
  2255. enPixelType; // [IN] Pixel format of input data
  2256. nWidth; // [IN] Image width
  2257. nHeight; // [IN] Image height
  2258. pImageBuffer; // [OUT] Output image buffer
  2259. nImageLen; // [OUT] Output image size
  2260. nBufferSize; // [IN] Output buffer size provided
  2261. enImageType; // [IN] Output image format
  2262. nJpgQuality; // [IN] Encoding quality, (50-99]
  2263. iMethodValue // [IN] Interpolation method of convert Bayer to RGB24
  2264. nReserved[4];
  2265. * @return Success, return MV_OK. Failure, return error code
  2266. ************************************************************************/
  2267. MV_CAMCTRL_API int __stdcall MV_CC_SaveImageEx2(IN void* handle, MV_SAVE_IMAGE_PARAM_EX* pSaveParam);
  2268. /************************************************************************
  2269. * @fn MV_CC_ConvertPixelType
  2270. * @brief 像素格式转换
  2271. * @param pstCvtParam [IN][OUT] 保存图片参数结构体
  2272. unsigned short nWidth; // [IN] 图像宽
  2273. unsigned short nHeight; // [IN] 图像高
  2274. enum MvGvspPixelType enSrcPixelType; // [IN] 源像素格式
  2275. unsigned char* pSrcData; // [IN] 输入数据缓存
  2276. unsigned int nSrcDataLen; // [IN] 输入数据大小
  2277. enum MvGvspPixelType enDstPixelType; // [IN] 目标像素格式
  2278. unsigned char* pDstBuffer; // [OUT] 输出数据缓存
  2279. unsigned int nDstLen; // [OUT] 输出数据大小
  2280. unsigned int nDstBufferSize; // [IN] 提供的输出缓冲区大小
  2281. * @return 成功,返回MV_OK;错误,返回错误码
  2282. * @fn MV_CC_ConvertPixelType
  2283. * @brief Pixel format conversion
  2284. * @param pstCvtParam [IN][OUT] Save image parameter structure
  2285. unsigned short nWidth; // [IN] Width
  2286. unsigned short nHeight; // [IN] Height
  2287. enum MvGvspPixelType enSrcPixelType; // [IN] Source pixel format
  2288. unsigned char* pSrcData; // [IN] Input data buffer
  2289. unsigned int nSrcDataLen; // [IN] Input data size
  2290. enum MvGvspPixelType enDstPixelType; // [IN] Destination pixel format
  2291. unsigned char* pDstBuffer; // [OUT] Output data buffer
  2292. unsigned int nDstLen; // [OUT] Output data size
  2293. unsigned int nDstBufferSize; // [IN] Provided output buffer size
  2294. * @return Success, return MV_OK. Failure, return error code
  2295. ************************************************************************/
  2296. MV_CAMCTRL_API int __stdcall MV_CC_ConvertPixelType(IN void* handle, IN OUT MV_CC_PIXEL_CONVERT_PARAM* pstCvtParam);
  2297. /************************************************************************
  2298. * @fn MV_CC_SetBayerCvtQuality
  2299. * @brief 插值算法类型设置
  2300. * @param BayerCvtQuality [IN] Bayer的插值方法 0-最近邻 1-双线性 2-Hamilton
  2301. * @return 成功,返回MV_OK;错误,返回错误码
  2302. * @fn MV_CC_SetBayerCvtQuality
  2303. * @brief Interpolation algorithm type setting
  2304. * @param BayerCvtQuality [IN] Bayer interpolation method 0-nearest neighbour 1-bilinearity 2-Hamilton
  2305. * @return Success, return MV_OK. Failure, return error code
  2306. ************************************************************************/
  2307. MV_CAMCTRL_API int __stdcall MV_CC_SetBayerCvtQuality(IN void* handle, IN unsigned int BayerCvtQuality);
  2308. /************************************************************************
  2309. * @fn MV_CC_GetTlProxy
  2310. * @brief 获取GenICam代理
  2311. * @param handle [IN] 句柄地址
  2312. * @return GenICam代理类指针 ,正常返回值非NULL;异常返回NULL
  2313. * @fn MV_CC_GetTlProxy
  2314. * @brief Get GenICam proxy
  2315. * @param handle [IN] Handle address
  2316. * @return GenICam proxy pointer, normal, return non-NULL; exception, return NULL
  2317. ************************************************************************/
  2318. MV_CAMCTRL_API void* __stdcall MV_CC_GetTlProxy(IN void* handle);
  2319. /************************************************************************
  2320. * @fn MV_CC_FeatureSave
  2321. * @brief 保存相机属性
  2322. * @param handle [IN] 句柄地址
  2323. * @param pFileName [IN] 属性文件名
  2324. * @return 成功,返回MV_OK;错误,返回错误码
  2325. * @fn MV_CC_FeatureSave
  2326. * @brief Save camera feature
  2327. * @param handle [IN] Handle
  2328. * @param pFileName [IN] File name
  2329. * @return Success, return MV_OK. Failure, return error code
  2330. ************************************************************************/
  2331. MV_CAMCTRL_API int __stdcall MV_CC_FeatureSave(IN void* handle, IN const char* pFileName);
  2332. /************************************************************************
  2333. * @fn MV_CC_FeatureLoad
  2334. * @brief 导入相机属性
  2335. * @param handle [IN] 句柄地址
  2336. * @param pFileName [IN] 属性文件名
  2337. * @return 成功,返回MV_OK;错误,返回错误码
  2338. * @fn MV_CC_FeatureLoad
  2339. * @brief Load camera feature
  2340. * @param handle [IN] Handle
  2341. * @param pFileName [IN] File name
  2342. * @return Success, return MV_OK. Failure, return error code
  2343. ************************************************************************/
  2344. MV_CAMCTRL_API int __stdcall MV_CC_FeatureLoad(IN void* handle, IN const char* pFileName);
  2345. /************************************************************************
  2346. * @fn MV_CC_FileAccessRead
  2347. * @brief 从相机读取文件
  2348. * @param handle [IN] 句柄地址
  2349. * @param pstFileAccess [IN] 文件存取结构体
  2350. * @return 成功,返回MV_OK;错误,返回错误码
  2351. * @fn MV_CC_FileAccessRead
  2352. * @brief Read the file from the camera
  2353. * @param handle [IN] Handle
  2354. * @param pstFileAccess [IN] File access structure
  2355. * @return Success, return MV_OK. Failure, return error code
  2356. ************************************************************************/
  2357. MV_CAMCTRL_API int __stdcall MV_CC_FileAccessRead(IN void* handle, IN MV_CC_FILE_ACCESS * pstFileAccess);
  2358. /************************************************************************
  2359. * @fn MV_CC_FileAccessWrite
  2360. * @brief 将文件写入相机
  2361. * @param handle [IN] 句柄地址
  2362. * @param pstFileAccess [IN] 文件存取结构体
  2363. * @return 成功,返回MV_OK;错误,返回错误码
  2364. * @fn MV_CC_FileAccessWrite
  2365. * @brief Write the file to camera
  2366. * @param handle [IN] Handle
  2367. * @param pstFileAccess [IN] File access structure
  2368. * @return Success, return MV_OK. Failure, return error code
  2369. ************************************************************************/
  2370. MV_CAMCTRL_API int __stdcall MV_CC_FileAccessWrite(IN void* handle, IN MV_CC_FILE_ACCESS * pstFileAccess);
  2371. /************************************************************************
  2372. * @fn MV_CC_GetFileAccessProgress
  2373. * @brief 获取文件存取的进度
  2374. * @param handle [IN] 句柄地址
  2375. * @param pstFileAccessProgress [IN] 进度内容
  2376. * @return 成功,返回MV_OK;错误,返回错误码 (当前文件存取的状态)
  2377. * @fn MV_CC_GetFileAccessProgress
  2378. * @brief Get File Access Progress
  2379. * @param handle [IN] Handle
  2380. * @param pstFileAccessProgress [IN] File access Progress
  2381. * @return Success, return MV_OK. Failure, return error code
  2382. ************************************************************************/
  2383. MV_CAMCTRL_API int __stdcall MV_CC_GetFileAccessProgress(IN void* handle, OUT MV_CC_FILE_ACCESS_PROGRESS * pstFileAccessProgress);
  2384. /************************************************************************
  2385. * @fn MV_CC_StartRecord
  2386. * @brief 开始录像
  2387. * @param handle [IN] 句柄地址
  2388. * @param pstRecordParam [IN] 录像参数结构体
  2389. * @return 成功,返回MV_OK;错误,返回错误码
  2390. * @fn MV_CC_StartRecord
  2391. * @brief Start Record
  2392. * @param handle [IN] Handle
  2393. * @param pstRecordParam [IN] Record param structure
  2394. * @return Success, return MV_OK. Failure, return error code
  2395. ************************************************************************/
  2396. MV_CAMCTRL_API int __stdcall MV_CC_StartRecord(IN void* handle, IN MV_CC_RECORD_PARAM* pstRecordParam);
  2397. /************************************************************************
  2398. * @fn MV_CC_InputOneFrame
  2399. * @brief 输入录像数据
  2400. * @param handle [IN] 句柄地址
  2401. * @param pstInputFrameInfo [IN] 录像数据结构体
  2402. * @return 成功,返回MV_OK;错误,返回错误码
  2403. * @fn MV_CC_InputOneFrame
  2404. * @brief Input RAW data to Record
  2405. * @param handle [IN] Handle
  2406. * @param pstInputFrameInfo [IN] Record data structure
  2407. * @return Success, return MV_OK. Failure, return error code
  2408. ************************************************************************/
  2409. MV_CAMCTRL_API int __stdcall MV_CC_InputOneFrame(IN void* handle, IN MV_CC_INPUT_FRAME_INFO * pstInputFrameInfo);
  2410. /************************************************************************
  2411. * @fn MV_CC_StopRecord
  2412. * @brief 停止录像
  2413. * @param handle [IN] 句柄地址
  2414. * @return 成功,返回MV_OK;错误,返回错误码
  2415. * @fn MV_CC_StopRecord
  2416. * @brief Stop Record
  2417. * @param handle [IN] Handle
  2418. * @return Success, return MV_OK. Failure, return error code
  2419. ************************************************************************/
  2420. MV_CAMCTRL_API int __stdcall MV_CC_StopRecord(IN void* handle);
  2421. /************************************************************************/
  2422. /* 弃用的接口 */
  2423. /* Abandoned interface */
  2424. /************************************************************************/
  2425. /***********************************************************************
  2426. * @fn MV_CC_GetOneFrame
  2427. * @brief 获取一帧图像,此函数为查询式获取,每次调用查询内部缓存有
  2428. 无数据,有数据则范围数据,无数据返回错误码
  2429. (该接口已弃用,建议改用 MV_CC_GetOneFrameTimeOut接口)
  2430. * @param handle [IN] 句柄
  2431. * @param pData [OUT] 图像数据接收指针
  2432. * @param nDataSize [IN] 接收缓存大小
  2433. * @param pFrameInfo [OUT] 图像信息结构体
  2434. * @return 成功,返回MV_OK;错误,返回错误码
  2435. * @fn MV_CC_GetOneFrame
  2436. * @brief Get one frame data, this function is using query to get data,
  2437. query whether the internal cache has data, return data if there has, return error code if no data
  2438. (This interface is abandoned, it is recommended to use the MV_CC_GetOneFrameTimeOut)
  2439. * @param handle [IN] Handle
  2440. * @param pData [OUT] Recevied image data pointer
  2441. * @param nDataSize [IN] Recevied buffer size
  2442. * @param pFrameInfo [OUT] Image information structure
  2443. * @return Success, return MV_OK. Failure, return error code
  2444. ***********************************************************************/
  2445. MV_CAMCTRL_API int __stdcall MV_CC_GetOneFrame(IN void* handle, IN OUT unsigned char * pData , IN unsigned int nDataSize, IN OUT MV_FRAME_OUT_INFO* pFrameInfo);
  2446. /***********************************************************************
  2447. * @fn MV_CC_GetOneFrameEx
  2448. * @brief 获取一帧trunck数据,此函数为查询式获取,每次调用查询内部
  2449. 缓存有无数据,有数据则范围数据,无数据返回错误码
  2450. (该接口已弃用,建议改用 MV_CC_GetOneFrameTimeOut接口)
  2451. * @param handle [IN] 句柄
  2452. * @param pData [OUT] 图像数据接收指针
  2453. * @param nDataSize [IN] 接收缓存大小
  2454. * @param pFrameInfo [OUT] 图像信息结构体
  2455. * @return 成功,返回MV_OK;错误,返回错误码
  2456. * @fn MV_CC_GetOneFrameEx
  2457. * @brief Get one frame of trunck data, this function is using query to get data,
  2458. query whether the internal cache has data, return data if there has, return error code if no data
  2459. (This interface is abandoned, it is recommended to use the MV_CC_GetOneFrameTimeOut)
  2460. * @param handle [IN] Handle
  2461. * @param pData [OUT] Recevied image data pointer
  2462. * @param nDataSize [IN] Recevied buffer size
  2463. * @param pFrameInfo [OUT] Image information structure
  2464. * @return Success, return MV_OK. Failure, return error code
  2465. ***********************************************************************/
  2466. MV_CAMCTRL_API int __stdcall MV_CC_GetOneFrameEx(IN void* handle, IN OUT unsigned char * pData , IN unsigned int nDataSize, IN OUT MV_FRAME_OUT_INFO_EX* pFrameInfo);
  2467. /***********************************************************************
  2468. * @fn MV_CC_RegisterImageCallBack
  2469. * @brief 注册图像数据回调(该接口已弃用,建议改用 MV_CC_RegisterImageCallBackEx接口)
  2470. * @param handle [IN] 句柄
  2471. * @param cbOutput [IN] 回调函数指针
  2472. * @param pUser [IN] 用户自定义变量
  2473. * @return 成功,返回MV_OK;错误,返回错误码
  2474. * @fn MV_CC_RegisterImageCallBack
  2475. * @brief Register image data callback (This interface is abandoned, it is recommended to use the MV_CC_RegisterImageCallBackEx)
  2476. * @param handle [IN] Handle
  2477. * @param cbOutput [IN] Callback function pointer
  2478. * @param pUser [IN] User defined variable
  2479. * @return Success, return MV_OK. Failure, return error code
  2480. ***********************************************************************/
  2481. MV_CAMCTRL_API int __stdcall MV_CC_RegisterImageCallBack(void* handle,
  2482. void(__stdcall* cbOutput)(unsigned char * pData, MV_FRAME_OUT_INFO* pFrameInfo, void* pUser),
  2483. void* pUser);
  2484. /************************************************************************
  2485. * @fn MV_CC_SaveImage
  2486. * @brief 保存图片(该接口已弃用,建议改用 MV_CC_SaveImageEx接口)
  2487. * @param pSaveParam [IN][OUT] 保存图片参数结构体
  2488. pData; // [IN] 输入数据缓存
  2489. nDataLen; // [IN] 输入数据大小
  2490. enPixelType; // [IN] 输入数据的像素格式
  2491. nWidth; // [IN] 图像宽
  2492. nHeight; // [IN] 图像高
  2493. pImageBuffer; // [OUT] 输出图片缓存
  2494. nImageLen; // [OUT] 输出图片大小
  2495. nBufferSize; // [IN] 提供的输出缓冲区大小
  2496. enImageType; // [IN] 输出图片格式
  2497. * @return 成功,返回MV_OK;错误,返回错误码
  2498. * @fn MV_CC_SaveImage
  2499. * @brief Save image (This interface is abandoned, it is recommended to use the MV_CC_SaveImageEx)
  2500. * @param pSaveParam [IN][OUT] Save image parameters structure
  2501. pData; // [IN] Input data buffer
  2502. nDataLen; // [IN] Input data size
  2503. enPixelType; // [IN] Input data pixel format
  2504. nWidth; // [IN] Width
  2505. nHeight; // [IN] Height
  2506. pImageBuffer; // [OUT] Output image buffer
  2507. nImageLen; // [OUT] Output image size
  2508. nBufferSize; // [IN] Provided output buffer size
  2509. enImageType; // [IN] Output image type
  2510. * @return Success, return MV_OK. Failure, return error code
  2511. ************************************************************************/
  2512. MV_CAMCTRL_API int __stdcall MV_CC_SaveImage(IN OUT MV_SAVE_IMAGE_PARAM* pSaveParam);
  2513. /************************************************************************
  2514. * @fn MV_GIGE_ForceIp
  2515. * @brief 强制IP(该接口已弃用,建议改用 MV_GIGE_ForceIpEx接口)
  2516. * @param handle:设备句柄
  2517. * @param nIP [IN] 设置的IP
  2518. * @return 见返回错误码
  2519. * @fn MV_GIGE_ForceIp
  2520. * @brief Force IP (This interface is abandoned, it is recommended to use the MV_GIGE_ForceIpEx)
  2521. * @param handle Handle
  2522. * @param nIP [IN] IP to set
  2523. * @return Refer to error code
  2524. ************************************************************************/
  2525. MV_CAMCTRL_API int __stdcall MV_GIGE_ForceIp(IN void* handle, unsigned int nIP);
  2526. /************************************************************************
  2527. * @fn MV_CC_RegisterEventCallBack
  2528. * @brief 注册事件回调(该接口已弃用,建议改用 MV_CC_RegisterEventCallBackEx接口)
  2529. * @param handle:设备句柄
  2530. * @param cbEvent [IN] 事件回调函数指针
  2531. * @param pUser [IN] 用户自定义变量
  2532. * @return 见返回错误码
  2533. * @fn MV_CC_RegisterEventCallBack
  2534. * @brief Register event callback (this interface has been deprecated and is recommended to be converted to the MV_CC_RegisterEventCallBackEx interface)
  2535. * @param handle:设备句柄
  2536. * @param cbEvent [IN] event callback pointer
  2537. * @param pUser [IN] User defined value
  2538. * @return 见返回错误码
  2539. ************************************************************************/
  2540. MV_CAMCTRL_API int __stdcall MV_CC_RegisterEventCallBack(void* handle,
  2541. void(__stdcall* cbEvent)(unsigned int nExternalEventId, void* pUser),
  2542. void* pUser);
  2543. /************************************************************************
  2544. * @fn MV_CC_SaveImageEx
  2545. * @brief 保存图片,支持Bmp和Jpeg.编码质量在50-99之前 (该接口已弃用,建议改用 MV_CC_SaveImageEx2接口)
  2546. * @param pSaveParam [IN][OUT] 保存图片参数结构体
  2547. pData; // [IN] 输入数据缓存
  2548. nDataLen; // [IN] 输入数据大小
  2549. enPixelType; // [IN] 输入数据的像素格式
  2550. nWidth; // [IN] 图像宽
  2551. nHeight; // [IN] 图像高
  2552. pImageBuffer; // [OUT] 输出图片缓存
  2553. nImageLen; // [OUT] 输出图片大小
  2554. nBufferSize; // [IN] 提供的输出缓冲区大小
  2555. enImageType; // [IN] 输出图片格式
  2556. nJpgQuality; // [IN] 编码质量, (50-99]
  2557. nReserved[4];
  2558. * @return 成功,返回MV_OK;错误,返回错误码
  2559. * @fn MV_CC_SaveImageEx
  2560. * @brief Save image, support Bmp and Jpeg. Encoding quality, (50-99]
  2561. * @param pSaveParam [IN][OUT] Save image parameters structure
  2562. pData; // [IN] Input data buffer
  2563. nDataLen; // [IN] Input data size
  2564. enPixelType; // [IN] Pixel format of input data
  2565. nWidth; // [IN] Image width
  2566. nHeight; // [IN] Image height
  2567. pImageBuffer; // [OUT] Output image buffer
  2568. nImageLen; // [OUT] Output image size
  2569. nBufferSize; // [IN] Output buffer size provided
  2570. enImageType; // [IN] Output image format
  2571. nJpgQuality; // [IN] Encoding quality, (50-99]
  2572. nReserved[4];
  2573. * @return Success, return MV_OK. Failure, return error code
  2574. ************************************************************************/
  2575. MV_CAMCTRL_API int __stdcall MV_CC_SaveImageEx(IN OUT MV_SAVE_IMAGE_PARAM_EX* pSaveParam);
  2576. #ifdef __cplusplus
  2577. }
  2578. #endif
  2579. #endif //_MV_CAMERA_CTRL_H_