From: DUC ANH HOANG Date: Thu, 15 Sep 2022 12:37:13 +0000 (+0200) Subject: [EDF-26044]: enable path tracer material loading on PARAVIS_GUI X-Git-Tag: V9_10_0a1~10 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=refs%2Fheads%2Fduc%2Fload_material_ospray;p=modules%2Fparavis.git [EDF-26044]: enable path tracer material loading on PARAVIS_GUI --- diff --git a/src/PVGUI/PVGUI_Module.h b/src/PVGUI/PVGUI_Module.h index 4715c0a9..1182a5b5 100644 --- a/src/PVGUI/PVGUI_Module.h +++ b/src/PVGUI/PVGUI_Module.h @@ -58,6 +58,8 @@ class PVGUI_Module: public LightApp_Module SaveAnimationId, SaveGeometryId, //- + LoadMaterialsId, + //- ConnectId, DisconnectId, //----------- diff --git a/src/PVGUI/PVGUI_Module_actions.cxx b/src/PVGUI/PVGUI_Module_actions.cxx index 9b328237..35d3fd0b 100644 --- a/src/PVGUI/PVGUI_Module_actions.cxx +++ b/src/PVGUI/PVGUI_Module_actions.cxx @@ -49,6 +49,7 @@ #include #include #include +#include #include #include #include @@ -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 ); diff --git a/src/PVGUI/resources/PARAVIS_msg_en.ts b/src/PVGUI/resources/PARAVIS_msg_en.ts index 2a71722c..3c7771d9 100644 --- a/src/PVGUI/resources/PARAVIS_msg_en.ts +++ b/src/PVGUI/resources/PARAVIS_msg_en.ts @@ -357,6 +357,18 @@ STB_SAVE_GEOMETRY Save Geometry + + TOP_LOAD_MATERIAL + Load Path Tracer Materials... + + + MEN_LOAD_MATERIAL + Load Path Tracer Materials... + + + STB_LOAD_MATERIAL + Load Path Tracer Materials... + TOP_CONNECT Connect diff --git a/src/PVGUI/resources/PARAVIS_msg_fr.ts b/src/PVGUI/resources/PARAVIS_msg_fr.ts index 44fcca35..8501cb37 100644 --- a/src/PVGUI/resources/PARAVIS_msg_fr.ts +++ b/src/PVGUI/resources/PARAVIS_msg_fr.ts @@ -361,6 +361,18 @@ STB_SAVE_GEOMETRY Enregistrer la Géométrie + + TOP_LOAD_MATERIAL + Charger le ficher de matériau d'Ospray... + + + MEN_LOAD_MATERIAL + Charger le ficher de matériau d'Ospray... + + + STB_LOAD_MATERIAL + Charger le ficher de matériau d'Ospray... + TOP_CONNECT Connecter