AspriseOCR_demo
添加引用代码(因为dll文件为VC编程,不能直接添加引用):
[DllImport("AspriseOCR.dll", EntryPoint = "OCR")]
public static extern IntPtr OCR(string file, int type);
[DllImport("AspriseOCR.dll", EntryPoint = "OCRpart")]
static extern IntPtr OCRpart(string file, int type, int startX, int startY, int width, int height);
[DllImport("AspriseOCR.dll", EntryPoint = "OCRBarCodes")]
static extern IntPtr OCRBarCodes(string file, int type);
[DllImport("AspriseOCR.dll", EntryPoint = "OCRpartBarCodes")]
static extern IntPtr OCRpartBarCodes(string file, int type, int startX, int startY, int width, int height);
AspriseOCR 4.0破解dll
AspriseOCR 4.0破解dll是由VC编写,所以引用需要用代码来实现,代码如下:
[DllImport(@"F:\ocr\OCR\OCR 图片识别\AspriseOCR 4.0破解dll\AspriseOCR.dll", EntryPoint = "OCR", CallingConvention = CallingConvention.Cdecl)]
public static extern IntPtr OCR(string file, int type);
[DllImport(@"F:\ocr\OCR\OCR 图片识别\AspriseOCR 4.0破解dll\AspriseOCR.dll", EntryPoint = "OCRpart", CallingConvention = CallingConvention.Cdecl)]
static extern IntPtr OCRpart(string file, int type, int startX, int startY, int width, int height);
[DllImport(@"F:\ocr\OCR\OCR 图片识别\AspriseOCR 4.0破解dll\AspriseOCR.dll", EntryPoint = "OCRBarCodes", CallingConvention = CallingConvention.Cdecl)]
static extern IntPtr OCRBarCodes(string file, int type);
[DllImport(@"F:\ocr\OCR\OCR 图片识别\AspriseOCR 4.0破解dll\AspriseOCR.dll", EntryPoint = "OCRpartBarCodes", CallingConvention = CallingConvention.Cdecl)]
static extern IntPtr OCRpartBarCodes(string file, int type, int startX, int startY, int width, int height);
使用实现代码如下:
Marshal.PtrToStringAnsi(OCRpart(PicturePath , -1, startX, startY, width, height));//返回值为字符串
return Marshal.PtrToStringAnsi(OCRpart(PicturePath, -1, 0, 0, 900, 200));
git常用命令
1. 创建git资源库
git init --bare 库名称
2. 在用户文件夹下把资源clone下来
git clone /g/software/repository/git/itheima .
注意:clone时候用户目录必须为空
3. 创建一个文件,纳入到版本控制中。
git add
第一次执行会出警告:warning: LF will be replaced by CRLF in readme.txt.
The file will have its original line endings in your working directory.
警告处理:需要配置用户信息
git config user.name = "zhangsan"
git config user.email = "itheima@gmail.com"
4. 提交到本地版本库里。
git commit
5. 推送到远程共享版本库中
git push origin master
6. 切换用户,拉取最新的文件
git pull
7. 查看仓库当前状态
git status
8. 查看修改了什么内容
git diff