if(myRepresentation == VTK_POINTS)
{
UnShrink();
- SetFeatureEdgesEnabled( false );
}
+ SetFeatureEdgesEnabled( theMode == SVTK::Representation::FeatureEdges );
}
mySurfaceActor->UnShrink();
}
+//----------------------------------------------------------------------------
+void
+VISU_ScalarMapAct
+::SetFeatureEdgesAllowed(bool theIsFeatureEdgesAllowed)
+{
+ Superclass::SetFeatureEdgesAllowed(theIsFeatureEdgesAllowed);
+
+ mySurfaceActor->SetFeatureEdgesAllowed(theIsFeatureEdgesAllowed);
+}
+
+void
+VISU_ScalarMapAct
+::SetFeatureEdgesAngle(vtkFloatingPointType theValue)
+{
+ Superclass::SetFeatureEdgesAngle(theValue);
+
+ mySurfaceActor->SetFeatureEdgesAngle(theValue);
+}
+
+void
+VISU_ScalarMapAct
+::SetFeatureEdgesFlags(bool theIsFeatureEdges,
+ bool theIsBoundaryEdges,
+ bool theIsManifoldEdges,
+ bool theIsNonManifoldEdges)
+{
+ Superclass::SetFeatureEdgesFlags(theIsFeatureEdges,
+ theIsBoundaryEdges,
+ theIsManifoldEdges,
+ theIsNonManifoldEdges);
+
+ mySurfaceActor->SetFeatureEdgesFlags(theIsFeatureEdges,
+ theIsBoundaryEdges,
+ theIsManifoldEdges,
+ theIsNonManifoldEdges);
+}
+
+void
+VISU_ScalarMapAct
+::SetFeatureEdgesColoring(bool theIsColoring)
+{
+ Superclass::SetFeatureEdgesColoring(theIsColoring);
+
+ mySurfaceActor->SetFeatureEdgesColoring(theIsColoring);
+}
+
+//----------------------------------------------------------------------------
+void
+VISU_ScalarMapAct
+::SetFeatureEdgesEnabled(bool theIsFeatureEdgesEnabled)
+{
+ if(theIsFeatureEdgesEnabled && myRepresentation == VTK_POINTS)
+ return;
+
+ Superclass::SetFeatureEdgesEnabled(theIsFeatureEdgesEnabled);
+
+ mySurfaceActor->SetFeatureEdgesEnabled(theIsFeatureEdgesEnabled);
+}
+
//----------------------------------------------------------------------------
void
VISU_ScalarMapAct
void
UnShrink();
+ virtual
+ void
+ SetFeatureEdgesAllowed(bool theIsFeatureEdgesAllowed);
+
+ virtual
+ void
+ SetFeatureEdgesEnabled(bool theIsFeatureEdgesEnabled);
+
+ virtual
+ void
+ SetFeatureEdgesAngle(vtkFloatingPointType theAngle = 30.0);
+
+ virtual
+ void
+ SetFeatureEdgesFlags(bool theIsFeatureEdges,
+ bool theIsBoundaryEdges,
+ bool theIsManifoldEdges,
+ bool theIsNonManifoldEdges);
+
+ virtual
+ void
+ SetFeatureEdgesColoring(bool theIsColoring);
+
virtual
void
SetOpacity(vtkFloatingPointType theValue);
myScaleFactor(0.0)
{
SetIsShrinkable(true);
- SetIsFeatureEdgesAllowed(false);
+ SetIsFeatureEdgesAllowed(true);
myWarpVector = vtkWarpVector::New();
myCellDataToPointData = vtkCellDataToPointData::New();
::VISU_ScalarMapOnDeformedShapePL():
myScaleFactor(0.0)
{
+ SetIsFeatureEdgesAllowed(true);
+
myWarpVector = vtkWarpVector::New();
myScalarsMergeFilter = VISU_MergeFilter::New();
myMergeFilter(VISU_MergeFilter::New())
{
SetIsShrinkable(true);
- SetIsFeatureEdgesAllowed(false);
+ SetIsFeatureEdgesAllowed(true);
myAppendFilter->SetMergingInputs(true);
myAppendFilter->Delete();
QString aShrinkType = " and $type in {'VISU::TMESH' 'VISU::TSCALARMAP' 'VISU::TDEFORMEDSHAPE' 'VISU::TSCALARMAPONDEFORMEDSHAPE'}";
QString aLineType = " and $type in {'VISU::TMESH' 'VISU::TSCALARMAP' 'VISU::TSCALARMAP' 'VISU::TISOSURFACES' 'VISU::TDEFORMEDSHAPE' "
"'VISU::TCUTPLANES' 'VISU::TCUTLINES' 'VISU::TSTREAMLINES' 'VISU::TPLOT3D' 'VISU::TSCALARMAPONDEFORMEDSHAPE' }";
- QString aFeatureEdgesType = " and $type in {'VISU::TMESH'}";
+ QString aFeatureEdgesType = " and $type in {'VISU::TMESH' 'VISU::TSCALARMAP''VISU::TDEFORMEDSHAPE' 'VISU::TSCALARMAPONDEFORMEDSHAPE'}";
aRule = "selcount=1";
mgr->setRule( action( VISU_CLIPPING ), aRule + aPrsType );
addPreference( tr( "VISU_SHOW_BOUNDARY_EDGES" ), featureEdgesGr, LightApp_Preferences::Bool, "VISU", "show_boundary_edges" );
addPreference( tr( "VISU_SHOW_MANIFOLD_EDGES" ), featureEdgesGr, LightApp_Preferences::Bool, "VISU", "show_manifold_edges" );
addPreference( tr( "VISU_SHOW_NON_MANIFOLD_EDGES" ), featureEdgesGr, LightApp_Preferences::Bool, "VISU", "show_non_manifold_edges" );
- addPreference( tr( "VISU_FEATURE_EDGES_COLORING" ), featureEdgesGr, LightApp_Preferences::Bool, "VISU", "feature_edges_coloring" );
+ //addPreference( tr( "VISU_FEATURE_EDGES_COLORING" ), featureEdgesGr, LightApp_Preferences::Bool, "VISU", "feature_edges_coloring" );
}
void VisuGUI::preferencesChanged( const QString& a, const QString& b)
myManifoldEdgesCB = new QCheckBox( tr( "SHOW_MANIFOLD_EDGES" ), myGrp );
myNonManifoldEdgesCB = new QCheckBox( tr( "SHOW_NON_MANIFOLD_EDGES" ), myGrp );
- myColoringCB = new QCheckBox( tr( "FEATURE_EDGES_COLORING" ), myGrp );
+ //myColoringCB = new QCheckBox( tr( "FEATURE_EDGES_COLORING" ), myGrp );
aLayout->addWidget( anAngleLbl, 0, 0 );
aLayout->addWidget( myAngleSpinBox, 0, 1 );
aLayout->addWidget( myBoundaryEdgesCB, 2, 0, 1, 2 );
aLayout->addWidget( myManifoldEdgesCB, 3, 0, 1, 2 );
aLayout->addWidget( myNonManifoldEdgesCB, 4, 0, 1, 2 );
- aLayout->addWidget( myColoringCB, 5, 0, 1, 2 );
+ //aLayout->addWidget( myColoringCB, 5, 0, 1, 2 );
aTopLayout->addWidget( myGrp );
myBoundaryEdgesCB->setChecked( anIsBoundaryEdges );
myManifoldEdgesCB->setChecked( anIsManifoldEdges );
myNonManifoldEdgesCB->setChecked( anIsNonManifoldEdges );
- myColoringCB->setChecked( aColoring );
+ //myColoringCB->setChecked( aColoring );
}
void VisuGUI_FeatureEdgesPanel::onApply()
myBoundaryEdgesCB->isChecked(),
myManifoldEdgesCB->isChecked(),
myNonManifoldEdgesCB->isChecked() );
- myActor->SetFeatureEdgesColoring( myColoringCB->isChecked() );
+ //myActor->SetFeatureEdgesColoring( myColoringCB->isChecked() );
myActor->Update();
}
anActor->GetSurfaceProperty()->SetColor(myCellColor.R, myCellColor.G, myCellColor.B);
anActor->GetEdgeProperty()->SetColor(myLinkColor.R, myLinkColor.G, myLinkColor.B);
anActor->GetNodeProperty()->SetColor(myNodeColor.R, myNodeColor.G, myNodeColor.B);
- anActor->SetFeatureEdgesEnabled(myPresentType == VISU::FEATURE_EDGES);
}
}
anActor->SetRepresentation(aDispMode);
if (toShrink && !toSupressShrinking) anActor->SetShrink();
anActor->SetShading(toUseShading);
+
+ anActor->SetFeatureEdgesAngle( aResourceMgr->doubleValue("VISU", "feature_edges_angle", 0.0) );
+ anActor->SetFeatureEdgesFlags( aResourceMgr->booleanValue("VISU", "show_feature_edges", false),
+ aResourceMgr->booleanValue("VISU", "show_boundary_edges", false),
+ aResourceMgr->booleanValue("VISU", "show_manifold_edges", false),
+ aResourceMgr->booleanValue("VISU", "show_non_manifold_edges", false) );
+ anActor->SetFeatureEdgesColoring( aResourceMgr->booleanValue("VISU", "feature_edges_coloring", false) );
+
UpdateActor(anActor);
}catch(...){
anActor->Delete();