mirror of
https://git.salome-platform.org/gitpub/modules/geom.git
synced 2025-02-23 00:35:36 +05:00
Fix for Bug IPAL17725:
TC71: shapes in shading selected in VTK become in wireframe
This commit is contained in:
parent
7b052b046b
commit
d3703226ee
@ -306,11 +306,6 @@ SetVisibility(int theVisibility)
|
|||||||
|
|
||||||
this->myHighlightActor->SetVisibility(theVisibility && (myIsSelected || myIsPreselected));
|
this->myHighlightActor->SetVisibility(theVisibility && (myIsSelected || myIsPreselected));
|
||||||
|
|
||||||
// if(myDisplayMode == (int)eShading)
|
|
||||||
// this->myHighlightActor->SetInput(myShadingFaceSource->GetOutput(),false);
|
|
||||||
// else
|
|
||||||
// this->myHighlightActor->SetInput(myAppendFilter->GetOutput(),false);
|
|
||||||
|
|
||||||
myShadingFaceActor->SetVisibility(theVisibility && (myDisplayMode == (int)eShading) && (!myIsSelected || !myIsPreselected));
|
myShadingFaceActor->SetVisibility(theVisibility && (myDisplayMode == (int)eShading) && (!myIsSelected || !myIsPreselected));
|
||||||
myWireframeFaceActor->SetVisibility(theVisibility && (myDisplayMode ==(int)eWireframe) && !myIsSelected);
|
myWireframeFaceActor->SetVisibility(theVisibility && (myDisplayMode ==(int)eWireframe) && !myIsSelected);
|
||||||
|
|
||||||
@ -508,7 +503,7 @@ void GEOM_Actor::SetShadingProperty(vtkProperty* Prop)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void GEOM_Actor::Render(vtkRenderer *ren, vtkMapper *Mapper)
|
void GEOM_Actor::Render(vtkRenderer *ren, vtkMapper *theMapper)
|
||||||
{
|
{
|
||||||
#ifdef MYDEBUG
|
#ifdef MYDEBUG
|
||||||
cout << "GEOM_Actor::Render"<<endl;
|
cout << "GEOM_Actor::Render"<<endl;
|
||||||
@ -517,7 +512,7 @@ void GEOM_Actor::Render(vtkRenderer *ren, vtkMapper *Mapper)
|
|||||||
if(!GetVisibility())
|
if(!GetVisibility())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
/* render the property */
|
/* render the property */
|
||||||
if (!this->Property) {
|
if (!this->Property) {
|
||||||
// force creation of a property
|
// force creation of a property
|
||||||
this->GetProperty();
|
this->GetProperty();
|
||||||
@ -574,10 +569,11 @@ void GEOM_Actor::Render(vtkRenderer *ren, vtkMapper *Mapper)
|
|||||||
vtkMatrix4x4 *aMatrix = vtkMatrix4x4::New();
|
vtkMatrix4x4 *aMatrix = vtkMatrix4x4::New();
|
||||||
this->GetMatrix(ren->GetActiveCamera(), aMatrix);
|
this->GetMatrix(ren->GetActiveCamera(), aMatrix);
|
||||||
this->Device->SetUserMatrix(aMatrix);
|
this->Device->SetUserMatrix(aMatrix);
|
||||||
this->Device->Render(ren,this->Mapper);
|
this->Device->Render(ren,theMapper);
|
||||||
aMatrix->Delete();
|
aMatrix->Delete();
|
||||||
} else
|
} else
|
||||||
this->Device->Render(ren, this->Mapper);
|
this->Device->Render(ren, theMapper);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void GEOM_Actor::ReleaseGraphicsResources(vtkWindow *)
|
void GEOM_Actor::ReleaseGraphicsResources(vtkWindow *)
|
||||||
@ -653,7 +649,7 @@ void GEOM_Actor::SubShapeOff()
|
|||||||
void GEOM_Actor::highlight(bool highlight)
|
void GEOM_Actor::highlight(bool highlight)
|
||||||
{
|
{
|
||||||
#ifdef MYDEBUG
|
#ifdef MYDEBUG
|
||||||
cout << "GEOM_Actor::highlight highlight="<<highlight<<endl;
|
cout << this << " GEOM_Actor::highlight highlight="<<highlight<<endl;
|
||||||
#endif
|
#endif
|
||||||
SALOME_Actor::highlight(highlight);
|
SALOME_Actor::highlight(highlight);
|
||||||
}
|
}
|
||||||
@ -702,12 +698,11 @@ GEOM_Actor
|
|||||||
{
|
{
|
||||||
myIsSelected = theIsHighlight;
|
myIsSelected = theIsHighlight;
|
||||||
#ifdef MYDEBUG
|
#ifdef MYDEBUG
|
||||||
cout << "GEOM_Actor::Highlight myIsSelected="<<myIsSelected<<endl;
|
cout << this << " GEOM_Actor::Highlight myIsSelected="<<myIsSelected<<endl;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
SALOME_Actor::Highlight(theIsHighlight); // this method call ::highlight(theIsHighlight) in the end
|
SALOME_Actor::Highlight(theIsHighlight); // this method call ::highlight(theIsHighlight) in the end
|
||||||
SetVisibility(GetVisibility());
|
SetVisibility(GetVisibility());
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
@ -720,8 +715,9 @@ GEOM_Actor
|
|||||||
bool theIsHighlight)
|
bool theIsHighlight)
|
||||||
{
|
{
|
||||||
#ifdef MYDEBUG
|
#ifdef MYDEBUG
|
||||||
cout << "this="<<this<<" GEOM_Actor::PreHighlight (3) theIsHighlight="<<theIsHighlight<<endl;
|
cout << this<<" GEOM_Actor::PreHighlight (3) theIsHighlight="<<theIsHighlight<<endl;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if ( !GetPickable() )
|
if ( !GetPickable() )
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
@ -764,10 +760,13 @@ GEOM_Actor
|
|||||||
{
|
{
|
||||||
// define the selection of object
|
// define the selection of object
|
||||||
#ifdef MYDEBUG
|
#ifdef MYDEBUG
|
||||||
cout << endl << "GEOM_Actor::Highlight (3) myIsSelected="<<myIsSelected<<endl;
|
cout << endl << this << " GEOM_Actor::Highlight (3) myIsSelected="<<myIsSelected<<endl;
|
||||||
#endif
|
#endif
|
||||||
bool aRet = SALOME_Actor::Highlight(theInteractorStyle,theSelectionEvent,theIsHighlight);
|
bool aRet = SALOME_Actor::Highlight(theInteractorStyle,theSelectionEvent,theIsHighlight);
|
||||||
SetSelected(theIsHighlight);
|
SetSelected(theIsHighlight);
|
||||||
|
if(theIsHighlight)
|
||||||
|
SetPreSelected(false);
|
||||||
|
|
||||||
|
|
||||||
return aRet;
|
return aRet;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user