// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
// File : VisuGUI_CutLinesDlg.cxx
// Author : VSV
// Module : VISU
-//
+
#include "VisuGUI_CutLinesDlg.h"
#include "VISU_ColoredPrs3dFactory.hh"
VisuGUI_ScalarBarBaseDlg::initFromPrsObject(myPrsCopy, theInit);
- myRotXSpn->setValue(myPrsCopy->GetRotateX()*180./PI);
- myRotYSpn->setValue(myPrsCopy->GetRotateY()*180./PI);
+ myRotXSpn->setValue(myPrsCopy->GetRotateX()*180./M_PI);
+ myRotYSpn->setValue(myPrsCopy->GetRotateY()*180./M_PI);
myPosSpn->setValue(myPrsCopy->GetDisplacement());
setOrientation(myPrsCopy->GetOrientationType());
myNbSpn->setValue( (int)myPrsCopy->GetNbLines() );
- myRotXSpn2->setValue(myPrsCopy->GetRotateX2()*180./PI);
- myRotYSpn2->setValue(myPrsCopy->GetRotateY2()*180./PI);
+ myRotXSpn2->setValue(myPrsCopy->GetRotateX2()*180./M_PI);
+ myRotYSpn2->setValue(myPrsCopy->GetRotateY2()*180./M_PI);
myPosSpn2->setValue(myPrsCopy->GetDisplacement2());
setOrientation2(myPrsCopy->GetOrientationType2());
anIsOk &= GetScalarPane()->storeToPrsObject( myPrsCopy );
myPrsCopy->SetOrientation(getOrientaion(),
- myRotXSpn->value()*PI/180.,
- myRotYSpn->value()*PI/180.);
+ myRotXSpn->value()*M_PI/180.,
+ myRotYSpn->value()*M_PI/180.);
myPrsCopy->SetDisplacement(myPosSpn->value());
myPrsCopy->SetNbLines((int)myNbSpn->value());
myPrsCopy->SetOrientation2(getOrientaion(false),
- myRotXSpn2->value()*PI/180.,
- myRotYSpn2->value()*PI/180.);
+ myRotXSpn2->value()*M_PI/180.,
+ myRotYSpn2->value()*M_PI/180.);
myPrsCopy->SetDisplacement2(myPosSpn2->value());
if (!myCBSetDef->isChecked())
return;
myCutLines->SetOrientation(getOrientaion(),
- myRotXSpn->value()*PI/180.,
- myRotYSpn->value()*PI/180.);
+ myRotXSpn->value()*M_PI/180.,
+ myRotYSpn->value()*M_PI/180.);
myCutLines->SetNbLines(aNbPlanes);
myCutLines->SetDisplacement2(myPosSpn2->value());
myCutLines->SetOrientation2(getOrientaion(false),
- myRotXSpn2->value()*PI/180.,
- myRotYSpn2->value()*PI/180.);
+ myRotXSpn2->value()*M_PI/180.,
+ myRotYSpn2->value()*M_PI/180.);
if (aNbRows>0)
for (int i = 0; i < aNbRows; ++i)
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
// VISU VISUGUI : GUI of VISU component
// File : VisuGUI_CutPlanesDlg.cxx
// Author : Laurent CORNABE & Hubert ROLLAND
// Module : VISU
-// $Header$
-//
+
#include "VisuGUI_CutPlanesDlg.h"
#include "VISU_ColoredPrs3dFactory.hh"
void VisuGUI_CutPlanesPane::initFromPrsObject (VISU::CutPlanes_i* thePrs)
{
setNbPlanes(thePrs->GetNbPlanes());
- setRotation(thePrs->GetRotateX()*180./PI, thePrs->GetRotateY()*180./PI);
+ setRotation(thePrs->GetRotateX()*180./M_PI, thePrs->GetRotateY()*180./M_PI);
setPlanePos(thePrs->GetOrientationType());
myPosSpn->setValue(thePrs->GetDisplacement());
InitEntity2VectorialFieldsMap(thePrs);
int VisuGUI_CutPlanesPane::storeToPrsObject (VISU::CutPlanes_i* thePrs)
{
- thePrs->SetOrientation(getOrientaion(), getRotation1()*PI/180., getRotation2()*PI/180.);
+ thePrs->SetOrientation(getOrientaion(), getRotation1()*M_PI/180., getRotation2()*M_PI/180.);
thePrs->SetNbPlanes(getNbPlanes());
thePrs->SetDisplacement(myPosSpn->value());
for (int i = 0; i < getNbPlanes(); ++i) {
int aNbRows = myPosTable->rowCount();
int aNbPlanes = getNbPlanes();
- myCutPlanes->SetOrientation(getOrientaion(),getRotation1()*PI/180.,getRotation2()*PI/180.);
+ myCutPlanes->SetOrientation(getOrientaion(),getRotation1()*M_PI/180.,getRotation2()*M_PI/180.);
myCutPlanes->SetNbPlanes(aNbPlanes);
myCutPlanes->SetDisplacement(myPosSpn->value());
myCutPlanes->SetScale(getScaleFactor());
if (!(bool)myCutPlanes) return;
if (myPreviewCheck->isChecked()) {
if (SVTK_ViewWindow* vf = VISU::GetActiveViewWindow<SVTK_ViewWindow>()) {
- myCutPlanes->SetOrientation(getOrientaion(),getRotation1()*PI/180.,getRotation2()*PI/180.);
+ myCutPlanes->SetOrientation(getOrientaion(),getRotation1()*M_PI/180.,getRotation2()*M_PI/180.);
myCutPlanes->GetPipeLine()->Update();
deletePlanes();
createPlanes();
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
// VISU VISUGUI : GUI of VISU component
// File : VisuGUI_Plot3DDlg.cxx
// Author : Laurent CORNABE & Hubert ROLLAND
// Module : VISU
-// $Header$
-//
+
#include "VisuGUI_Plot3DDlg.h"
#include "VisuGUI.h"
GBOrientation->button(id)->click();
// rotation
- Rot1->setValue(thePrs->GetRotateX() * 180./PI);
- Rot2->setValue(thePrs->GetRotateY() * 180./PI);
+ Rot1->setValue(thePrs->GetRotateX() * 180./M_PI);
+ Rot2->setValue(thePrs->GetRotateY() * 180./M_PI);
// position
RelativeChkB->setChecked(thePrs->IsPositionRelative());
default: ori = VISU::Plot3D::ZX;
}
// rotation
- thePrs->SetOrientation(ori, Rot1->value()*PI/180., Rot2->value()*PI/180.);
+ thePrs->SetOrientation(ori, Rot1->value()*M_PI/180., Rot2->value()*M_PI/180.);
// position
thePrs->SetPlanePosition(PositionSpn->value(), RelativeChkB->isChecked());
// Set rotation
- Rot1->setValue(theXRotation * 180./PI);
+ Rot1->setValue(theXRotation * 180./M_PI);
Rot1->setEnabled(false);
- Rot2->setValue(theYRotation * 180./PI);
+ Rot2->setValue(theYRotation * 180./M_PI);
Rot2->setEnabled(false);
// Set position