[FEM] ViewProviderFemConstrain*: remove unused includes - part 1
- also sort includes - also fix warnings about too long lines
This commit is contained in:
@@ -23,30 +23,23 @@
|
||||
* *
|
||||
***************************************************************************/
|
||||
|
||||
|
||||
#include "PreCompiled.h"
|
||||
|
||||
#ifndef _PreComp_
|
||||
# include <Standard_math.hxx>
|
||||
# include <Precision.hxx>
|
||||
|
||||
# include <Inventor/nodes/SoSeparator.h>
|
||||
# include <Inventor/nodes/SoTranslation.h>
|
||||
# include <Inventor/nodes/SoRotation.h>
|
||||
# include <Inventor/nodes/SoMultipleCopy.h>
|
||||
# include <Inventor/nodes/SoCylinder.h>
|
||||
# include <Inventor/nodes/SoSphere.h>
|
||||
# include <Inventor/nodes/SoText3.h>
|
||||
# include <Inventor/nodes/SoFont.h>
|
||||
# include <Inventor/nodes/SoMaterial.h>
|
||||
# include <Inventor/nodes/SoMaterialBinding.h>
|
||||
# include <Inventor/nodes/SoRotation.h>
|
||||
# include <Inventor/nodes/SoSeparator.h>
|
||||
# include <Inventor/nodes/SoSphere.h>
|
||||
# include <Inventor/nodes/SoTranslation.h>
|
||||
#endif
|
||||
|
||||
#include "Mod/Fem/App/FemConstraintHeatflux.h"
|
||||
#include "TaskFemConstraintHeatflux.h"
|
||||
#include "ViewProviderFemConstraintHeatflux.h"
|
||||
#include <Base/Console.h>
|
||||
#include <Gui/Control.h>
|
||||
#include "Mod/Fem/App/FemConstraintHeatflux.h"
|
||||
|
||||
#include "ViewProviderFemConstraintHeatflux.h"
|
||||
#include "TaskFemConstraintHeatflux.h"
|
||||
|
||||
|
||||
using namespace FemGui;
|
||||
|
||||
@@ -55,7 +48,7 @@ PROPERTY_SOURCE(FemGui::ViewProviderFemConstraintHeatflux, FemGui::ViewProviderF
|
||||
ViewProviderFemConstraintHeatflux::ViewProviderFemConstraintHeatflux()
|
||||
{
|
||||
sPixmap = "FEM_ConstraintHeatflux";
|
||||
ADD_PROPERTY(FaceColor,(0.2f,0.3f,0.2f));
|
||||
ADD_PROPERTY(FaceColor, (0.2f, 0.3f, 0.2f));
|
||||
}
|
||||
|
||||
ViewProviderFemConstraintHeatflux::~ViewProviderFemConstraintHeatflux()
|
||||
@@ -133,56 +126,56 @@ void ViewProviderFemConstraintHeatflux::updateData(const App::Property* prop)
|
||||
|
||||
///draw a temp gauge,with sphere and a cylinder
|
||||
//first move to correct position
|
||||
SoTranslation* trans = new SoTranslation();
|
||||
SbVec3f newPos=base+scaledradius*dir*0.7f;
|
||||
SoTranslation *trans = new SoTranslation();
|
||||
SbVec3f newPos = base + scaledradius * dir * 0.7f;
|
||||
trans->translation.setValue(newPos);
|
||||
sep->addChild(trans);
|
||||
|
||||
//adjust orientation
|
||||
SoRotation* rot = new SoRotation();
|
||||
rot->rotation.setValue(SbRotation(SbVec3f(0,1,0),dir));
|
||||
SoRotation *rot = new SoRotation();
|
||||
rot->rotation.setValue(SbRotation(SbVec3f(0, 1, 0), dir));
|
||||
sep->addChild(rot);
|
||||
|
||||
//define color of shape
|
||||
SoMaterial* myMaterial = new SoMaterial;
|
||||
myMaterial->diffuseColor.set1Value(0,SbColor(0.65f,0.1f,0.25f));//RGB
|
||||
SoMaterial *myMaterial = new SoMaterial;
|
||||
myMaterial->diffuseColor.set1Value(0, SbColor(0.65f, 0.1f, 0.25f));//RGB
|
||||
//myMaterial->diffuseColor.set1Value(1,SbColor(.1,.1,.1));//possible to adjust sides separately
|
||||
sep->addChild(myMaterial);
|
||||
|
||||
//draw a sphere
|
||||
SoSphere* sph = new SoSphere();
|
||||
sph->radius.setValue(scaledradius*0.75);
|
||||
SoSphere *sph = new SoSphere();
|
||||
sph->radius.setValue(scaledradius * 0.75);
|
||||
sep->addChild(sph);
|
||||
//translate position
|
||||
SoTranslation* trans2 = new SoTranslation();
|
||||
trans2->translation.setValue(SbVec3f(0,scaledheight*0.375,0));
|
||||
SoTranslation *trans2 = new SoTranslation();
|
||||
trans2->translation.setValue(SbVec3f(0, scaledheight * 0.375, 0));
|
||||
sep->addChild(trans2);
|
||||
//draw a cylinder
|
||||
SoCylinder* cyl = new SoCylinder();
|
||||
cyl->height.setValue(scaledheight*0.5);
|
||||
cyl->radius.setValue(scaledradius*0.375);
|
||||
SoCylinder *cyl = new SoCylinder();
|
||||
cyl->height.setValue(scaledheight * 0.5);
|
||||
cyl->radius.setValue(scaledradius * 0.375);
|
||||
sep->addChild(cyl);
|
||||
//translate position
|
||||
SoTranslation* trans3 = new SoTranslation();
|
||||
trans3->translation.setValue(SbVec3f(0,scaledheight*0.375,0));
|
||||
SoTranslation *trans3 = new SoTranslation();
|
||||
trans3->translation.setValue(SbVec3f(0, scaledheight * 0.375, 0));
|
||||
sep->addChild(trans3);
|
||||
//define color of shape
|
||||
SoMaterial *myMaterial2 = new SoMaterial;
|
||||
myMaterial2->diffuseColor.set1Value(0,SbColor(1,1,1));//RGB
|
||||
myMaterial2->diffuseColor.set1Value(0, SbColor(1, 1, 1));//RGB
|
||||
sep->addChild(myMaterial2);
|
||||
//draw a cylinder
|
||||
SoCylinder* cyl2 = new SoCylinder();
|
||||
cyl2->height.setValue(scaledheight*0.25);
|
||||
cyl2->radius.setValue(scaledradius*0.375);
|
||||
SoCylinder *cyl2 = new SoCylinder();
|
||||
cyl2->height.setValue(scaledheight * 0.25);
|
||||
cyl2->radius.setValue(scaledradius * 0.375);
|
||||
sep->addChild(cyl2);
|
||||
//translate position
|
||||
SoTranslation* trans4 = new SoTranslation();
|
||||
trans4->translation.setValue(SbVec3f(0,-scaledheight*0.375,0));
|
||||
//translate position
|
||||
SoTranslation *trans4 = new SoTranslation();
|
||||
trans4->translation.setValue(SbVec3f(0, -scaledheight * 0.375, 0));
|
||||
sep->addChild(trans4);
|
||||
//draw a cylinder
|
||||
SoCylinder* cyl3 = new SoCylinder();
|
||||
cyl3->height.setValue(scaledheight*0.05);
|
||||
cyl3->radius.setValue(scaledradius*1);
|
||||
//draw a cylinder
|
||||
SoCylinder *cyl3 = new SoCylinder();
|
||||
cyl3->height.setValue(scaledheight * 0.05);
|
||||
cyl3->radius.setValue(scaledradius * 1);
|
||||
sep->addChild(cyl3);
|
||||
|
||||
pShapeSep->addChild(sep);
|
||||
|
||||
Reference in New Issue
Block a user