Add Enums.cs. PlateDetector Remove enum PlateType. ApiController Remove enums: LaneDirection, ModePlate
This commit is contained in:
parent
454251898d
commit
f4527e3eac
|
@ -80,6 +80,7 @@
|
|||
<Compile Include="AppConstant.cs" />
|
||||
<Compile Include="C3DeviceController.cs" />
|
||||
<Compile Include="Camera.cs" />
|
||||
<Compile Include="Enums.cs" />
|
||||
<Compile Include="ILane.cs" />
|
||||
<Compile Include="LaneIn.cs">
|
||||
<SubType>UserControl</SubType>
|
||||
|
|
|
@ -12,18 +12,6 @@ namespace AIParkingApplication
|
|||
private bool isHttpClientDisposabled;
|
||||
private int numberOfRetry;
|
||||
|
||||
public enum LaneDirection
|
||||
{
|
||||
In,
|
||||
Out
|
||||
}
|
||||
|
||||
public enum ModePlate
|
||||
{
|
||||
Sqare,
|
||||
Long
|
||||
}
|
||||
|
||||
public ApiController(string baseAddress, int numberOfRetry = 5)
|
||||
{
|
||||
httpClient = new HttpClient
|
||||
|
@ -123,7 +111,7 @@ namespace AIParkingApplication
|
|||
}
|
||||
|
||||
//Neu Dicrection la Out thi logID la logID lay ve khi check the
|
||||
public async Task<SaveLogRespone> SaveLog(LaneDirection direction, string cardID, string cameraID, ModePlate squareOrLong, string timeInOrOut, string textPlate, Mat plateImage, Mat plateImageResult, Mat PlateFrameImage, Mat FrameImage, string logID = "")
|
||||
public async Task<SaveLogRespone> SaveLog(LaneDirection direction, string cardID, string cameraID, PlateType squareOrLong, string timeInOrOut, string textPlate, Mat plateImage, Mat plateImageResult, Mat PlateFrameImage, Mat FrameImage, string logID = "")
|
||||
{
|
||||
string plateImageBase64 = Convert.ToBase64String(plateImage.ToBytes());
|
||||
string plateImageResultBase64 = Convert.ToBase64String(plateImageResult.ToBytes());
|
||||
|
@ -138,7 +126,7 @@ namespace AIParkingApplication
|
|||
CardID = cardID,
|
||||
TextPlate = textPlate,
|
||||
CameraID = cameraID,
|
||||
ModePlate = (squareOrLong == ModePlate.Sqare) ? "1":"0",
|
||||
ModePlate = (squareOrLong == PlateType.Square) ? "1":"0",
|
||||
TimeVehicleInOrOut = timeInOrOut,
|
||||
PlateImage = plateImageBase64,
|
||||
PlateResultImage = plateImageResultBase64,
|
||||
|
|
14
AIParkingApplication/Enums.cs
Normal file
14
AIParkingApplication/Enums.cs
Normal file
|
@ -0,0 +1,14 @@
|
|||
namespace AIParkingApplication
|
||||
{
|
||||
public enum PlateType
|
||||
{
|
||||
Square,
|
||||
Long
|
||||
}
|
||||
|
||||
public enum LaneDirection
|
||||
{
|
||||
In,
|
||||
Out
|
||||
}
|
||||
}
|
|
@ -81,12 +81,6 @@ namespace AIParkingApplication
|
|||
}
|
||||
}
|
||||
|
||||
public enum PlateType
|
||||
{
|
||||
Square,
|
||||
Long
|
||||
}
|
||||
|
||||
public static class PlateDetectorConstant
|
||||
{
|
||||
public const string SQUARE_PLATE_WEIGHT_FILENAME = "plate.xml";
|
||||
|
|
Loading…
Reference in New Issue
Block a user