]> SALOME platform Git repositories - modules/geom.git/commitdiff
Salome HOME
Debug for material colors with OCCT-7.4.0
authorrnv <rnv@opencascade.com>
Tue, 25 Feb 2020 15:24:52 +0000 (18:24 +0300)
committerrnv <rnv@opencascade.com>
Tue, 25 Feb 2020 15:24:52 +0000 (18:24 +0300)
src/Material/Material_Model.cxx

index 5ab3d6e35f7ad8903a90d0af665abfc03d3faced..869e40dfbd52e5a55ae8167ca4034d7914f96c2c 100644 (file)
@@ -401,6 +401,11 @@ QColor Material_Model::color( ReflectionType type ) const
   QColor value;
   if ( type >= 0 && type < 4 )
     value = myReflection[ type ].color;
+#if OCC_VERSION_LARGE >= 0x07040000
+  // Compatibility with previous OCCT versions, set for non-physical materials always white color
+  if ( !isPhysical() )
+    value = Qt::white;
+#endif
   return value;
 }