Salome HOME
updated copyright message
[modules/shaper.git] / src / PartSet / PartSet_Module.cpp
index 76bafe5f6b1cc2c22eadd5b143e0120c2a7e6684..c4dc84c15c976b86d033e98574fd530843e7a47e 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2014-2022  CEA/DEN, EDF R&D
+// Copyright (C) 2014-2023  CEA, EDF
 //
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 
 #include <SUIT_ResourceMgr.h>
 
+#include <Basics_OCCTVersion.hxx>
+
 #define FEATURE_ITEM_COLOR "0,0,225"
 
 
@@ -1474,7 +1476,11 @@ void PartSet_Module::setTexture(const AISObjectPtr& thePrs,
 
       //aPixmap = OCCViewer_Utilities::imageToPixmap( px.toImage());
       Handle(Image_PixMap) aPixmap = new Image_PixMap();
+#if OCC_VERSION_LARGE < 0x07070000
       aPixmap->InitTrash(Image_PixMap::ImgBGRA, aWidth, aHeight);
+#else
+      aPixmap->InitTrash(Image_Format_BGRA, aWidth, aHeight);
+#endif
       std::list<unsigned char>::iterator aByteIter = aByteList.begin();
       for (int aLine = 0; aLine < aHeight; ++aLine) {
         // convert pixels from ARGB to renderer-compatible RGBA