|
@@ -254,7 +254,7 @@ namespace OTSSysMgrApp
|
|
|
bitmap = CImageHandler.ToGrayBitmap(ImageByte, width, height);
|
|
|
pbImage.Image = bitmap;
|
|
|
btnSaveImage.Enabled = true;
|
|
|
- log.Info("Image capture success!\nImage resolution:" + tbRWidth.Text + "X" + tbRHeight.Text + ";");
|
|
|
+ log.Info("Image capture success!\nImage resolution:" + bitmap.Width + "X" + bitmap.Height + ";");
|
|
|
}
|
|
|
else
|
|
|
{
|
|
@@ -319,7 +319,11 @@ namespace OTSSysMgrApp
|
|
|
//采集时间
|
|
|
a_Milliseconds = Convert.ToUInt32(tbCollectionTime.Text);
|
|
|
//采集XRay数据
|
|
|
- m_EDSHardwareMgr.CollectSpectrum(a_Milliseconds, ref a_XrayData);
|
|
|
+ bool result=m_EDSHardwareMgr.CollectSpectrum(a_Milliseconds, ref a_XrayData);
|
|
|
+ if(!result)
|
|
|
+ {
|
|
|
+ log.Error("m_EDSHardwareMgr.CollectSpectrum failed!");
|
|
|
+ }
|
|
|
int[] XData = new int[2000];
|
|
|
uint nXrayCount = 0;
|
|
|
for (int i = 1; i <= 2000; i++)
|
|
@@ -897,7 +901,11 @@ namespace OTSSysMgrApp
|
|
|
}
|
|
|
|
|
|
m_EDSHardwareMgr.SetResolution(int.Parse(tbRWidth.Text), int.Parse(tbRHeight.Text));
|
|
|
- m_EDSHardwareMgr.GetXRayByPoints(cOTSParticleClrs, a_Milliseconds, false);
|
|
|
+ bool result=m_EDSHardwareMgr.GetXRayByPoints(cOTSParticleClrs, a_Milliseconds, false);
|
|
|
+ if(!result)
|
|
|
+ {
|
|
|
+ log.Error("m_EDSHardwareMgr.GetXRayByPoints failed!");
|
|
|
+ }
|
|
|
|
|
|
int[] XData = new int[2000];
|
|
|
uint nXrayCount = 0;
|
|
@@ -979,6 +987,10 @@ namespace OTSSysMgrApp
|
|
|
fea.SetSegmentsList(segs,false);
|
|
|
string ele = "";
|
|
|
bool isTrue = m_EDSHardwareMgr.GetXRayBySingleFeature(a_Milliseconds, fea, ref a_XrayData,ref ele, false);
|
|
|
+ if (!isTrue)
|
|
|
+ {
|
|
|
+ log.Error("GetAreaRay() failed!");
|
|
|
+ }
|
|
|
int[] XData = new int[2000];
|
|
|
uint nXrayCount = 0;
|
|
|
for (int i = 1; i <= 2000; i++)
|