From a8ff93a0cf274795f0e9c3d66093f1c4c6ccf972 Mon Sep 17 00:00:00 2001
From: zhangzengfei <zhangzengfei@iotlink.com>
Date: 星期二, 19 十一月 2019 15:57:02 +0800
Subject: [PATCH] feat: add cloud plate sdk

---
 csdk_struct.h |   87 ++++++++++++++++++++++++++++++++++++++++++-
 1 files changed, 85 insertions(+), 2 deletions(-)

diff --git a/csdk_struct.h b/csdk_struct.h
index 5d8d74f..e5a1465 100644
--- a/csdk_struct.h
+++ b/csdk_struct.h
@@ -69,8 +69,43 @@
     float prob;
 } cObjInfo;
 
-typedef struct _cPlateIDResult 
-{
+typedef struct _cPlateIDCfg {
+    int nFastMemorySize;            // 鍗曚綅 K
+    int nMemorySize;                // 鍗曚綅 M
+    int nMinPlateWidth;				// 妫�娴嬬殑鏈�灏忚溅鐗屽搴︼紝浠ュ儚绱犱负鍗曚綅
+    int nMaxPlateWidth;				// 妫�娴嬬殑鏈�澶ц溅鐗屽搴︼紝浠ュ儚绱犱负鍗曚綅
+    int nMaxImageWidth;				// 鏈�澶у浘鍍忓搴�
+    int nMaxImageHeight;			// 鏈�澶у浘鍍忛珮搴�
+
+    unsigned char bIsFieldImage;	// 鏄惁鏄満鍥惧儚
+    unsigned char bMovingImage;		// 璇嗗埆杩愬姩or闈欐鍥惧儚
+    unsigned char nOrderOpt;		// 杈撳嚭椤哄簭閫夐」 0-缃俊搴� 1-鑷笂鑰屼笅 2-鑷笅鑰屼笂
+    unsigned char bLeanCorrection;	// 鏄惁鍚敤杞︾墝鏃嬭浆鍔熻兘锛岄粯璁ゅ紑鍚�
+    unsigned char nImproveSpeed;	// 0: 璇嗗埆鐜囦紭鍏� 1:璇嗗埆閫熷害浼樺厛
+    unsigned char bCarLogo;			// 0: 涓嶆娴嬭溅鏍� 1: 妫�娴嬭溅鏍�
+    unsigned char bLotDetect;		// 0: 涓嶆娴嬭溅浣� 1: 妫�娴嬭溅浣�
+    unsigned char bShadow;			// 0: 閽堝鏃犻槾褰辩殑杞︾墝 1锛氶拡瀵规湁闃村奖鐨勮溅鐗岋紝榛樿寮�鍚�
+    unsigned char bShieldRailing;	// 0: 灞忚斀鏍忔潌骞叉壈锛� 1:涓嶅睆钄芥爮鏉嗗共鎵�
+    unsigned char bCarModel;		// 0: 涓嶈瘑鍒溅鍨嬶紝 1: 璇嗗埆杞﹀瀷
+    unsigned char bLocateTh;		// 杞︾墝瀹氫綅闃堝��
+    unsigned char bOCRTh;           // 杞︾墝璇嗗埆闃堝��
+
+    unsigned char bIndividual;		// 涓�у寲杞︾墝寮�鍚�
+    unsigned char bTwoRowYellow;	// 鍙屽眰榛勮壊杞︾墝寮�鍚�
+    unsigned char bArmPolice;		// 鍗曞眰姝﹁杞︾墝寮�鍚�
+    unsigned char bArmPolice2;		// 鍙屽眰姝﹁杞︾墝寮�鍚�
+    unsigned char bTwoRowArmy;		// 鍙屽眰鍐涢槦杞︾墝寮�鍚�
+    unsigned char bTractor;	    	// 鍐滅敤杞﹁溅鐗屽紑鍚�
+    unsigned char bEmbassy;		    // 浣块杞︾墝寮�鍚�
+    unsigned char bChangNei;		// 鍘傚唴杞︾墝寮�鍚�
+    unsigned char bMinHang;		    // 姘戣埅杞︾墝寮�鍚�
+    unsigned char bConsulate;		// 棰嗕簨棣嗚溅鐗屽紑鍚�
+    unsigned char bNewEnergy;		// 鏂拌兘婧愯溅鐗屽紑鍚�
+    unsigned char bOnlyTwoRowYellow;// 鍙瘑鍒弻灞傞粍鐗屽紑鍚�
+    unsigned char bOnlyLocation;    // 鍙畾浣嶈溅鐗屽紑鍚�
+}cPlateIDCfg;
+
+typedef struct _cPlateIDResult {
 	char license[16];	// 杞︾墝瀛楃涓�
 	char color[8];		// 杞︾墝棰滆壊
 
@@ -96,4 +131,52 @@
 	unsigned short nCarModelConfidence;	// 杞﹀瀷鍙俊搴�	
 }cPlateIDResult;
 
+typedef struct _cPlateIDCloudSDKCfg {
+	int iImageMode;         //0锛氫负甯фā寮� 1锛氫负鍦烘ā寮�
+	int iRecMode;           //璇嗗埆妯″紡锛�0锛氬崟寮犲浘鐗囪瘑鍒紝1:瑙嗛妫�娴�+璇嗗埆锛�2锛氳棰戝甯ц瀺鍚堣瘑鍒�(娉細1妯″紡姣�2妯″紡蹇紝浣嗚瘑鍒巼鍜屾崟鑾风巼姣�2浣�)
+	                          
+	int iMinPlateWidth;     //璇嗗埆鏈�灏忚溅鐗屽搴�
+	int iMaxPlateWidth;     //璇嗗埆鏈�澶ц溅鐗屽搴�
+	
+	int iImageWidth;        //鍥剧墖瀹藉害 
+	int iImageHeight;       //鍥剧墖楂樺害
+
+	int iMinHorAngle; 
+	int iMaxHorAngle;       //姘村钩鐭瑙掑害鑼冨洿锛屾敮鎸佹渶澶ц搴︿负[-30掳锛�30掳]
+	int iMinVerAngle;
+	int iMaxVerAngle;       //鍨傜洿鐭瑙掑害鑼冨洿锛屾敮鎸佹渶澶ц搴︿负[-30掳锛�30掳]
+
+	//姝や簺椤归拡瀵硅溅鍨嬭瘑鍒湁鐢紝鍏朵綑鏃犵敤
+	float fExpLeftRightR;   //杞﹁劯宸﹀彸鎵╁厖(杞︾墝鐨勫搴�)鍊嶆暟 鍙傝�冨�间负1.6
+	float fExpTopR;         //杞﹁劯涓婇儴鎵╁厖(杞︾墝鐨勯珮搴�)鍊嶆暟 鍙傝�冨�间负6.0
+	float fExpBottomR;      //杞﹁劯涓嬮儴鎵╁厖(杞︾墝鐨勯珮搴�)鍊嶆暟 鍙傝�冨�间负1.5
+}cPlateIDCloudSDKCfg;
+
+typedef struct _cPlateIDCloudSDKResult {
+	char number[20];     //璇嗗埆缁撴灉
+	cRECT PlateRect;    //杞︾墝浣嶇疆
+	int x[4];
+	int y[4];
+	int iConfidence;    //杞︾墝缃俊搴�
+	int ePlateType;     //杞︾墝绫诲瀷
+	int iMoveDir;       //杞﹁締杩愬姩鏂瑰悜 0锛氭湞杩戣繍鍔紝1锛氭湞杩滆繍鍔紝-1锛氭湭鐭�
+	int eVColor1;       //杞﹁韩涓婚鑹�
+	int eVColor2;       //杞﹁韩娆¢鑹�
+	int eVehicleBright; //杞﹁締娣辨祬鑹�
+	unsigned char *pResultBits; //瑙嗛璇嗗埆妯″紡涓姄鎷嶇殑鍥剧墖,瑙嗛妯″紡璇嗗埆涓嬫湁鏁堬紝闇�瑕佸紑杈�
+	
+	int iFramNo;        //瑙嗛妯″紡涓嬪抚鍙�
+	int sTime[7];       //瑙嗛璇嗗埆妯″紡涓姄鎷嶆寮犲浘鐨勬椂闂�
+	
+	//閽堝杞﹁劯璇嗗埆搴旂敤姝ら」锛屽叾浣欐棤鐢�
+	unsigned char  *pVehicleFaceImage; //瀵瑰簲鐨勮溅鑴哥殑鍥剧墖,闇�瑕佹彁鍓嶅紑杈熷唴瀛橈紝寮�杈熶釜鏈�澶у唴瀛樺氨鍙互锛屽楂樺彲浠ラ兘涓�1000
+	int iVehicleFaceWidth;             //杞﹁劯瀹藉害
+	int iVehicleFaceHeight;            //杞﹁劯楂樺害
+	int iGrayFaceFlag;                 //杞﹁劯鏄惁涓虹伆搴﹀浘
+
+	cRECT charLocation[20];     //杞︾墝瀛楃鐨勪綅缃�(鍩轰簬澶у浘)
+	int charConfidence[20];     //瀛楃璇嗗埆缃俊搴�
+	int iCharNum;               //杞︾墝瀛楃鏁扮洰
+}cPlateIDCloudSDKResult;
+
 #endif
\ No newline at end of file

--
Gitblit v1.8.0