]> SALOME platform Git repositories - modules/paravis.git/commitdiff
Salome HOME
[EDF-26044]: enable path tracer material loading on PARAVIS_GUI duc/load_material_ospray
authorDUC ANH HOANG <duc-anh-externe.hoang@edf.fr>
Thu, 15 Sep 2022 12:37:13 +0000 (14:37 +0200)
committerDUC ANH HOANG <duc-anh-externe.hoang@edf.fr>
Mon, 19 Sep 2022 08:42:16 +0000 (10:42 +0200)
src/PVGUI/PVGUI_Module.h
src/PVGUI/PVGUI_Module_actions.cxx
src/PVGUI/resources/PARAVIS_msg_en.ts
src/PVGUI/resources/PARAVIS_msg_fr.ts

index 4715c0a9e1b1cb61782a834fd6a05493c0cbd20c..1182a5b50b8fc822ef64546a2f0b623357feeea4 100644 (file)
@@ -58,6 +58,8 @@ class PVGUI_Module: public LightApp_Module
     SaveAnimationId,
     SaveGeometryId,
     //-
+    LoadMaterialsId,
+    //-
     ConnectId,
     DisconnectId,
     //-----------
index 9b328237c8a347219df8abc4f9d654bf5d33adc2..35d3fd0b815e3bb377c7c0272c974a29f4fe5f89 100644 (file)
@@ -49,6 +49,7 @@
 #include <pqExportReaction.h>
 #include <pqSaveAnimationReaction.h>
 #include <pqSaveAnimationGeometryReaction.h>
+#include <pqLoadMaterialsReaction.h>
 #include <pqServerConnectReaction.h>
 #include <pqServerDisconnectReaction.h>
 #include <pqCameraUndoRedoReaction.h>
@@ -152,6 +153,14 @@ void PVGUI_Module::pvCreateActions()
   registerAction(SaveGeometryId, anAction);
   new pqSaveAnimationGeometryReaction(anAction);
 
+  // Load Path Tracer Materials
+  aPixmap = resMgr->loadPixmap( "ParaView", tr("ICON_LOAD_MATERIAL"), false );
+  anAction = new QAction(QIcon(aPixmap), tr("MEN_LOAD_MATERIAL"), this);
+  anAction->setToolTip(tr("TOP_LOAD_MATERIAL"));
+  anAction->setStatusTip(tr("STB_LOAD_MATERIAL"));
+  registerAction(LoadMaterialsId, anAction);
+  new pqLoadMaterialsReaction(anAction);
+
   // Connect
   aPixmap = resMgr->loadPixmap( "ParaView", tr("ICON_CONNECT"), false );
   anAction = new QAction(QIcon(aPixmap), tr("MEN_CONNECT"), this);
@@ -429,10 +438,13 @@ void PVGUI_Module::pvCreateMenus()
   createMenu( SaveGeometryId, aPVMnu, 35 );
   createMenu( separator(), aPVMnu, -1, 35 );
 
-  createMenu( ConnectId, aPVMnu, 45 );
-  createMenu( DisconnectId, aPVMnu, 45 );
+  createMenu( LoadMaterialsId, aPVMnu, 45);
   createMenu( separator(), aPVMnu, -1, 45 );
 
+  createMenu( ConnectId, aPVMnu, 55 );
+  createMenu( DisconnectId, aPVMnu, 55 );
+  createMenu( separator(), aPVMnu, -1, 55 );
+
   // --- Menu "Edit"
   aPVMnu = createMenu( tr( "MEN_DESK_EDIT" ), -1, -1 );
 
index 2a71722c99d167b76a9c017824a93d4e016decd8..3c7771d97067ca7a01b499e897ac0a1301699884 100644 (file)
         <source>STB_SAVE_GEOMETRY</source>
         <translation>Save Geometry</translation>
     </message>
+    <message>
+        <source>TOP_LOAD_MATERIAL</source>
+        <translation>Load Path Tracer Materials...</translation>
+    </message>
+    <message>
+        <source>MEN_LOAD_MATERIAL</source>
+        <translation>Load Path Tracer Materials...</translation>
+    </message>
+    <message>
+        <source>STB_LOAD_MATERIAL</source>
+        <translation>Load Path Tracer Materials...</translation>
+    </message>
     <message>
         <source>TOP_CONNECT</source>
         <translation>Connect</translation>
index 44fcca35e57d27751a396ae6e94ec5476a98b78a..8501cb3788398163aca4e5d877ccf73c84356847 100644 (file)
         <source>STB_SAVE_GEOMETRY</source>
         <translation>Enregistrer la Géométrie</translation>
     </message>
+    <message>
+        <source>TOP_LOAD_MATERIAL</source>
+        <translation>Charger le ficher de matériau d&apos;Ospray...</translation>
+    </message>
+    <message>
+        <source>MEN_LOAD_MATERIAL</source>
+        <translation>Charger le ficher de matériau d&apos;Ospray...</translation>
+    </message>
+    <message>
+        <source>STB_LOAD_MATERIAL</source>
+        <translation>Charger le ficher de matériau d&apos;Ospray...</translation>
+    </message>
     <message>
         <source>TOP_CONNECT</source>
         <translation>Connecter</translation>