using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading.Tasks;
namespace LB_SmartVisionCameraSDK.PHM6000
{
//typedef void (__stdcall* ShowInfo) (void* pData, int nSize);
///
/// 此回调函数用于显示参数信息,调试时使用,无返回值
///
/// 为字符串
/// 为字符串长度
[UnmanagedFunctionPointer(CallingConvention.StdCall)]
public delegate void ShowInfo(IntPtr pData, int nSize);
//typedef void (__stdcall* ShowRectInfo) (int left, int top, int right, int bottom);
///
/// 此回调函数用于在画兴趣区时显示矩形参数,无返回值
///
/// 左上角x坐标
/// 左上角y坐标
/// 右下角x坐标
/// 右下角y坐标
[UnmanagedFunctionPointer(CallingConvention.StdCall)]
public delegate void ShowRectInfo(int left, int top, int right, int bottom);
//typedef void (__stdcall* ShowObjectInfo) (int nType, void* pObjectInfo, int nCount);
///
/// 此回调函数用于在画兴趣区时显示所绘对象的参数,无返回值
///
/// 对象类型
/// 对象指针
/// 对象数据个数
[UnmanagedFunctionPointer(CallingConvention.StdCall)]
public delegate void ShowObjectInfo(int nType, IntPtr pObjectInfo, int nCount);
///
/// 图像的2D操作类
///
public class Pilot2D
{
//PILOT2D_API(void*) CreatePilot2DEntry(void* hWnd);
///
/// 创建二维图显示接口,返回其句柄
///
/// 为容纳二维显示控件的容器句柄
/// 返回二维显示控件的句柄
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "CreatePilot2DEntry")]
public static extern IntPtr CreatePilot2DEntry(IntPtr hWnd);
//PILOT2D_API(void) DestroyPilot2DEntry(void* pHandle);
///
/// 销毁二维图显示接口
///
/// 二维显示控件的句柄
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "DestroyPilot2DEntry")]
public static extern void DestroyPilot2DEntry(IntPtr pHandle);
//PILOT2D_API(void) SetImageSize(void* pHandle, int nWidth, int nHeight);
///
/// 设置图像大小,用于逐行添加显示数据
///
/// 二维显示控件的句柄
/// 宽度
/// 高度
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "SetImageSize")]
public static extern void SetImageSize(IntPtr pHandle, int nWidth, int nHeight);
//PILOT2D_API(void) GetImageSize(void* pHandle, int& nWidth, int& nHeight);
///
/// 获取图像大小
///
/// 二维显示控件的句柄
/// 宽度
/// 高度
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "GetImageSize")]
public static extern void GetImageSize(IntPtr pHandle, ref int nWidth, ref int nHeight);
//PILOT2D_API(void) SetImageRotated(void* pHandle, int nIsRotated);
///
/// 设置图像旋转九十度
///
/// 二维显示控件的句柄
/// 为1时旋显示,为0时正常显示
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "SetImageRotated")]
public static extern void SetImageRotated(IntPtr pHandle, int nIsRotated);
//PILOT2D_API(void) ResizePilot2D(void* pHandle, int nWidth, int nHeight);
///
/// 调整窗口大小,在主程序窗口大小发生变化时调用
///
/// 二维显示控件的句柄
/// 宽度
/// 高度
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "ResizePilot2D")]
public static extern void ResizePilot2D(IntPtr pHandle, int nWidth, int nHeight);
//PILOT2D_API(void) RefreshPilot2D(void* pHandle);
///
/// 刷新显示窗口,此控件在传入数据时并不更新显示,直到调用此函数。
///
/// 二维显示控件的句柄
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "ResizePilot2D")]
public static extern void ResizePilot2D(IntPtr pHandle);
//PILOT2D_API(void) RefreshPilot2D(void* pHandle);
///
/// 刷新显示窗口,此控件在传入数据时并不更新显示,直到调用此函数。
///
/// 二维显示控件的句柄
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "RefreshPilot2D")]
public static extern void RefreshPilot2D(IntPtr pHandle);
//PILOT2D_API(int) AddIntensityData(void* pHandle, LBPointZA* points, int nCount);
///
/// 添加强度数据
///
/// 二维显示控件的句柄
/// 兰宝线扫描传感器输出的数据指针, LBPointZA* points
/// 指定上述数据的指针里的点的数量
/// 函数调用成功返回1,失败返回-1
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "AddIntensityData")]
public static extern int AddIntensityData(IntPtr pHandle, IntPtr points, int nCount);
//PILOT2D_API(int) AddDepthData(void* pHandle, LBPointZA* points, int nCount, short nMinDepth, short nMaxDepth);
///
/// 添加深度数据,此函数具有颜色渲染功能
///
/// 二维显示控件的句柄
/// 兰宝线扫描传感器输出的数据指针, LBPointZA* points
/// 指定上述数据的指针里的点的数量
/// 指定深度中的最小值,用于颜色渲染,建议值最小值-1
/// 指定深度中的最大值,用于颜色渲染,建议值最大值+1
/// 函数调用成功返回1,失败返回-1
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "AddDepthData")]
public static extern int AddDepthData(IntPtr pHandle, IntPtr points, int nCount, short nMinDepth, short nMaxDepth);
//PILOT2D_API(int) AddIntensityArray(void* pHandle, unsigned char* points, int nCount);
///
/// 添加强度数据(提供另一种数据输入格式,不常用)
///
/// 二维显示控件的句柄
/// 强度数据为8位无符号字符型数据指针, unsigned char* points
/// 指定上述数据的指针里的点的数量
/// 函数调用成功返回1,失败返回-1
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "AddIntensityArray")]
public static extern int AddIntensityArray(IntPtr pHandle, IntPtr points, int nCount);
//PILOT2D_API(int) AddDepthArray(void* pHandle, float* points, int nCount, short nMinDepth, short nMaxDepth);
///
/// 添加深度数据(提供另一种数据输入格式,不常用)
///
/// 二维显示控件的句柄
///
/// 强度数据为浮点型数据指针, float* points
/// 指定上述数据的指针里的点的数量
/// 指定深度中的最小值,用于颜色渲染,建议值最小值-1
/// 指定深度中的最大值,用于颜色渲染,建议值最大值+1
/// 函数调用成功返回1,失败返回-1
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "AddDepthArray")]
public static extern int AddDepthArray(IntPtr pHandle, IntPtr points, int nCount, short nMinDepth, short nMaxDepth);
//PILOT2D_API(int) AddRawImagePoints(void* pHandle, LBPointBGRA* points, int nWidth, int nHeight);
///
/// 添加原始图像数据
///
/// 二维显示控件的句柄
/// 原始图像数据指针, LBPointBGRA* points
/// 原始图像的宽度
/// 原始图像的高度
/// 函数调用成功返回1,失败返回-1
///
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "AddRawImagePoints")]
public static extern int AddRawImagePoints(IntPtr pHandle, IntPtr points, int nCount, short nMinDepth, short nMaxDepth);
//PILOT2D_API(void) SetImageData(void* pHandle, LBPointBGRA* points, int nWidth, int nHeight);
///
/// 设置图像数据
///
/// 二维显示控件的句柄
/// 图像数据指针
/// 图像的宽度
/// 图像的高度
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "SetImageData")]
public static extern void SetImageData(IntPtr pHandle, IntPtr points, int nWidth, int nHeight);
//PILOT2D_API(void) GetImageData(void* pHandle, LBPointBGRA* points, int nWidth, int nHeight);
///
/// 获取图像数据
///
/// 二维显示控件的句柄
/// 图像数据指针, LBPointBGRA* points
/// 图像的宽度
/// 图像的高度
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "GetImageData")]
public static extern void GetImageData(IntPtr pHandle, IntPtr points, int nWidth, int nHeight);
//PILOT2D_API(int) AddBarycentreDataZA(void* pHandle, LBPointZA* points, int nCount, float fMinDistance, float fMaxDistance, float fStdDistance);
///
/// 添加质心数据
///
/// 二维显示控件的句柄
/// 兰宝线扫描传感器输出的数据指针
/// 指定上述数据的指针里的点的数量
/// 兰宝线扫描传感器检测的最小距离(从说明书获得,取值225.0)
/// 兰宝线扫描传感器检测的最大距离(从说明书获得,取值473.0)
/// 兰宝线扫描传感器检测的标准距离(从说明书获得,取值325.0)
/// 函数调用成功返回1,失败返回-1
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "AddBarycentreDataZA")]
public static extern int AddBarycentreDataZA(IntPtr pHandle, IntPtr points, int nCount, float fMinDistance, float fMaxDistance, float fStdDistance);
//PILOT2D_API(int) AddBarycentreArray(void* pHandle, float* points, int nCount);
///
/// 添加质心数据
///
/// 二维显示控件的句柄
/// 质心数据为浮点型数据指针, float* points
/// 指定上述数据的指针里的点的数量
/// 函数调用成功返回1,失败返回-1
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "AddBarycentreArray")]
public static extern int AddBarycentreArray(IntPtr pHandle, IntPtr points, int nCount);
//PILOT2D_API(void) ClearBarycentreArray(void* pHandle);
///
/// 清除质心数据
///
/// 二维显示控件的句柄
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "ClearBarycentreArray")]
public static extern void ClearBarycentreArray(IntPtr pHandle);
//PILOT2D_API(void) SetBarycentreColor(void* pHandle, int r, int g, int b);
///
/// 设置质心颜色
///
/// 二维显示控件的句柄
/// 红色分量,八位无符号字符型数值
/// 绿色分量,八位无符号字符型数值
/// 蓝色分量,八位无符号字符型数值
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "SetBarycentreColor")]
public static extern void SetBarycentreColor(IntPtr pHandle, int r, int g, int b);
//PILOT2D_API(void) ClearAllPoints(void* pHandle);
///
/// 清除数据,在显示新的图象前调用
///
/// 二维显示控件的句柄
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "ClearAllPoints")]
public static extern void ClearAllPoints(IntPtr pHandle);
//PILOT2D_API(int) LoadPicture(void* pHandle, char* szFileName);
///
/// 加载图像数据
///
/// 二维显示控件的句柄
/// 文件名,GB2312编码字符串, char* szFileName
/// 函数调用成功返回1,失败返回-1
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "LoadPicture")]
public static extern int LoadPicture(IntPtr pHandle, byte[] szFileName);
//PILOT2D_API(int) SavePicture(void* pHandle, char* szFileName);
///
/// 保存图像数据
///
/// 二维显示控件的句柄
/// 文件名,GB2312编码字符串, char* szFileName
/// 函数调用成功返回1,失败返回-1
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "SavePicture")]
public static extern int SavePicture(IntPtr pHandle, byte[] szFileName);
//PILOT2D_API(void) BeginDrawTool(void* pHandle);
///
/// 开始绘制兴趣区状态
///
/// 二维显示控件的句柄
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "BeginDrawTool")]
public static extern void BeginDrawTool(IntPtr pHandle);
//PILOT2D_API(void) EndDrawTool(void* pHandle);
///
/// 结束绘制兴趣区状态
///
/// 二维显示控件的句柄
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "EndDrawTool")]
public static extern void EndDrawTool(IntPtr pHandle);
//PILOT2D_API(void) SetDrawRect(void* pHandle);
///
/// 设为绘制矩形兴趣区状态
///
/// 二维显示控件的句柄
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "SetDrawRect")]
public static extern void SetDrawRect(IntPtr pHandle);
//PILOT2D_API(void) SetDrawPolygon(void* pHandle);
///
/// 设为绘制多边形兴趣区状态
///
/// 二维显示控件的句柄
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "SetDrawPolygon")]
public static extern void SetDrawPolygon(IntPtr pHandle);
//PILOT2D_API(void) SetDrawCircle(void* pHandle);
///
/// 设为绘制圆形兴趣区状态
///
/// 二维显示控件的句柄
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "SetDrawCircle")]
public static extern void SetDrawCircle(IntPtr pHandle);
//PILOT2D_API(void) SetDrawAnnulus(void* pHandle);
///
/// 设为绘制环形兴趣区状态
///
/// 二维显示控件的句柄
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "SetDrawAnnulus")]
public static extern void SetDrawAnnulus(IntPtr pHandle);
//PILOT2D_API(void) SetDrawSelection(void* pHandle);
///
/// 设为选择兴趣区状态
///
/// 二维显示控件的句柄
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "SetDrawSelection")]
public static extern void SetDrawSelection(IntPtr pHandle);
//PILOT2D_API(void) SetRectColor(void* pHandle, int r, int g, int b);
///
/// 设置绘制矩形兴趣区颜色
///
/// 二维显示控件的句柄
/// 红色分量,八位无符号字符型数值
/// 绿色分量,八位无符号字符型数值
/// 蓝色分量,八位无符号字符型数值
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "SetRectColor")]
public static extern void SetRectColor(IntPtr pHandle, int r, int g, int b);
//PILOT2D_API(void) AddRect(void* pHandle, int left, int top, int right, int bottom);
///
/// 添加矩形兴趣区
///
/// 二维显示控件的句柄
/// 待添加的矩形兴趣区左上角的x坐标
/// 待添加的矩形兴趣区左上角的y坐标
/// 待添加的矩形兴趣区右下角的x坐标
/// 待添加的矩形兴趣区右下角的y坐标
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "AddRect")]
public static extern void AddRect(IntPtr pHandle, int left, int top, int right, int bottom);
//PILOT2D_API(void) AddCircle(void* pHandle, int x, int y, int radius);
///
/// 添加圆形兴趣区
///
/// 二维显示控件的句柄
/// 待添加的圆形兴趣区中心的x坐标
/// 待添加的圆形兴趣区中心的y坐标
/// 待添加的圆形兴趣区的x半径
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "AddCircle")]
public static extern void AddCircle(IntPtr pHandle, int x, int y, int radius);
//PILOT2D_API(void) AddAnnulus(void* pHandle, int x, int y, int radius, float fRadiusRatio);
///
/// 添加环形兴趣区
///
/// 二维显示控件的句柄
/// 待添加的环形兴趣区中心的x坐标
/// 待添加的环形兴趣区中心的y坐标
/// 待添加的环形兴趣区的x半径
/// 待添加的环形兴趣区内外半径比
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "AddAnnulus")]
public static extern void AddAnnulus(IntPtr pHandle, int x, int y, int radius, float fRadiusRatio);
//PILOT2D_API(void) AddPolygon(void* pHandle, void* points, int nCount);
///
/// 添加多边形兴趣区
///
/// 二维显示控件的句柄
/// 待添加的多边形兴趣区的顶点坐标的指针
/// 待添加的多边形兴趣区的顶点坐标的数量
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "AddPolygon")]
public static extern void AddPolygon(IntPtr pHandle, IntPtr points, int nCount);
//PILOT2D_API(void) DeleteRect(void* pHandle);
///
/// 删除矩形兴趣区(删除前要选中)
///
/// 二维显示控件的句柄
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "DeleteRect")]
public static extern void DeleteRect(IntPtr pHandle);
//PILOT2D_API(void) DeleteROI(void* pHandle);
///
/// 删除兴趣区对象(删除前要选中)
///
/// 二维显示控件的句柄
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "DeleteROI")]
public static extern void DeleteROI(IntPtr pHandle);
//PILOT2D_API(void) RegisterShowRectInfoCallback(void* pHandle, ShowRectInfo callback);
///
/// 注册画兴趣区时显示矩形参数的回调函数
///
/// 二维显示控件的句柄
/// 回调函数的指针
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "RegisterShowRectInfoCallback")]
public static extern void RegisterShowRectInfoCallback(IntPtr pHandle, ShowRectInfo callback);
//PILOT2D_API(void) RegisterShowInfoCallback(void* pHandle, ShowInfo callback);
///
/// 注册显示调试信息的回调函数
///
/// 二维显示控件的句柄
/// 回调函数的指针
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "RegisterShowInfoCallback")]
public static extern void RegisterShowInfoCallback(IntPtr pHandle, ShowInfo callback);
//PILOT2D_API(void) RegisterShowObjectInfoCallback(void* pHandle, ShowObjectInfo callback);
///
/// 注册画兴趣区时显示对象参数的回调函数
///
/// 二维显示控件的句柄
/// 回调函数的指针
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "RegisterShowObjectInfoCallback")]
public static extern void RegisterShowObjectInfoCallback(IntPtr pHandle, ShowInfo callback);
#region 图像处理相关操作
//PILOT2D_API(BITMAPINFO) GetImageBITMAPINFO(void* pHandle);
///
/// 获取图像的BITMAPINFO结构体
///
/// 二维显示控件的句柄
/// 返回BITMAPINFO结构体
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "GetImageBITMAPINFO")]
public static extern BITMAPINFO GetImageBITMAPINFO(IntPtr pHandle);
//PILOT2D_API GetImageBufferPtr(void* pHandle);
///
/// 获取图像数据的指针
///
/// 二维显示控件的句柄
/// 返回图像数据的指针,(LBPointBGRA*)
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "GetImageBufferPtr")]
public static extern IntPtr GetImageBufferPtr(IntPtr pHandle);
//PILOT2D_API(LBPointBGRA*) RotateImage(void* pHandle, int& destWidth, int& destHeight, double angle, int keepImageSize = 0);
///
/// 图像旋转操作
///
/// 二维显示控件的句柄
/// 用于回传旋转后图像的宽度
/// 用于回传旋转后图像的高度
/// 旋转角度
/// 是否保持图像尺寸
/// 返回操作后图像数据的指针,(LBPointBGRA*)
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "RotateImage")]
public static extern IntPtr RotateImage(IntPtr pHandle, ref int destWidth, ref int destHeight, double angle, int keepImageSize = 0);
//PILOT2D_API(LBPointBGRA*) TranslateImage(void* pHandle, int& destWidth, int& destHeight, int dx, int dy, int keepImageSize = 0);
///
/// 图像平移操作
///
/// 二维显示控件的句柄
/// 用于回传平移后图像的宽度
/// 用于回传平移后图像的高度
/// 平移操作的x增量
/// 平移操作的y增量
/// 是否保持图像尺寸
/// 返回操作后图像数据的指针,(LBPointBGRA*)
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "RotateImage")]
public static extern IntPtr RotateImage(IntPtr pHandle, ref int destWidth, ref int destHeight, int dx, int dy, int keepImageSize = 0);
//PILOT2D_API(LBPointBGRA*) TransformImage(void* pHandle, int& destWidth, int& destHeight, int dx, int dy, double angle, int keepImageSize = 0);
///
/// 图像旋转平移操作
///
/// 二维显示控件的句柄
/// 用于回传旋转平移后图像的宽度
/// 用于回传旋转平移后图像的高度
/// 平移操作的x增量
/// 平移操作的y增量
/// 旋转角度的增量
/// 是否保持图像尺寸
/// 返回操作后图像数据的指针,(LBPointBGRA*)
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "TransformImage")]
public static extern IntPtr TransformImage(IntPtr pHandle, ref int destWidth, ref int destHeight, int dx, int dy, double angle, int keepImageSize = 0);
//PILOT2D_API(LBPointBGRA*) MirrorImage(void* pHandle, int& destWidth, int& destHeight, int hMiiror, int vMirror);
///
/// 图像镜像操作
///
/// 二维显示控件的句柄
/// 用于回传旋转平移后图像的宽度
/// 用于回传旋转平移后图像的高度
/// 为1时,水平镜像,为0时水平不镜像
/// 为1时,垂直镜像,为0时垂直不镜像
/// 返回操作后图像数据的指针
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "MirrorImage")]
public static extern IntPtr MirrorImage(IntPtr pHandle, ref int destWidth, ref int destHeight, int hMiiror, int vMirror);
//PILOT2D_API(void) GetTransformParameter(void* pHandle, float& fAngle, int& xOffset, int& yOffset, int& hMirror, int& vMirror, int& KeepImageSize);
///
/// 获取已执行过的转换参数
///
/// 相机接口句柄
/// 回传旋转角度
/// 回传x向平移量
/// 回传y向平移量
/// 回传水平镜像标志,为1时水平镜像,为0时不变
/// 回传垂直镜像标志,为1时垂直镜像,为0时不变
/// 回传保持图像大小标志
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "GetTransformParameter")]
public static extern void GetTransformParameter(IntPtr pHandle, ref float fAngle, ref int xOffset, ref int yOffset, ref int hMirror, ref int vMirror, ref int KeepImageSize);
//PILOT2D_API(void) ShowRoiHeight(void* pHandle, float* fRoiHeight, int nRow, int nCol);
///
/// 显示ROI对应的高度值
///
/// 相机接口句柄
/// 兴趣区高度数组,fRoiHeight为NULL,或者nRow和nCol中有一个为0,就不显示, float* fRoiHeight
/// 兴趣区行数
/// 兴趣区列数
[DllImport("Pilot2D.dll", CallingConvention = CallingConvention.StdCall, EntryPoint = "ShowRoiHeight")]
public static extern void ShowRoiHeight(IntPtr pHandle, IntPtr fRoiHeight, int nRow, int nCol);
#endregion
}
}