imos_sdk_pub.h 43 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172
  1. /*******************************************************************************
  2. Copyright (c) 2008-2009, Hangzhou H3C Technologies Co., Ltd. All rights reserved.
  3. --------------------------------------------------------------------------------
  4. imos_sdk_pub.h
  5. Project Code: MW_SDK
  6. Module Name: SDK
  7. Date Created: 2012-01-14
  8. Author:
  9. Description: 该文件定义了sdk相关的枚举、结构体
  10. --------------------------------------------------------------------------------
  11. Modification History
  12. DATE NAME DESCRIPTION
  13. --------------------------------------------------------------------------------
  14. 2012-01-14
  15. *******************************************************************************/
  16. #ifndef __IMOS_SDK_PUB_H__
  17. #define __IMOS_SDK_PUB_H__
  18. #ifdef __cplusplus
  19. extern "C"{
  20. #endif /* __cplusplus */
  21. /**
  22. * @struct tagMwPoint
  23. * @brief 点坐标
  24. * @attention 无
  25. */
  26. typedef struct tagMwPoint
  27. {
  28. ULONG ulX; /**< 横坐标 */
  29. ULONG ulY; /**< 纵坐标 */
  30. }IMOS_MW_POINT_S;
  31. /**
  32. * @struct tagMwPoint
  33. * @brief 线坐标结构
  34. * @attention 无
  35. */
  36. typedef struct tagMwLine
  37. {
  38. IMOS_MW_POINT_S stHead; /**< 头坐标 */
  39. IMOS_MW_POINT_S stTail; /**< 尾坐标 */
  40. }IMOS_MW_LINE_S;
  41. /**
  42. * @struct tagMwRectangle
  43. * @brief 矩形框坐标结构
  44. * @attention 无
  45. */
  46. typedef struct tagMwRectangle
  47. {
  48. IMOS_MW_POINT_S stTopLeft; /**< 左上角坐标 */
  49. IMOS_MW_POINT_S stBotRight; /**< 右下角坐标 */
  50. }IMOS_MW_RECTANGLE_S;
  51. /**
  52. * @struct tagMwQuadrangle
  53. * @brief 四方形框坐标结构
  54. * @attention 无
  55. */
  56. typedef struct tagMwQuadrangle
  57. {
  58. IMOS_MW_POINT_S stTopLeft; /**< 左上角坐标 */
  59. IMOS_MW_POINT_S stTopRight; /**< 右上角坐标 */
  60. IMOS_MW_POINT_S stBotLeft; /**< 左下角坐标 */
  61. IMOS_MW_POINT_S stBotRight; /**< 右下角坐标 */
  62. }IMOS_MW_QUADRANGLE_S;
  63. /**
  64. * @struct tagMwAddr
  65. * @brief 地址结构
  66. * @attention
  67. */
  68. typedef struct tagMwAddr
  69. {
  70. CHAR szIPAddr[IMOS_MW_IPADDR_LEN]; /**< IP地址 */
  71. USHORT usPort; /**< 端口 */
  72. USHORT usReserve; /**< 保留 */
  73. }IMOS_MW_ADDR_S;
  74. #if 0
  75. #endif
  76. /******************************* 系统、设备维护相关结构 ***********************************/
  77. /**
  78. * @struct tagMwPlayerStatus
  79. * @brief 播放器状态
  80. * @attention 无
  81. */
  82. typedef struct tagMwPlayerStatus
  83. {
  84. ULONG ulStreamHandle; /**< 流句柄 */
  85. ULONG ulErrCode; /**< 错误码 */
  86. }IMOS_MW_PLAYER_STATUS_S;
  87. /**
  88. * @struct tagMwTime
  89. * @brief 时间信息
  90. * @attention
  91. */
  92. typedef struct tagMwTime
  93. {
  94. USHORT usYear; /**< 年,当前年数(如2009年时,该值为2009) */
  95. USHORT usMonth; /**< 月,当前月份(1-12) */
  96. USHORT usMonthDay; /**< 日,每月的几号(1-31) */
  97. USHORT usHour; /**< 时,当前小时数(0-23) */
  98. USHORT usMinute; /**< 分,当前分钟数(0-59) */
  99. USHORT usSecond; /**< 秒,当前秒数(0-60) */
  100. USHORT usWeekday; /**< 周几,每周的星期几(0-6),0 对应周日,1-6 对应周一 至 周六 , 暂未使用 */
  101. USHORT usReserve; /**< 保留 */
  102. }IMOS_MW_TIME_S;
  103. /**
  104. * @struct tagMwSystemTimeInfo
  105. * @brief 系统(本地)时间
  106. * @attention lTimeZone为 本地时区与零时区的差,例如 北京时间UTC+8,则填写 8
  107. */
  108. typedef struct tagMwSystemTimeInfo
  109. {
  110. LONG lTimeZone; /**< 设置系统时区, -12到12,对应和标准时间的偏差 */
  111. IMOS_MW_TIME_S stLocalTime; /**< 本地时间 */
  112. }IMOS_MW_SYSTEM_TIME_INFO_S;
  113. /**
  114. * @struct tagMwUserInfo
  115. * @brief 用户信息
  116. * @attention 删除用户信息时,只需传入用户名即可
  117. */
  118. typedef struct tagMwUserInfo
  119. {
  120. CHAR szUserName[IMOS_MW_USER_NAME_LEN + 4]; /**< 用户名 */
  121. CHAR szPassword[IMOS_MW_USER_PASSWORD_LEN + 4]; /**< 用户密码 */
  122. ULONG ulLevel; /**< 用户级别, 参见: IMOS_MW_USERLEVEL_ADMINISTRATOR 等 */
  123. }IMOS_MW_USER_INFO_S;
  124. /**
  125. * @struct tagMwBasicDeviceInfo
  126. * @brief 设备基本信息
  127. * @attention 无
  128. */
  129. typedef struct tagMwBasicDeviceInfo
  130. {
  131. CHAR szManufacturer[IMOS_MW_VERSION_LEN]; /**< 厂商 */
  132. CHAR szDeviceModel[IMOS_MW_VERSION_LEN]; /**< 设备类型 */
  133. CHAR szSerialNumber[IMOS_MW_VERSION_LEN]; /**< 设备序列号 */
  134. CHAR szDeviceMAC[IMOS_MW_VERSION_LEN]; /**< 设备MAC地址 */
  135. CHAR szFirmwareVersion[IMOS_MW_VERSION_LEN]; /**< 软件版本, program 版本 */
  136. CHAR szHardwareID[IMOS_MW_VERSION_LEN]; /**< 硬件标识 */
  137. CHAR szPCBVersion[IMOS_MW_VERSION_LEN]; /**< PCB版本 */
  138. CHAR szUbootVersion[IMOS_MW_VERSION_LEN]; /**< UBOOT引导版本 */
  139. }IMOS_MW_BASIC_DEVICE_INFO_S;
  140. /**
  141. * @struct tagMwSyslogServer
  142. * @brief 日志主机的IP地址和端口
  143. * @attention 无
  144. */
  145. typedef struct tagMwSyslogServerInfo
  146. {
  147. BOOL_T bEnable; /**< 使能日志主机 */
  148. CHAR szSyslogIP[IMOS_MW_IPADDR_LEN]; /**< 日志主机的IP地址 */
  149. USHORT usPort; /**< 日志主机端口号 */
  150. USHORT usReserve; /**< 保留字段,暂不使用 */
  151. }IMOS_MW_SYSLOG_SERVER_INFO_S;
  152. #if 0
  153. #endif
  154. /******************************* 网口信息 ***********************************/
  155. /**
  156. * @struct tagMwPPPoE
  157. * @brief PPPoE配置
  158. * @attention 无
  159. */
  160. typedef struct tagMwPPPoE
  161. {
  162. CHAR szUserName[IMOS_MW_PPPOE_USERNAME_LEN + 4]; /**< PPPoE账号 */
  163. CHAR szPassword[IMOS_MW_PPPOE_PASSWORD_LEN + 4]; /**< PPPoE密码 */
  164. }IMOS_MW_PPPOE_S;
  165. /**
  166. * @struct tagMwUNPCfg
  167. * @brief UNP配置
  168. * @attention
  169. */
  170. typedef struct tagMwUNPCfg
  171. {
  172. BOOL_T bEnable; /**< UNP是否使能 */
  173. CHAR szAddress[IMOS_MW_IPADDR_LEN]; /**< UNP server 地址 */
  174. BOOL_T bIdentify; /**< 是否鉴权 */
  175. CHAR szUserName[IMOS_MW_UNP_USERNAME_LEN + 4]; /**< UNP帐号 */
  176. CHAR szPassword[IMOS_MW_UNP_PASSWORD_LEN + 4]; /**< UNP密码 */
  177. }IMOS_MW_UNP_CFG_S;
  178. /**
  179. * @struct tagMwNetworkInterfaceCfg
  180. * @brief 网口信息
  181. * @attention
  182. */
  183. typedef struct tagMwNetworkInterfaceCfg
  184. {
  185. ULONG ulIPGetType; /**< IP获取方式, 参见: IMOS_MW_IP_GET_TYPE_STATIC 等 */
  186. IMOS_MW_PPPOE_S stPPPoE; /**< PPPoE配置 */
  187. ULONG ulMTULen; /**< MTU长度, IP获取方式为PPPoE时该参数无效 */
  188. CHAR szIpAddress[IMOS_MW_IPADDR_LEN]; /**< IP地址 */
  189. CHAR szIpNetmask[IMOS_MW_IPADDR_LEN]; /**< 子网掩码 */
  190. CHAR szIpGateway[IMOS_MW_IPADDR_LEN]; /**< 网关 */
  191. ULONG ulWorkMode; /**< 网口工作模式, 参见: IMOS_MW_ETH_WORKMODE_AUTO_NEGOTIATION 等 */
  192. }IMOS_MW_NETWORK_INTERFACE_CFG_S;
  193. /**
  194. * @struct tagMwNetworkInterfaceInfo
  195. * @brief 网口状态信息
  196. * @attention
  197. */
  198. typedef struct tagMwNetworkInterfaceInfo
  199. {
  200. CHAR szIpAddress[IMOS_MW_IPADDR_LEN]; /**< IP地址 */
  201. CHAR szIpNetmask[IMOS_MW_IPADDR_LEN]; /**< 子网掩码 */
  202. CHAR szIpGateway[IMOS_MW_IPADDR_LEN]; /**< 网关 */
  203. ULONG ulType; /**< 目前使用网口的类型,参见: IMOS_MW_PORT_MODE_ELECTRONIC 等 */
  204. ULONG ulWorkMode; /**< 网口当前工作模式, 参见: IMOS_MW_ETH_WORKMODE_AUTO_NEGOTIATION 等 */
  205. }IMOS_MW_NETWORK_INTERFACE_INFO_S;
  206. #if 0
  207. #endif
  208. /*************************** 图像相关结构 ****************************************/
  209. /**
  210. * @struct tagMwSharpness
  211. * @brief 锐度参数
  212. * @attention
  213. */
  214. typedef struct tagMwSharpness
  215. {
  216. ULONG ulMode; /**< 锐度模式, 参见: IMOS_MW_SHARPNESS_AUTO 等 */
  217. ULONG ulSharpness; /**< 锐度值 */
  218. }IMOS_MW_SHARPNESS_S;
  219. /**
  220. * @struct tagMwDenoise
  221. * @brief 图像降噪
  222. * @attention 无
  223. */
  224. typedef struct tagMwDenoise
  225. {
  226. ULONG ul2DLevel; /**< 2D降噪等级 */
  227. ULONG ul3DLevel; /**< 3D降噪等级 */
  228. }IMOS_MW_DENOISE_S;
  229. /**
  230. * @struct tagMwWhiteBalance
  231. * @brief 白平衡参数
  232. * @attention
  233. */
  234. typedef struct tagMwWhiteBalance
  235. {
  236. ULONG ulMode; /**< 白平衡模式, 参见: IMOS_MW_WB_AUTO 等 */
  237. LONG lBlueOffset; /**< 蓝色偏移量 */
  238. LONG lRedOffset; /**< 红色偏移量 */
  239. }IMOS_MW_WHITE_BALANCE_S;
  240. /**
  241. * @struct tagMwImageEnhance
  242. * @brief 图像增强参数
  243. * @attention
  244. */
  245. typedef struct tagMwImageEnhance
  246. {
  247. ULONG ulBrightness; /**< 亮度 */
  248. ULONG ulContrast; /**< 对比度 */
  249. ULONG ulSaturation; /**< 饱和度 */
  250. ULONG ulHue; /**< 色调 */
  251. IMOS_MW_SHARPNESS_S stSharpness; /**< 锐度参数 */
  252. IMOS_MW_DENOISE_S stDenoise; /**< 降噪参数 */
  253. ULONG ulMirrorMode; /**< 镜像模式, 参见: IMOS_MW_MIRROR_MODE_NONE 等 */
  254. }IMOS_MW_IMAGE_ENHANCE_S;
  255. /**
  256. * @struct tagMwFocus
  257. * @brief 对焦参数
  258. * @attention
  259. */
  260. typedef struct tagMwFocus
  261. {
  262. ULONG ulFocusMode; /**< 对焦模式, 参见: IMOS_MW_FOCUS_AUTO 等 */
  263. ULONG ulAutoFocusSense; /**< 自动对焦灵敏度 */
  264. ULONG ulManualFocusMinDistance; /**< 最小对焦距离,手动对焦, 单位: 毫米 */
  265. }IMOS_MW_FOCUS_S;
  266. /**
  267. * @struct tagMwWhiteBalanceCfg
  268. * @brief 白平衡参数配置
  269. * @attention
  270. */
  271. typedef struct tagMwWhiteBalanceCfg
  272. {
  273. ULONG ulImageType; /**< 图像类型, 参见: IMOS_MW_IMAGE_TYPE_VIDEO 等 */
  274. IMOS_MW_WHITE_BALANCE_S stWhiteBalance; /**< 白平衡参数 */
  275. }IMOS_MW_WHITE_BALANCE_CFG_S;
  276. /**
  277. * @struct tagMwImageEnhanceCfg
  278. * @brief 图像增强参数配置
  279. * @attention
  280. */
  281. typedef struct tagMwImageEnhanceCfg
  282. {
  283. ULONG ulImageType; /**< 图像类型, 参见: IMOS_MW_IMAGE_TYPE_VIDEO 等 */
  284. IMOS_MW_IMAGE_ENHANCE_S stImageEnhance; /**< 图像增强参数 */
  285. }IMOS_MW_IMAGE_ENHANCE_CFG_S;
  286. /**
  287. * @struct tagMwImageEnhanceCfg
  288. * @brief 对焦参数配置
  289. * @attention
  290. */
  291. typedef struct tagMwFocusCfg
  292. {
  293. ULONG ulImageType; /**< 图像类型, 参见: IMOS_MW_IMAGE_TYPE_VIDEO 等 */
  294. IMOS_MW_FOCUS_S stFocus; /**< 对焦参数 */
  295. }IMOS_MW_FOCUS_CFG_S;
  296. /**
  297. * @struct tagMwConditionCfgEx
  298. * @brief 场景 环境参数
  299. * @attention
  300. */
  301. typedef struct tagMwConditionCfgEx
  302. {
  303. ULONG ulType; /**< 环境参数类型,参见: IMOS_MW_CONDITION_ILLUMINATION 等 */
  304. LONG lParam1; /**< 环境参数1 */
  305. LONG lParam2; /**< 环境参数2 */
  306. LONG lParam3; /**< 环境参数3 */
  307. }IMOS_MW_CONDITION_CFG_EX_S;
  308. #if 0
  309. #endif
  310. /*************************** OSD 相关结构 ****************************************/
  311. /**
  312. * @struct tagMwOSDInfoParam
  313. * @brief OSD 叠加内容
  314. * @attention 无
  315. */
  316. typedef struct tagMwOSDInfoParam
  317. {
  318. ULONG ulInfoType; /**< 叠加内容类型,参考: IMOS_MW_OSD_INFO_TYPE_UNUSED 等 */
  319. CHAR szValue[IMOS_MW_OSD_INFO_LEN + 4]; /**< 自定义 OSD 内容 */
  320. }IMOS_MW_OSD_INFO_PARAM_S;
  321. /**
  322. * @struct tagMwOSDInfoConf
  323. * @brief 叠加OSD 参数
  324. * @attention 无
  325. */
  326. typedef struct tagMwOSDInfoConf
  327. {
  328. ULONG ulIndex; /**< 叠加区域ID */
  329. BOOL_T bEnable; /**< 使能开关 */
  330. IMOS_MW_OSD_INFO_PARAM_S astInfoParam[IMOS_MW_INFO_OSD_LINE_MAX]; /**< 叠加内容 */
  331. IMOS_MW_RECTANGLE_S stArea; /**< 叠加区域 */
  332. }IMOS_MW_INFO_OSD_S;
  333. /**
  334. * @struct tagMwInfoOSDCfg
  335. * @brief 叠加OSD 配置
  336. * @attention 删除该配置时,只需指定待删除区域的ID
  337. */
  338. typedef struct tagMwInfoOSDCfg
  339. {
  340. ULONG ulAreaNum; /**< 叠加区域个数 */
  341. IMOS_MW_INFO_OSD_S astInfoOSD[1]; /**< 叠加OSD 配置,区域最大个数为: IMOS_MW_INFO_OSD_MAX_NUM */
  342. }IMOS_MW_INFO_OSD_CFG_S;
  343. /**
  344. * @struct tagMwOSDStyleCfg
  345. * @brief 叠加OSD 样式
  346. * @attention 无
  347. */
  348. typedef struct tagMwOSDStyleCfg
  349. {
  350. ULONG ulFontStyle; /**< 字体形式, 参见: IMOS_MW_OSD_FONT_STYLE_NORMAL 等 */
  351. ULONG ulFontSize; /**< 字体大小, 参见: IMOS_MW_OSD_FONT_SIZE_LARGE 等 */
  352. ULONG ulFontType; /**< 字体, 暂不支持设置 */
  353. ULONG ulColor; /**< 颜色, 参见: IMOS_MW_OSD_COLOR_WHITE 等 */
  354. ULONG ulAlpha; /**< 透明度, 参见: IMOS_MW_OSD_ALPHA_NO 等 */
  355. ULONG ulTimeFormat; /**< 时间格式, 参见: IMOS_MW_TIME_FORMAT_HHMMSS 等 */
  356. ULONG ulDateFormat; /**< 日期格式, 参见: IMOS_MW_DATE_FORMAT_YYYYMMDD 等 */
  357. }IMOS_MW_OSD_STYLE_CFG_S;
  358. #if 0
  359. #endif
  360. /******************************* 媒体流相关结构 ***********************************/
  361. /**
  362. * @struct tagMwResolution
  363. * @brief 分辨率
  364. * @attention
  365. */
  366. typedef struct tagMwResolution
  367. {
  368. ULONG ulWidth; /**< 宽,单位: 像素 */
  369. ULONG ulHeight; /**< 高,单位: 像素 */
  370. }IMOS_MW_RESOLUTION_S;
  371. /**
  372. * @struct tagMwVideoInModeCfg
  373. * @brief 采集制式
  374. * @attention
  375. */
  376. typedef struct tagMwVideoInModeCfg
  377. {
  378. IMOS_MW_RESOLUTION_S stResolution; /**< 采集分辨率 */
  379. ULONG ulFrameRate; /**< 采集帧率 */
  380. }IMOS_MW_VIDEOIN_MODE_CFG_S;
  381. /**
  382. * @struct tagMwVideoStreamConf
  383. * @brief 视频编码参数
  384. * @attention
  385. */
  386. typedef struct tagMwVideoStreamConf
  387. {
  388. BOOL_T bIsEnable; /**< 启动/关闭编码 0-关闭 1-启动 */
  389. ULONG ulEncodeFmt; /**< 编码格式,参见: IMOS_MW_STREAM_FORMAT_MPEG1 等 */
  390. IMOS_MW_RESOLUTION_S stResolution; /**< 编码分辨率 */
  391. ULONG ulBitRate; /**< 码率 */
  392. ULONG ulFrameRate; /**< 帧率 */
  393. ULONG ulGopType; /**< gop结构参数, 参考: IMOS_MW_GOP_TYPE_IP 等 */
  394. ULONG ulIInterval; /**< I帧间隔 */
  395. ULONG ulEncMode; /**< 编码模式,参见: IMOS_MW_ENCODE_MODE_CBR 等 */
  396. ULONG ulQuality; /**< 编码压缩质量 */
  397. ULONG ulSmoothValue; /**< 码流平滑 */
  398. }IMOS_MW_VIDEO_STREAM_CONF_S;
  399. /**
  400. * @struct tagMwVideoEncoderCfg
  401. * @brief 视频编码参数配置
  402. * @attention 获取指定流的编码参数时,需要传入流ID
  403. */
  404. typedef struct tagMwVideoEncoderCfg
  405. {
  406. ULONG ulStreamID; /**< 流ID, 参见: IMOS_MW_STREAM_ID_MAIN 等 */
  407. IMOS_MW_VIDEO_STREAM_CONF_S stVideoStreamCfg; /**< 视频编码参数 */
  408. }IMOS_MW_VIDEO_ENCODER_CFG_S;
  409. /**
  410. * @enum tagMwMediaStreamInfo
  411. * @brief 媒体流信息
  412. * @attention 无
  413. */
  414. typedef struct tagMwMediaStreamInfo
  415. {
  416. ULONG ulStreamHandle; /**< 流句柄 */
  417. ULONG ulStreamID; /**< 流ID, 参见: IMOS_MW_STREAM_ID_MAIN 等 */
  418. ULONG ulTransMode; /**< 传输模式,参见: IMOS_MW_TRANSFER_MODE_RTP_UDP 等 */
  419. CHAR szIPAddr[IMOS_MW_IPADDR_LEN]; /**< 流目的IP地址 */
  420. USHORT usPort; /**< 流目的端口 */
  421. USHORT usReserved; /**< 保留 */
  422. ULONG ulMediaType; /**< 媒体类型, 参见: IMOS_MW_MEDIA_VIDEO 等 */
  423. CHAR szUser[IMOS_MW_NAME_LEN]; /**< 流建立者 */
  424. }IMOS_MW_VIDEO_STREAM_INFO_S;
  425. /**
  426. * @struct tagMwVideoParam
  427. * @brief 视频解码参数
  428. * @attention 无
  429. */
  430. typedef struct tagMwVideoParam
  431. {
  432. ULONG ulFrameRate; /**< 帧率, 单位: fps */
  433. ULONG ulBitRate; /**< 码率, 单位: bps */
  434. ULONG ulRecvPktNum; /**< 已接收到包数 */
  435. ULONG ulLostPktNum; /**< 丢弃包数 */
  436. ULONG ulAllFrameNum; /**< 帧总数 */
  437. ULONG ulLostFrameNum; /**< 丢弃的帧数 */
  438. }IMOS_MW_VIDEO_PARAM_S;
  439. #if 0
  440. #endif
  441. /******************************* 存储(本地)相关结构 ***********************************/
  442. /**
  443. * @struct tagMwLocalPicStor
  444. * @brief 本地SD卡抓拍存储配置信息
  445. * @attention
  446. */
  447. typedef struct tagMwLocalPicStor
  448. {
  449. ULONG ulAllocPercent; /**< 分配容量百分比,单位 %,默认0, 界面暂不使用,界面不显示 */
  450. ULONG ulAllocMemory; /**< 分配容量, 单位: MB */
  451. ULONG ulSpareMemory; /**< 剩余容量, 单位: MB */
  452. ULONG ulCurrentFileNum; /**< 当前文件个数 */
  453. ULONG ulSpareFileNum; /**< 剩余可存文件个数 */
  454. ULONG ulStorPolicy; /**< 存储策略 参见: IMOS_MW_STOR_POLICY_XXX */
  455. ULONG ulStorMode; /**< SD卡存储模式 参见: IMOS_MW_LOCAL_STOR_XXX */
  456. }IMOS_MW_LOCAL_PIC_STORCFG_S;
  457. /**
  458. * @struct tagMwLocalVideoStor
  459. * @brief 本地SD卡视频存储配置信息
  460. * @attention
  461. */
  462. typedef struct tagMwLocalVideoStor
  463. {
  464. ULONG ulAllocPercent; /**< 分配容量百分比,单位 %,默认0, 界面暂不使用,界面不显示 */
  465. ULONG ulAllocMemory; /**< 分配容量, 单位: MB */
  466. ULONG ulPlanStreamID; /**< 计划流 流ID */
  467. ULONG ulManualStreamID; /**< 手动流 流ID */
  468. ULONG ulEventStreamID; /**< 事件流 流ID */
  469. ULONG ulStorPolicy; /**< 存储策略 参见: IMOS_MW_STOR_POLICY_XXX */
  470. ULONG ulStorMode; /**< SD卡存储模式 参见: IMOS_MW_LOCAL_STOR_XXX */
  471. }IMOS_MW_LOCAL_VIDEO_STORCFG_S;
  472. /**
  473. * @struct tagMwLocalStorInfo
  474. * @brief 本地SD 卡存储
  475. * @attention
  476. */
  477. typedef struct tagMwLocalStorInfo
  478. {
  479. ULONG ulTotalMemory; /**< 本地存储总容量(SD卡容量), 单位: MB */
  480. IMOS_MW_LOCAL_PIC_STORCFG_S stPicStorCfg; /**< SD卡抓拍图片存储配置 */
  481. IMOS_MW_LOCAL_VIDEO_STORCFG_S stVideoStorCfg; /**< SD卡视频存储配置 */
  482. }IMOS_MW_LOCAL_STOR_INFO_S;
  483. /**
  484. * @struct tagMwLocalStorPicInfo
  485. * @brief SD 卡文件信息
  486. * @attention
  487. */
  488. typedef struct tagMwStorLocalPicInfo
  489. {
  490. CHAR stFile[IMOS_MW_NAME_LEN]; /**< 文件ID, 单个文件ID 长度不超过 IMOS_MW_FILE_NAME_LEN */
  491. IMOS_MW_TIME_S stTime; /**< 时间(年月日时分秒) */
  492. CHAR szPictureInfo[IMOS_MW_NAME_LEN]; /**< 车牌号(卡口) */
  493. }IMOS_MW_STOR_LOCAL_PIC_INFO_S;
  494. /**
  495. * @struct tagMwStorLocalVideo
  496. * @brief 本地SD 卡 录像文件
  497. * @attention 无
  498. */
  499. typedef struct tagMwStorLocalVideo
  500. {
  501. CHAR szFile[IMOS_MW_FILE_NAME_LEN]; /**< 录像文件ID */
  502. ULONG ulFileSize; /**< 录像文件大小 */
  503. IMOS_MW_TIME_S stSartTime; /**< 录像文件开始时间 */
  504. IMOS_MW_TIME_S stEndTime; /**< 录像文件结束时间 */
  505. }IMOS_MW_STOR_LOCAL_VIDEO_S;
  506. /**
  507. * @struct tagMwStorPathInfo
  508. * @brief 存储路径
  509. * @attention 无
  510. */
  511. typedef struct tagMwStorPathInfo
  512. {
  513. CHAR szName[IMOS_MW_DEFAULT_PATH_LEN]; /**< 目录/文件 的名称 */
  514. ULONG ulDirType; /**< 路径属性: 目录/文件, 参见: IMOS_MW_STOR_PATH_DIR 等 */
  515. ULONG ulStorFileType; /**< 文件类型: 照片/录像, 参见: IMOS_MW_STOR_FILE_TYPE_VIDEO 等 */
  516. }IMOS_MW_STOR_PATH_INFO_S;
  517. #if 0
  518. #endif
  519. /******************************* 播放器相关结构 ***********************************/
  520. /**
  521. * @struct tagMwPhotoServerCfg
  522. * @brief 照片接收服务器配置
  523. * @attention
  524. */
  525. typedef struct tagMwPhotoServerCfg
  526. {
  527. ULONG ulProtocol; /**< 通信协议类型 */
  528. CHAR szCameraID[IMOS_MW_PHOTOSERVER_CODE_LEN + 4]; /**< 相机编号 */
  529. CHAR szTollgateID[IMOS_MW_PHOTOSERVER_CODE_LEN + 4]; /**< 卡口编号 */
  530. CHAR szDrivewayID[IMOS_MW_PHOTOSERVER_CODE_LEN + 4]; /**< 道路编号 */
  531. CHAR szDirectionID[IMOS_MW_PHOTOSERVER_CODE_LEN + 4]; /**< 方向编号 */
  532. CHAR szDeviceID[IMOS_MW_PHOTOSERVER_CODE_LEN + 4]; /**< 设备编号 */
  533. CHAR szPassword[IMOS_MW_PHOTOSERVER_CODE_LEN + 4]; /**< 平台接入密码 */
  534. CHAR szUserName[IMOS_MW_PHOTOSERVER_CODE_LEN + 4]; /**< 接入平台用户名 */
  535. CHAR szServerPassword[IMOS_MW_PHOTOSERVER_CODE_LEN + 4]; /**< 接入平台密码 */
  536. IMOS_MW_ADDR_S stServerAddr; /**< 照片服务器地址 */
  537. }IMOS_MW_PHOTO_SERVER_CFG_S;
  538. /**
  539. * @struct tagMwUniviewMultiProtocolHeader
  540. * @brief 宇视协议信息头,多张照片
  541. * @attention 对外接口
  542. */
  543. typedef struct tagMwUniviewMultiProtocolHeader
  544. {
  545. CHAR *apcData[IMOS_MW_TRAFFIC_PIC_MAX_NUM]; /**< 数据指针 */
  546. ULONG aulDataLen[IMOS_MW_TRAFFIC_PIC_MAX_NUM]; /**< 数据长度 */
  547. ULONG aulPicType[IMOS_MW_TRAFFIC_PIC_MAX_NUM]; /**< 照片类型, 参照:IMOS_MW_IMAGE_VEHICLE */
  548. CHAR acPassTime[IMOS_MW_TRAFFIC_PIC_MAX_NUM][IMOS_MW_UNIVIEW_MAX_TIME_LEN]; /**< 经过时间 */
  549. ULONG ulPicNumber; /**< 照片张数 */
  550. /* 设备信息 */
  551. LONG lApplicationType; /**< 应用类型:对应相关产品 */
  552. CHAR szCamID[IMOS_MW_DEV_ID_MAX_LEN]; /**< 设备编号:采集设备统一编号或卡口相机编码, 不可为空 */
  553. CHAR szTollgateID[IMOS_MW_DEV_ID_MAX_LEN]; /**< 卡口编号:产生该信息的卡口代码 */
  554. CHAR szTollgateName[IMOS_MW_TOLLGATE_NAME_MAX_LEN]; /**< 卡口名称:可选字段 */
  555. ULONG ulCameraType; /**< 相机类型 0 全景 1特性 */
  556. ULONG ulRecordID; /**<车辆信息编号:由1开始自动增长(转换成字符串要求不超过16字节) */
  557. /* 时间、地点信息 */
  558. CHAR szPassTime[IMOS_MW_UNIVIEW_MAX_TIME_LEN]; /**< 经过时刻:YYYYMMDDHHMMSS, 时间按24小时制 */
  559. CHAR szPlaceName[IMOS_MW_PLACE_NAME_MAX_LEN]; /**< 地点名称 */
  560. LONG lLaneID; /**< 车道编号:从1开始, 车辆行驶方向最左车道为1,由左向右顺序编号 */
  561. LONG lLaneType; /**< 车道类型:0-机动车道,1-非机动车道 */
  562. /**< 方向编号:1-东向西 2-西向东 3-南向北 4-北向南
  563. 5-东南向西北 6-西北向东南 7-东北向西南 8-西南向东北 */
  564. LONG lDirection;
  565. CHAR szDirectionName[IMOS_MW_DIRECTION_NAME_MAX_LEN]; /**< 方向名称:可选字段 */
  566. /* 车牌信息 */
  567. CHAR szCarPlate[IMOS_MW_CAR_PLATE_MAX_LEN]; /**< 号牌号码:不能自动识别的用"-"表示 */
  568. ULONG aulLPRRect[4]; /**< 车牌坐标:XL=a[0], YL=a[1], XR=a[2], YR=a[3] */
  569. LONG lPlateType; /**< 号牌种类:按GA24.7编码 */
  570. LONG lPlateColor; /**< 号牌颜色:0-白色1-黄色 2-蓝色 3-黑色 4-其他 */
  571. LONG lPlateNumber; /**< 号牌数量 */
  572. /**< 号牌一致:
  573. 0-车头和车尾号牌号码不一致
  574. 1-车头和车尾号牌号码完全一致
  575. 2-车头号牌号码无法自动识别
  576. 3-车尾号牌号码无法自动识别
  577. 4-车头和车尾号牌号码均无法自动识别 */
  578. LONG lPlateCoincide;
  579. CHAR szRearVehiclePlateID[IMOS_MW_CAR_PLATE_MAX_LEN]; /**< 尾部号牌号码:被查控车辆车尾号牌号码,允许车辆尾部号牌号码不全。不能自动识别的用"-"表示 */
  580. LONG lRearPlateColor; /**< 尾部号牌颜色: 0-白色1-黄色 2-蓝色 3-黑色 4-其他 */
  581. LONG lRearPlateType; /**< 尾部号牌种类: 按GA24.7编码; 或者1-单排 2-武警 3-警用 4-双排 5-其他 */
  582. /**< 车辆信息 */
  583. ULONG aulVehicleXY[4]; /**< 车辆坐标:XL=a[0], YL=a[1], XR=a[2], YR=a[3] */
  584. CHAR szVehicleBrand[IMOS_MW_CAR_VEHICLE_BRAND_LEN]; /**< 车辆厂牌编码(自行编码) 考虑到字节对齐定义长度为4,实际使用长度为2 */
  585. LONG lVehicleBody; /**< 车辆外型编码(自行编码) */
  586. LONG lVehicleType; /**< 车辆类型 0-未知,1-小型车 2-中型车 3-大型车 4-其他 */
  587. LONG lVehicleLength; /**< 车外廓长(以厘米为单位) */
  588. LONG lVehicleColorDept; /**< 车身颜色深浅:0-未知,1-浅,2-深 */
  589. /**< 车身颜色:
  590. A:白,B:灰,C:黄,D:粉,E:红,F:紫,G:绿,H:蓝,
  591. I:棕,J:黑,K:橙,L:青,M:银,N:银白,Z:其他(!) */
  592. CHAR cVehicleColor; /* 车身颜色 */
  593. /* 识别,注:后面的UCHAR紧跟CHAR */
  594. UCHAR ucPlateScore; /**< 此次识别中,整牌的置信度,100最大 */
  595. UCHAR ucRearPlateScore; /**< 尾部号码置信度,100最大 */
  596. UCHAR ucPicType; /**< 0:实时照片,1:历史照片 */
  597. LONG lIdentifyStatus; /**< 识别状态:0-识别成功 1-不成功 2-不完整(!) 3-表示需要平台识别 */
  598. LONG lIdentifyTime; /**< 识别时间, 单位毫秒 */
  599. LONG lDressColor; /**< 行人衣着颜色(!) */
  600. LONG lDealTag; /**< 处理标记:0-初始状态未校对 1-已校对和保存 2-无效信息 3-已处理和保存(!) */
  601. /* 车速 */
  602. LONG lVehicleSpeed; /**< 车辆速度: 单位km/h, -1-无测速功能 */
  603. LONG lLimitedSpeed; /**< 执法限速: 车辆限速, 单位km/h */
  604. LONG lMarkedSpeed; /**< 标识限速 */
  605. LONG lDriveStatus; /**< 行驶状态:0-正常 1-嫌疑或按GA408.1编码 */
  606. /**< 红灯信息 */
  607. LONG lRedLightTime; /**< 红灯时间 */
  608. CHAR szRedLightStartTime[IMOS_MW_UNIVIEW_MAX_TIME_LEN]; /**< 红灯开始时间:YYYYMMDDHHMMSS, 精确到毫秒, 时间按24小时制 */
  609. CHAR szRedLightEndTime[IMOS_MW_UNIVIEW_MAX_TIME_LEN]; /**< 红灯结束时间:YYYYMMDDHHMMSS, 精确到毫秒, 时间按24小时制 */
  610. }IMOS_MW_MULTI_UNIVIEW_PROTOCOL_HEADER_S;
  611. /******************************************************************************
  612. 标识:IMOS_MW_ONE_PIC_INFO_S
  613. 类型:结构体
  614. 目的:单张照片信息
  615. 定义:
  616. ******************************************************************************/
  617. typedef struct tagMwOnePicInfo
  618. {
  619. VOID *pPicData; /* 图像类型:1-车辆大图 2-车牌彩色小图 3-车牌二值化图 */
  620. ULONG ulPicLen; /* 图片长度 */
  621. }IMOS_MW_SINGLE_PIC_INFO_S;
  622. /**
  623. * @struct tagMwPicData
  624. * @brief 照片数据
  625. * @attention 对外接口
  626. */
  627. typedef struct tagMwPicData
  628. {
  629. ULONG ulPicNum; /* 照片张数 */
  630. IMOS_MW_SINGLE_PIC_INFO_S astPicInfo[IMOS_MW_TRAFFIC_PIC_MAX_NUM]; /* 照片信息 */
  631. }IMOS_MW_PIC_INFO_S;
  632. /**
  633. * @struct tagMwDeviceRunInfo
  634. * @brief 设备运行状态 (系统运行时间,设备温度,CPU使用率,内存使用率)
  635. * @attention 无
  636. */
  637. typedef struct tagMwDeviceRunInfo
  638. {
  639. ULONG ulRunTime; /**< 设备运行时间 */
  640. LONG lDeviceTemperature; /**< 设备温度 */
  641. ULONG ulCPUUtilization; /**< CPU使用率 */
  642. ULONG ulMemUtilization; /**< 内存使用率 */
  643. }IMOS_MW_DEVICE_RUN_INFO_S;
  644. /**
  645. * @struct tagMwTransPortCfg
  646. * @brief 透明通道配置
  647. * @attention
  648. */
  649. typedef struct tagMwTransPortCfg
  650. {
  651. ULONG ulSerialID; /**< 串口ID (详见串口能力描述) */
  652. ULONG ulEnable; /**< 使能透明通道: 0 不启用, 1 启用 */
  653. ULONG ulTransMode; /**< 传输模式,暂不支持,留待扩展: UDP/TCP 等 */
  654. IMOS_MW_ADDR_S stPeerAddr; /**< 远端地址 */
  655. IMOS_MW_ADDR_S stLocalAddr; /**< 本端地址 */
  656. }IMOS_MW_TRANSPORT_CFG_S;
  657. /**
  658. * @struct tagMwSingTransPortCfg
  659. * @brief 单透明通道配置
  660. * @attention
  661. */
  662. typedef struct tagMwSingTransPortCfg
  663. {
  664. ULONG ulChannelID; /**< 透明通道号 */
  665. IMOS_MW_TRANSPORT_CFG_S stTransPortCfg; /**< 透明通道配置 */
  666. }IMOS_MW_SING_TRANSPORT_CFG_S;
  667. /**
  668. * @struct tagMwMultiTransPortCfg
  669. * @brief 多透明通道配置
  670. * @attention
  671. */
  672. typedef struct tagMwMultiTransPortCfg
  673. {
  674. ULONG ulTransPortNum; /**< 透明通道数 */
  675. IMOS_MW_SING_TRANSPORT_CFG_S astSingTransPortCfg[IMOS_MW_SERIAL_MAX_NUM]; /**< 各透明通道配置 */
  676. }IMOS_MW_MULTI_TRANSPORT_CFG_S;
  677. /**
  678. * @struct tagMwTrParam
  679. * @brief 交通参数结果
  680. * @attention
  681. */
  682. typedef struct tagMwTrParam
  683. {
  684. ULONG ulLaneID; /**< 车道编号 */
  685. ULONG ulTrafficFlow; /**< 汽车流量 */
  686. ULONG ulAveSpeed; /**< 平均速度,单位:千米/小时 */
  687. FLOAT fAveHeadTime; /**< 平均车头时距,单位:秒 */
  688. FLOAT fAveTimOcupyRat; /**< 平均车道时间占有率,,单位:X100% */
  689. FLOAT fAveHeadSpac; /**< 平均车头间距,单位:米 */
  690. FLOAT fVehQueueLen; /**< 车道队列长度,单位:米 */
  691. FLOAT fAveSpaOcupyRat; /**< 平均车道空间占有率,,单位:X100% */
  692. ULONG ulWayStat; /**< 车道通行状态,分为多个等级,例:拥堵,通畅等 */
  693. ULONG aulCarTypeCount[IMOS_MW_CAR_TYPE_NUM]; /**< 各种车辆类型的车流量 0-11分别代表轿车、SUV、面包车、小货车、
  694. 中巴车、大客车、大货车、大型车、中型车、小型车、摩托车、超长车 */
  695. ULONG aulLPRColorCount[IMOS_MW_LPR_COLOR_NUM]; /**< 各种车牌类型的车流量 0-4 白牌、黄牌、蓝牌、黑牌、其他 */
  696. ULONG aulSpeedCarCount[IMOS_MW_CAR_SPEED_NUM]; /**< 各车速统计 0 代表超速,1代表低速 未实现 */
  697. ULONG ulVehicles; /**< 通过车辆总数 辆 未实现 */
  698. ULONG ulVehicleLength; /**< 车外轮廓 单位:厘米 未实现 */
  699. ULONG ulDensity; /**< 车辆密度 每公里的车辆数,单位辆/km 未实现 */
  700. ULONG ulVolume; /**< 交通量 辆/单位时间 未实现 */
  701. ULONG ulFlowRate; /**< 流率 辆/小时 未实现 */
  702. ULONG ulBackOfQueue; /**< 旅行时间 秒 未实现 */
  703. ULONG ulDelay; /**< 延误 秒 未实现 */
  704. }IMOS_MW_TRAFFIC_PARA_S;
  705. /**
  706. * @struct tagMwTrParamRes
  707. * @brief 各个车道交通参数结果
  708. * @attention
  709. */
  710. typedef struct tagMwTrParamRes
  711. {
  712. CHAR szStartTime[IMOS_MW_UNIVIEW_MAX_TIME_LEN]; /* 开始时间 YYYYMMDDhhmmss*/
  713. ULONG ulDriveWayNum; /* 实际配置的车道数 */
  714. IMOS_MW_TRAFFIC_PARA_S astTrParaRslt[IMOS_MW_DRIVEWAY_NUM_MAX]; /* 各车道交通流量参数结果 */
  715. }IMOS_MW_TRAFFIC_PARA_RSLT_S;
  716. /**
  717. * @enum tagMwEpTgVehicleStat
  718. * @brief 车辆进出状态
  719. * @attention
  720. */
  721. typedef enum tagMwEpTgVehicleStat
  722. {
  723. VEHICLE_STAT_INVALID = -1, /* 进出状态未变化 */
  724. VEHICLE_STAT_NONE = 0, /* 车辆初始状态 */
  725. VEHICLE_STAT_IN_LINE = 1, /* 车辆进入拌线 */
  726. }IMOS_MW_TRAFFIC_VEHICLE_STAT_E;
  727. /**
  728. * @struct tagMwVehicleState
  729. * @brief 各个车道车辆进出状态
  730. * @attention
  731. */
  732. typedef struct tagMwVehicleState
  733. {
  734. ULONG ulDriveWayNum; /* 实际配置的车道数 */
  735. CHAR szStatPassTime[IMOS_MW_UNIVIEW_MAX_TIME_LEN]; /* 通过时间 YYYYMMDDHHMMSSMMM */
  736. IMOS_MW_TRAFFIC_VEHICLE_STAT_E aenVehicleState[IMOS_MW_DRIVEWAY_NUM_MAX]; /* 各车道车辆进出状态 */
  737. ULONG aulDriveWayCode[IMOS_MW_DRIVEWAY_NUM_MAX]; /* 各个车道编码 */
  738. }IMOS_MW_VEHICLE_STATE_S;
  739. /**
  740. * @struct tagMwDayNight
  741. * @brief 昼夜模式参数
  742. * @attention
  743. */
  744. typedef struct tagMwDayNight
  745. {
  746. ULONG ulMode; /**< 昼夜模式, 参见: IMOS_MW_DAYNIGHT_AUTO 等 */
  747. ULONG ulSensitivity; /**< 切换灵敏度 */
  748. }IMOS_MW_DAYNIGHT_S;
  749. /**
  750. * @struct tagMwMetering
  751. * @brief 测光参数
  752. * @attention
  753. */
  754. typedef struct tagMwMetering
  755. {
  756. ULONG ulMode; /**< 测光模式, 参见: IMOS_MW_METERING_CENTER 等 */
  757. IMOS_MW_RECTANGLE_S stArea; /**< 测光区域 */
  758. ULONG ulRefBrightness; /**< 参考亮度 */
  759. ULONG ulHoldTime; /**< 持续时间 */
  760. }IMOS_MW_METERING_S;
  761. /**
  762. * @struct tagMwImgWDR
  763. * @brief 宽动态参数
  764. * @attention
  765. */
  766. typedef struct tagMwImgWDR
  767. {
  768. ULONG ulMode; /**< 宽动态模式, 参见: IMOS_MW_WDR_DISABLE 等 */
  769. ULONG ulExpRatio; /**< 曝光比率,暂不支持 */
  770. ULONG ulOnSense; /**< 宽动态开启灵敏度 */
  771. ULONG ulOffSense; /**< 宽动态关闭灵敏度 */
  772. BOOL_T bAntiFlicker; /**< 宽动态条纹抑制 */
  773. }MW_WDR_S;
  774. /**
  775. * @struct tagMwSlowShutter
  776. * @brief 慢快门
  777. * @attention 无
  778. */
  779. typedef struct tagMwSlowShutter
  780. {
  781. BOOL_T bEnable; /**< 慢快门使能项 */
  782. ULONG ulMaxSlowShutter; /**< 最慢慢快门 */
  783. }IMOS_MW_SLOW_SHUTTER_S;
  784. /**
  785. * @struct tagMwCustomExposure
  786. * @brief 自定义曝光参数
  787. * @attention 无
  788. */
  789. typedef struct tagMwCustomExposure
  790. {
  791. ULONG ulMaxIris; /**< 最大光圈, 单位: f值*100 */
  792. ULONG ulMinIris; /**< 最小光圈, 单位: f值*100 */
  793. ULONG ulSlowShutter; /**< 最慢快门 */
  794. ULONG ulFastShutter; /**< 最快快门 */
  795. ULONG ulMaxGain; /**< 最大增益, 单位: db */
  796. ULONG ulMinGain; /**< 最小增益, 单位: db */
  797. }IMOS_MW_CUSTOM_EXPOSURE_S;
  798. /**
  799. * @struct tagMwImgExposure
  800. * @brief 曝光参数
  801. * @attention
  802. */
  803. typedef struct tagMwImgExposure
  804. {
  805. ULONG ulMode; /**< 曝光模式, 参见: IMOS_MW_EXPOSURE_AUTO 等 */
  806. LONG lExpCompensate; /**< 曝光补偿 */
  807. ULONG ulIris; /**< 光圈值, 单位: f值*100 */
  808. ULONG ulShutter; /**< 快门值 */
  809. ULONG ulGain; /**< 增益, 单位: db */
  810. IMOS_MW_CUSTOM_EXPOSURE_S stCustomExposure; /**< 自定义曝光参数 */
  811. IMOS_MW_SLOW_SHUTTER_S stSlowShutter; /**< 慢快门参数 */
  812. MW_WDR_S stWDR; /**< 宽动态参数 */
  813. IMOS_MW_METERING_S stMetering; /**< 测光参数 */
  814. IMOS_MW_DAYNIGHT_S stDayNight; /**< 昼夜参数 */
  815. }IMOS_MW_EXPOSURE_S;
  816. /**
  817. * @struct tagMwDriveExpandSerialParam
  818. * @brief 车道串口号参数
  819. * @attention 无
  820. */
  821. typedef struct tagMwDriveExpandSerialParam
  822. {
  823. ULONG aulSerialID[4]; /**< 串口号 */
  824. }IMOS_MW_DRIVE_EXPAND_SERIAL_PARAM_S;
  825. /**
  826. * @struct tagMwTimeSectionCfg
  827. * @brief 计划时间段配置
  828. * @attention
  829. * - 时间字符串格式: 由时分秒组成中间使用":"号隔开, 如 00:01:59 表示 0点1分59秒
  830. */
  831. typedef struct tagMwTimeSectionCfg
  832. {
  833. CHAR szStartTime[12]; /**< 起始时间 */
  834. CHAR szEndTime[12]; /**< 结束时间 */
  835. }IMOS_MW_TIME_SECTION_S;
  836. /**
  837. * @struct tagMwVehicleDrvCfg
  838. * @brief 车辆行驶方向配置
  839. * @attention
  840. */
  841. typedef struct tagMwVehicleDrvCfg
  842. {
  843. ULONG ulDrivingDirection; /**< 车辆行驶方向,参见: IMOS_MW_DRIVING_DIRECTION_COME 等 */
  844. IMOS_MW_TIME_SECTION_S stTimeSection; /**< 行驶方向生效时间段 */
  845. }IMOS_MW_VEHICLE_DRV_CFG_S;
  846. /**
  847. * @struct tagMwDriveExpandParam
  848. * @brief 车道扩展参数
  849. * @attention 无
  850. */
  851. typedef struct tagMwDriveExpandParam
  852. {
  853. IMOS_MW_VEHICLE_DRV_CFG_S astDrvCfg[4]; /**< 车辆行驶方向配置 */
  854. }IMOS_MW_DRIVE_EXPAND_PARAM_S;
  855. /**
  856. * @struct tagMwSingSpeedLimit
  857. * @brief 限速非默认配置
  858. * @attention
  859. */
  860. typedef struct tagMwSingSpeedLimit
  861. {
  862. ULONG ulLimitSpeed; /**< 限速值 */
  863. IMOS_MW_TIME_SECTION_S stTimeSection; /**< 限速使能时间段*/
  864. }IMOS_MW_SINGEL_SPEED_LIMIT_S;
  865. /**
  866. * @struct tagMwWaySpeedLimit
  867. * @brief 分车道限速
  868. * @attention
  869. */
  870. typedef struct tagMwWaySpeedLimit
  871. {
  872. ULONG ulDrivewaySpeedLimit; /**< 默认车道限速值 */
  873. ULONG ulDrivewayMinSpeedLimit; /**< 默认车道最低限速值,最低限速不需要分时段配置 */
  874. IMOS_MW_SINGEL_SPEED_LIMIT_S astWaySpeedLimit[6]; /**< 另配车道限速值 */
  875. }IMOS_MW_WAY_SPEED_LIMIT_S;
  876. /**
  877. * @struct tagMwCarSpeedLimit
  878. * @brief 分车型限速
  879. * @attention
  880. */
  881. typedef struct tagMwCarSpeedLimit
  882. {
  883. ULONG ulVehicleType; /**< 车型, 参见: IMOS_MW_VEHICLETYPE_SMALL 等 */
  884. ULONG ulMinSpeedLimit; /**< 默认最低限速值,最低限速不需要分时段配置 */
  885. ULONG ulSpeed; /**< 默认当前车型限速值 */
  886. IMOS_MW_SINGEL_SPEED_LIMIT_S astCarSpeedLimit[6]; /**< 另配当前车型限速值 */
  887. }IMOS_MW_CAR_SPEED_LIMIT_S;
  888. /**
  889. * @struct tagMwSpeedLimitUnion
  890. * @brief 限速参数
  891. * @attention
  892. */
  893. union tagMwSpeedLimitUnion
  894. {
  895. IMOS_MW_WAY_SPEED_LIMIT_S stWaySpeedLimit; /**< 按车道限速 */
  896. IMOS_MW_CAR_SPEED_LIMIT_S astVehicleTypeSpeedLimit[8]; /**< 车型限速信息 */
  897. };
  898. /**
  899. * @struct tagMwDriveWayType
  900. * @brief 车道行驶类型
  901. * @attention
  902. */
  903. typedef struct tagMwDriveWayType
  904. {
  905. ULONG ulWayType; /**< 车道行驶类型,参见IMOS_MW_DRIVING_TYPE_STRAIGHT */
  906. IMOS_MW_TIME_SECTION_S stTimeSection; /**< 车道行驶类型使能时间段*/
  907. }IMOS_MW_DRIVE_WAY_TYPE_S;
  908. /**
  909. * @struct tagMwSingDrivewayExpandCfg
  910. * @brief 单个车道拓展配置
  911. * @attention 无
  912. */
  913. typedef struct tagMwSingleWayExpandCfg
  914. {
  915. ULONG ulDriDirection; /**< 默认车辆行驶方向,参见IMOS_MW_DRIVING_DIRECTION_COME */
  916. IMOS_MW_VEHICLE_DRV_CFG_S astDriDirection[6]; /**< 独立配置车辆行驶方向 */
  917. ULONG ulDriWayType; /**< 默认车道行驶类型,参见: IMOS_MW_DRIVING_TYPE_STRAIGHT 等 */
  918. IMOS_MW_DRIVE_WAY_TYPE_S astDrivWayType[6]; /**< 独立配置车道行驶类型 */
  919. ULONG ulExeSpeedAdjustFactor; /**< 执行限速 */
  920. ULONG ulSpeedLimitMode; /**< 车辆限速模式, 参见: IMOS_MW_SPEEDLIMIT_MODE_DRIVEWAY 等 */
  921. int __unionReserve; /**< 保留(soap需要该字段来确认使用UNION的哪个) */
  922. union tagMwSpeedLimitUnion unDriveWaySpeedLimit; /**< 车道限速值配置 */
  923. }IMOS_MW_SING_DRIV_WAY_EXP_CFG_S;
  924. /**
  925. * @struct tagMwDrivewayExpandCfg
  926. * @brief 车道扩展配置
  927. * @attention 无
  928. */
  929. typedef struct tagMwDrivewayExpandCfg
  930. {
  931. IMOS_MW_DRIVE_EXPAND_PARAM_S astDrivewayExpandParam[4]; /**< 车道扩展参数 */
  932. IMOS_MW_DRIVE_EXPAND_SERIAL_PARAM_S stDrivewayExpandSerialParam; /**< 串口号参数 */
  933. IMOS_MW_SING_DRIV_WAY_EXP_CFG_S astSingDrivWayExpCfg[4]; /**< 车道拓展配置参数 */
  934. ULONG aulPPort[4]; /**< 车道可配置对应大筒相机P口 */
  935. }IMOS_MW_DRIVEWAY_EXPAND_CFG_S;
  936. /**
  937. * @struct tagMwIdentifyArea
  938. * @brief 识别区域
  939. * @attention
  940. */
  941. typedef struct tagMwIdentifyArea
  942. {
  943. ULONG ulAreaID; /**< 区域ID, 全F代表无效区域 */
  944. IMOS_MW_QUADRANGLE_S stIdentifyArea; /**< 识别区域坐标 */
  945. }IMOS_MW_IDENTIFY_AREA_S;
  946. typedef struct tagMwPlateIdentifyCfg
  947. {
  948. USHORT usMinLprWidthPix; /**< 最小车牌检测宽度--以象素为单位 */
  949. USHORT usMaxLprWidthPix; /**< 最大车牌检测宽度--以象素为单位 */
  950. ULONG ulAreaNum; /**< 识别区域个数 */
  951. IMOS_MW_IDENTIFY_AREA_S astIdentifyArea[4]; /**< 识别区域 */
  952. BOOL_T bNorthKoreaPlate; /**< 是否支持朝鲜车牌 */
  953. BOOL_T bAgroPlate; /**< 是否支持农用车牌 */
  954. BOOL_T bVehicleLogo; /**< 是否支持车标识别 */
  955. BOOL_T bVehicleColor; /**< 是否支持车身颜色识别 */
  956. UCHAR ucDefaultProvince; /**< 车牌缺省汉字 */
  957. UCHAR ucDefaultLetter; /**< 车牌缺省字母 */
  958. UCHAR aucReserve[2]; /**< 保留:aucReserve[0] bit位
  959. 0位:车牌矫正(0代表关,1代表开),3位:大车识别,4位:遮阳板检测功能使能,
  960. 5位安全带检测, 6位:车型检测,7位使馆车牌 */
  961. /**< 保留:aucReserve[1] 此配置是否为"视频检测设置"页面下发,
  962. BOOL_TRUE:"视频检测设置"页面下发 */
  963. ULONG ulSpecialPlate; /**< 特殊车牌 参见:IMOS_MW_PLATE_WG */
  964. CHAR szFilterPlateString[128]; /**< 异地牌照过滤字段,用/分割 */
  965. ULONG ulPlateParam; /**< 支持车牌识别参数,按位操作:0x01支持泥头车识别,不能按位 */
  966. ULONG ulCheckRepeatTime; /**< 重复车牌过滤时间,单位 秒 */
  967. ULONG ulNewPlateParam; /**< 新的车牌识别参数,按位操作,bit位0代表关,1代表开
  968. 0位:摩托车识别,1位:白名单放行使能 */
  969. ULONG ulMultiPlateIdentifyMode; /**< 卡口出入口多帧识别模式, 参见:IMOS_MW_TG_MULTI_IDENTIFY_MODE_NO */
  970. }IMOS_MW_PLATE_IDENTIFY_CFG_S;
  971. /**
  972. * @struct tagMwTriggerLine
  973. * @brief 触发线信息
  974. * @attention
  975. */
  976. typedef struct tagMwTriggerLine
  977. {
  978. ULONG ulLineID; /**< 触发线ID */
  979. BOOL_T bEnable; /**< 是否使能 */
  980. ULONG ulLineType; /**< 触发线类型,参见: IMOS_MW_TRIGGER_LINE_DEFAULT1 等 */
  981. ULONG ulTriggerDelay; /**< 延时触发 */
  982. IMOS_MW_LINE_S stLine; /**< 触发线位置 */
  983. }IMOS_MW_TRIGGERLINE_S;
  984. /**
  985. * @struct tagMwTriggerLineCfg
  986. * @brief 触发线配置
  987. * @attention
  988. */
  989. typedef struct tagMwTriggerLineCfg
  990. {
  991. ULONG ulLineNum; /**< 触发线条数 */
  992. IMOS_MW_TRIGGERLINE_S astTriggerLine[IMOS_MW_TRIGGER_LINE_NUM]; /**< 触发线配置 */
  993. }IMOS_MW_TRIGGERLINE_CFG_S;
  994. /**
  995. * @struct tagMwDrivewayLine
  996. * @brief 车道线
  997. * @attention
  998. */
  999. typedef struct tagMwDrivewayLine
  1000. {
  1001. ULONG ulLineID; /**< 车道线ID */
  1002. BOOL_T bEnable; /**< 车道线是否启用 */
  1003. ULONG ulLineType; /**< 车道线类型, 参见: IMOS_MW_DRIVEWAY_LINE_SOLID_WHITE 等 */
  1004. BOOL_T bEnableCoverDetect; /**< 是否启用压线检测 */
  1005. BOOL_T bDetectOverline; /**< 是否启用越线检测 */
  1006. FLOAT fSensitivity; /**< 压线检测灵敏度,说明: 车牌宽度 * 压线检测灵敏度 = 车身宽度 */
  1007. IMOS_MW_LINE_S stLine; /**< 位置坐标 */
  1008. }IMOS_MW_DRIVEWAY_LINE_S;
  1009. /**
  1010. * @struct tagMwDrivewayLineCfg
  1011. * @brief 车道线信息
  1012. * @attention
  1013. */
  1014. typedef struct tagMwDrivewayLineCfg
  1015. {
  1016. ULONG ulLineNum; /**< 车道线数目 */
  1017. IMOS_MW_DRIVEWAY_LINE_S astDrivewayLine[9]; /**< 车道线配置 */
  1018. }IMOS_MW_DRIVEWAYLINE_CFG_S;
  1019. /**
  1020. * @union tagMwListMatchRule
  1021. * @brief 名单匹配规则
  1022. * @attention
  1023. */
  1024. typedef struct tagMwListMatchRule
  1025. {
  1026. ULONG ulMatchMode; /* 匹配模式 0 模糊匹配,1 精确匹配*/
  1027. ULONG ulLetterFuzzyMatchLevel; /* 字母数字模糊匹配等级,等级:0.1.2; 仅ulMatchMode为0生效 */
  1028. BOOL_T bChineseIgnored; /* 是否忽略汉字匹配; 仅ulMatchMode为0生效 */
  1029. }IMOS_MW_LIST_MATCH_RULE_CFG;
  1030. /**
  1031. * @struct tagMwGateWhiteList
  1032. * @brief 出入口白名单配置
  1033. * @attention
  1034. */
  1035. typedef struct tagMwGateWhiteList
  1036. {
  1037. BOOL_T bEnabled; /* 是否使能名单 */
  1038. IMOS_MW_LIST_MATCH_RULE_CFG stMatchRule; /* 匹配规则 */
  1039. }IMOS_MW_GATE_WHITE_LIST_CFG_S;
  1040. /**
  1041. * @struct tagMwGateBlackList
  1042. * @brief 出入口黑名单配置
  1043. * @attention
  1044. */
  1045. typedef struct tagMwGateBLACKList
  1046. {
  1047. BOOL_T bEnabled; /* 是否使能名单 */
  1048. BOOL_T bLinkSwitch; /* 是否联动开关量 */
  1049. ULONG ulLinkSwitchID; /* 联动开关量ID */
  1050. IMOS_MW_LIST_MATCH_RULE_CFG stMatchRule; /* 匹配规则 */
  1051. }IMOS_MW_GATE_BLACK_LIST_CFG_S;
  1052. /**
  1053. *@union tagMwReleaseStrategyCfg
  1054. *@brief 放行策略
  1055. *@attention
  1056. */
  1057. typedef struct tagMwReleaseStrategyCfg
  1058. {
  1059. ULONG ulCtrlMode; /* 控制模式 0:服务器控制模式; 1:离线控制模式; 2:单机控制开闸 */
  1060. ULONG ulReleaseTactics; /* 开关量控制模式,取值: 0 所有车辆放行 1 白名单车辆放行 2 非黑名单车辆放行 */
  1061. BOOL_T bUnidentifiedRelease; /* 未识别车辆是否放行 */
  1062. ULONG ulOutputSwitchID; /* 放行开关量 */
  1063. }IMOS_MW_RELEASE_STRATEGY_CFG_S;
  1064. #ifdef __cplusplus
  1065. }
  1066. #endif
  1067. #endif /*end of __IMOS_SDK_PUB_H__*/