myVertexActor(GEOM_DeviceActor::New(),true),
myVertexSource(GEOM_VertexSource::New(),true),
+ myStandaloneVertexActor(GEOM_DeviceActor::New(),true),
+ myStandaloneVertexSource(GEOM_VertexSource::New(),true),
+
myIsolatedEdgeActor(GEOM_DeviceActor::New(),true),
myIsolatedEdgeSource(GEOM_EdgeSource::New(),true),
myHighlightProp->SetAmbientColor(1, 1, 1);
myHighlightProp->SetDiffuseColor(1, 1, 1);
myHighlightProp->SetSpecularColor(0.5, 0.5, 0.5);
- myHighlightProp->SetPointSize(0);
+ myHighlightProp->SetPointSize(SALOME_POINT_SIZE+2);
myHighlightActor->SetProperty(myHighlightProp.GetPointer());
this->myHighlightActor->SetInput(myAppendFilter->GetOutputPort(),false);
myPreHighlightProp->SetColor(0,1,1);
- myPreHighlightProp->SetPointSize(0);
+ myPreHighlightProp->SetPointSize(SALOME_POINT_SIZE);
myPreHighlightProp->SetLineWidth(SALOME_LINE_WIDTH+1);
myPreHighlightProp->SetRepresentationToWireframe();
aProperty->SetPointSize(3);
aProperty->SetColor(1, 1, 0);
+ myAppendFilter->AddInputConnection(myStandaloneVertexSource->GetOutputPort());
+ myStandaloneVertexActor->SetInput(myStandaloneVertexSource->GetOutputPort(),false);
+ aProperty = myStandaloneVertexActor->GetProperty();
+ aProperty->SetRepresentation(VTK_POINTS);
+ aProperty->SetPointSize(3);
+ aProperty->SetColor(1, 1, 0);
+
myAppendFilter->AddInputConnection(myIsolatedEdgeSource->GetOutputPort());
myIsolatedEdgeActor->SetInput(myIsolatedEdgeSource->GetOutputPort(),false);
aProperty = myIsolatedEdgeActor->GetProperty();
SetModified()
{
this->myVertexSource->Modified();
+ this->myStandaloneVertexSource->Modified();
this->myIsolatedEdgeSource->Modified();
this->myOneFaceEdgeSource->Modified();
this->mySharedEdgeSource->Modified();
myIsolatedEdgeActor->AddToRender(theRenderer);
myVertexActor->AddToRender(theRenderer);
+ myStandaloneVertexActor->AddToRender(theRenderer);
}
void
myIsolatedEdgeActor->RemoveFromRender(theRenderer);
myVertexActor->RemoveFromRender(theRenderer);
+ myStandaloneVertexActor->RemoveFromRender(theRenderer);
SetSelected(false);
myIsolatedEdgeActor->SetVisibility(theVisibility && !myIsSelected);
myVertexActor->SetVisibility(theVisibility && (isOnlyVertex || (myVerticesMode && (!myIsSelected && !myIsPreselected))));// must be added new mode points
+
+ myStandaloneVertexActor->SetVisibility(theVisibility);
}
{
myVerticesMode = theMode;
if ( theMode || isOnlyVertex ) {
- myPreHighlightProp->SetPointSize(SALOME_POINT_SIZE+2);
- myHighlightProp->SetPointSize(SALOME_POINT_SIZE);
+ myAppendFilter->AddInputConnection(myVertexSource->GetOutputPort());
} else {
- myPreHighlightProp->SetPointSize(0);
- myHighlightProp->SetPointSize(0);
+ myAppendFilter->RemoveInputConnection(0, myVertexSource->GetOutputPort());
}
SetModified();
}
myShape = theShape;
myVertexSource->Clear();
+ myStandaloneVertexSource->Clear();
myIsolatedEdgeSource->Clear();
myOneFaceEdgeSource->Clear();
mySharedEdgeSource->Clear();
TopExp::MapShapesAndAncestors(theShape,TopAbs_EDGE,TopAbs_FACE,anEdgeMap);
GEOM::SetShape(theShape,anEdgeMap,theIsVector,
+ myStandaloneVertexSource.Get(),
myIsolatedEdgeSource.Get(),
myOneFaceEdgeSource.Get(),
mySharedEdgeSource.Get(),
if((bool)myShape.Infinite() || isOnlyVertex ){
myVertexActor->GetDeviceActor()->SetInfinitive(true);
+ myStandaloneVertexActor->GetDeviceActor()->SetInfinitive(true);
myHighlightActor->GetDeviceActor()->SetInfinitive(true);
}
return myVertexActor->GetProperty();
}
+vtkProperty* GEOM_Actor::GetStandaloneVertexProperty()
+{
+ return myStandaloneVertexActor->GetProperty();
+}
+
vtkProperty* GEOM_Actor::GetSharedEdgeProperty()
{
return mySharedEdgeActor->GetProperty();
myHighlightProp->SetOpacity(opa);
myPreHighlightProp->SetOpacity(opa);
myVertexActor->GetProperty()->SetOpacity(opa);
+ myStandaloneVertexActor->GetProperty()->SetOpacity(opa);
}
double GEOM_Actor::GetOpacity()
void GEOM_Actor::SetPointColor(double r, double g, double b)
{
myVertexActor->GetProperty()->SetColor(r, g, b);
+ myStandaloneVertexActor->GetProperty()->SetColor(r, g, b);
}
/*!
aCoefnt = theProps[0]->GetAmbient();
myShadingFaceProp->SetAmbient(aCoefnt);
myVertexActor->GetProperty()->SetAmbient(aCoefnt);
+ myStandaloneVertexActor->GetProperty()->SetAmbient(aCoefnt);
if ( aSize == 2 )
aCoefnt = theProps[1]->GetAmbient();
myShadingBackFaceProp->SetAmbient(aCoefnt);
aCoefnt = theProps[0]->GetDiffuse();
myShadingFaceProp->SetDiffuse(aCoefnt);
myVertexActor->GetProperty()->SetDiffuse(aCoefnt);
+ myStandaloneVertexActor->GetProperty()->SetDiffuse(aCoefnt);
if ( aSize == 2 )
aCoefnt = theProps[1]->GetDiffuse();
myShadingBackFaceProp->SetDiffuse(aCoefnt);
aCoefnt = theProps[0]->GetSpecular();
myShadingFaceProp->SetSpecular(aCoefnt);
myVertexActor->GetProperty()->SetSpecular(aCoefnt);
+ myStandaloneVertexActor->GetProperty()->SetSpecular(aCoefnt);
if ( aSize == 2 )
aCoefnt = theProps[1]->GetSpecular();
myShadingBackFaceProp->SetSpecular(aCoefnt);
aColor = theProps[0]->GetAmbientColor();
myShadingFaceProp->SetAmbientColor(aColor[0], aColor[1], aColor[2]);
myVertexActor->GetProperty()->SetAmbientColor(aColor[0], aColor[1], aColor[2]);
+ myStandaloneVertexActor->GetProperty()->SetAmbientColor(aColor[0], aColor[1], aColor[2]);
if ( aSize == 2 )
aColor = theProps[1]->GetAmbientColor();
myShadingBackFaceProp->SetAmbientColor(aColor[0], aColor[1], aColor[2]);
aColor = theProps[0]->GetDiffuseColor();
myShadingFaceProp->SetDiffuseColor(aColor[0], aColor[1], aColor[2]);
myVertexActor->GetProperty()->SetDiffuseColor(aColor[0], aColor[1], aColor[2]);
+ myStandaloneVertexActor->GetProperty()->SetDiffuseColor(aColor[0], aColor[1], aColor[2]);
if ( aSize == 2 )
aColor = theProps[1]->GetDiffuseColor();
myShadingBackFaceProp->SetDiffuseColor(aColor[0], aColor[1], aColor[2]);
aColor = theProps[0]->GetSpecularColor();
myShadingFaceProp->SetSpecularColor(aColor[0], aColor[1], aColor[2]);
myVertexActor->GetProperty()->SetSpecularColor(aColor[0], aColor[1], aColor[2]);
+ myStandaloneVertexActor->GetProperty()->SetSpecularColor(aColor[0], aColor[1], aColor[2]);
if ( aSize == 2 )
aColor = theProps[1]->GetSpecularColor();
myShadingBackFaceProp->SetSpecularColor(aColor[0], aColor[1], aColor[2]);
aCoefnt = theProps[0]->GetSpecularPower();
myShadingFaceProp->SetSpecularPower(aCoefnt);
myVertexActor->GetProperty()->SetSpecularPower(aCoefnt);
+ myStandaloneVertexActor->GetProperty()->SetSpecularPower(aCoefnt);
if ( aSize == 2 )
aCoefnt = theProps[1]->GetSpecularPower();
myShadingBackFaceProp->SetSpecularPower(aCoefnt);