Salome HOME
Copyright update 2022
[modules/gui.git] / src / OCCViewer / OCCViewer_EnvTextureDlg.cxx
index 958cb4870e92e04d46ca3716fe8aad61b9737d0d..5c8c7c0f67e0fa7242b5ba365a339e089420a03e 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2015-2016  CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2015-2022  CEA/DEN, EDF R&D, OPEN CASCADE
 //
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
@@ -169,7 +169,7 @@ void OCCViewer_EnvTextureDlg::onEnvTexture( bool theIsChecked )
     onTextureChanged();
   else {
     Handle(Graphic3d_TextureEnv) aTexture;
-    setEnvTexture( aTexture, V3d_TEX_ALL );
+    setEnvTexture( aTexture );
   }
 }
 
@@ -189,14 +189,13 @@ void OCCViewer_EnvTextureDlg::onTextureChanged()
   }
   else {
     myEnvTextureName->setText("");
-    Graphic3d_NameOfTextureEnv aStandardTexture;
     QList<Graphic3d_NameOfTextureEnv> aTextures;
     aTextures << Graphic3d_NOT_ENV_CLOUDS << Graphic3d_NOT_ENV_CV   << Graphic3d_NOT_ENV_MEDIT
                  << Graphic3d_NOT_ENV_PEARL  << Graphic3d_NOT_ENV_SKY1 << Graphic3d_NOT_ENV_SKY2
                  << Graphic3d_NOT_ENV_LINES  << Graphic3d_NOT_ENV_ROAD;
     aTexture = new Graphic3d_TextureEnv( aTextures.at( myEnvTextureId->currentIndex() ) );
   }
-  setEnvTexture( aTexture, V3d_TEX_ENVIRONMENT );
+  setEnvTexture( aTexture );
 }
 
 /*!
@@ -218,19 +217,18 @@ void OCCViewer_EnvTextureDlg::ClickOnHelp()
 {
   SUIT_Application* app = SUIT_Session::session()->activeApplication();
   if ( app )
-    app->onHelpContextModule( "GUI", "occ_3d_viewer_page.html", "env_texture" );
+    app->onHelpContextModule( "GUI", "occ_3d_viewer.html", "env-texture" );
 }
 
 /*!
   Sets current texture environment for all view in the viewer
 */
-void OCCViewer_EnvTextureDlg::setEnvTexture( Handle(Graphic3d_TextureEnv) theTexture, V3d_TypeOfSurfaceDetail theMode )
+void OCCViewer_EnvTextureDlg::setEnvTexture( Handle(Graphic3d_TextureEnv) theTexture)
 {
   for ( int i = OCCViewer_ViewFrame::BOTTOM_RIGHT; i <= OCCViewer_ViewFrame::TOP_RIGHT; i++ ) {
     if ( OCCViewer_ViewWindow* aViewWindow = myViewFrame->getView(i) ) {
       Handle(V3d_View) aView = aViewWindow->getViewPort()->getView();
       aView->SetTextureEnv( theTexture );
-      aView->SetSurfaceDetail( theMode );
       aView->Redraw();
     }
   }