Version: 6.3.1

src/VISUGUI/VisuGUI_PrimitiveBox.h

Go to the documentation of this file.
00001 // Copyright (C) 2007-2011  CEA/DEN, EDF R&D, OPEN CASCADE
00002 //
00003 // This library is free software; you can redistribute it and/or
00004 // modify it under the terms of the GNU Lesser General Public
00005 // License as published by the Free Software Foundation; either
00006 // version 2.1 of the License.
00007 //
00008 // This library is distributed in the hope that it will be useful,
00009 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00010 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00011 // Lesser General Public License for more details.
00012 //
00013 // You should have received a copy of the GNU Lesser General Public
00014 // License along with this library; if not, write to the Free Software
00015 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
00016 //
00017 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
00018 //
00019 
00020 //  VISU VISUGUI : GUI of VISU component
00021 //  File   : VisuGUI_PrimitiveBox.h
00022 //  Author : Oleg UVAROV
00023 //  Module : VISU
00024 //
00025 #ifndef VISUGUI_PRIMITIVEBOX_H
00026 #define VISUGUI_PRIMITIVEBOX_H
00027 
00028 #include <QGroupBox>
00029 
00030 class QLabel;
00031 class QLineEdit;
00032 class QPushButton;
00033 class QRadioButton;
00034 
00035 class SalomeApp_DoubleSpinBox;
00036 class SalomeApp_IntSpinBox;
00037 
00038 class VisuGUI_PrimitiveBox : public QGroupBox
00039 {
00040   Q_OBJECT
00041 
00042 public:
00043   VisuGUI_PrimitiveBox( QWidget* );
00044   ~VisuGUI_PrimitiveBox() {}
00045 
00046 public:
00047   int                      getPrimitiveType() const { return myPrimitiveType; }
00048   void                     setPrimitiveType( int );
00049 
00050   float                    getClamp() const;
00051   void                     setClamp( float );
00052   void                     setClampMaximum( float );
00053 
00054   QString                  getMainTexture() const { return myMainTexture; }
00055   void                     setMainTexture( const QString& );
00056 
00057   QString                  getAlphaTexture() const { return myAlphaTexture; }
00058   void                     setAlphaTexture( const QString& );
00059 
00060   float                    getAlphaThreshold() const;
00061   void                     setAlphaThreshold( float );
00062 
00063   int                      getResolution() const;
00064   void                     setResolution( int );
00065 
00066   int                      getFaceNumber() const;
00067   void                     setFaceNumber( int );
00068 
00069   int                      getFaceLimit() const;
00070   void                     setFaceLimit( int );
00071 
00072 protected slots:
00073   void                     onTogglePointSprite();
00074   void                     onToggleOpenGLPoint();
00075   void                     onToggleGeomSphere();
00076 
00077   void                     onBrowseMainTexture();
00078   void                     onBrowseAlphaTexture();
00079 
00080   void                     onResolutionChanged( int );
00081 
00082 private:
00083   int                      myPrimitiveType;
00084 
00085   QRadioButton*            myPointSpriteButton;
00086   QRadioButton*            myOpenGLPointButton;
00087   QRadioButton*            myGeomSphereButton;
00088 
00089   QString                  myMainTexture;
00090   QString                  myAlphaTexture;
00091 
00092   QLabel*                  myClampLabel;
00093   SalomeApp_DoubleSpinBox* myClampSpinBox;
00094 
00095   QLabel*                  myMainTextureLabel;
00096   QLineEdit*               myMainTextureLineEdit;
00097   QPushButton*             myMainTextureButton;
00098 
00099   QLabel*                  myAlphaTextureLabel;
00100   QLineEdit*               myAlphaTextureLineEdit;
00101   QPushButton*             myAlphaTextureButton;
00102 
00103   QLabel*                  myAlphaThresholdLabel;
00104   SalomeApp_DoubleSpinBox* myAlphaThresholdSpinBox;
00105 
00106   QLabel*                  myResolutionLabel;
00107   SalomeApp_IntSpinBox*    myResolutionSpinBox;
00108 
00109   QLabel*                  myFaceNumberLabel;
00110   QLineEdit*               myFaceNumberLineEdit;
00111 
00112   QLabel*                  myFaceLimitLabel;
00113   SalomeApp_IntSpinBox*    myFaceLimitSpinBox;
00114 };
00115 
00116 
00117 
00118 #endif
Copyright © 2007-2011 CEA/DEN, EDF R&D, OPEN CASCADE
Copyright © 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS