Browse Source

报告国标C++部分,去除无效颗粒

zhangjiaxin 2 years ago
parent
commit
8ad140daee

+ 24 - 7
OTSCPP/OTSRptCalculate/GBCal/GBFieldData.cpp

@@ -316,8 +316,11 @@ namespace OTSGBCalculate
 				double dFeretDiameter = pParticle->GetFeretDiameter();
 				if (dFeretDiameter >= 13)
 				{
-					// DS					
-					listDSParticles.push_back(pParticle);
+					// DS		
+					if (pParticle->GetType() != OTS_PARTICLE_TYPE::INVALID)//here we take all the particles 
+					{
+						listDSParticles.push_back(pParticle);
+					}
 				}
 				else
 				{
@@ -347,7 +350,7 @@ namespace OTSGBCalculate
 					else
 					{
 						// B or D
-						if (pParticle->GetChemicalType() != GB_CHEMICAL_TYPE::INVALID)//here we take all the particles 
+						if (pParticle->GetType() != OTS_PARTICLE_TYPE::INVALID)//here we take all the particles 
 						{
 							GBParticle gbP = GBParticle(pParticle, GB_LEVEL_TYPE::INVALID, GB_WIDTH_TYPE::INVALID);
 							//²»ÄÜÈ·¶¨ÊÇB»òD£¬ÏÈÉèΪINVALID
@@ -359,6 +362,9 @@ namespace OTSGBCalculate
 
 				}
 			}
+
+
+
 		}
 		
 			for (auto pGBParticle : listBAndDParticles)
@@ -510,8 +516,12 @@ namespace OTSGBCalculate
 				double dFeretDiameter = pParticle->GetFeretDiameter();
 				if (dFeretDiameter >= 13)
 				{
-					// DS					
-					listDSParticles.push_back(pParticle);
+					// DS			
+					if (pParticle->GetType() != OTS_PARTICLE_TYPE::INVALID)//here we take all the particles 
+					{
+						listDSParticles.push_back(pParticle);
+					}
+					
 				}
 				else
 				{
@@ -724,7 +734,11 @@ namespace OTSGBCalculate
 				if (dFeretDiameter >= 13)
 				{
 					// DS					
-					listDSParticles.push_back(pParticle);
+					if (pParticle->GetType() != OTS_PARTICLE_TYPE::INVALID)//here we take all the particles 
+					{
+						listDSParticles.push_back(pParticle);
+					}
+					
 				}
 				else
 				{
@@ -905,7 +919,10 @@ namespace OTSGBCalculate
 				if (dFeretDiameter >= 13)
 				{
 					// DS					
-					listDSParticles.push_back(pParticle);
+					if (pParticle->GetType() != OTS_PARTICLE_TYPE::INVALID)//here we take all the particles 
+					{
+						listDSParticles.push_back(pParticle);
+					}
 				}
 				else
 				{

+ 3 - 0
OTSIncAReportApp/OTSIncAReportApp.csproj.user

@@ -3,4 +3,7 @@
   <PropertyGroup>
     <ReferencePath>D:\夹杂物\2.4\OTS2_0\Bin\x64\Release_oxford50\</ReferencePath>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release_oxford50|x64'">
+    <EnableUnmanagedDebugging>true</EnableUnmanagedDebugging>
+  </PropertyGroup>
 </Project>