123456789101112131415161718192021222324252627282930313233343536373839404142434445464748 |
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace OASystem.Domain.Dtos.Tencent
- {
-
-
-
- public static class OCRVerifyMethod
- {
-
-
-
-
-
-
- public static bool ImageType(string type)
- {
- string[] picBase64Array = type.Split(';');
- string picFormat = picBase64Array[0].Split('/')[1];
- if (picFormat.ToLower().Equals("png") || picFormat.ToLower().Equals("jpg") || picFormat.ToLower().Equals("jpeg") || picFormat.ToLower().Equals("bmp"))
- return true;
- return false;
- }
-
-
-
-
-
-
- public static bool ImageSize(string picBase64)
- {
- double strSize = 1024 * 1024 * 7;
- if (picBase64.Length < strSize)
- {
- return true;
- }
- return false;
- }
- }
- }
|