return myMapperTable->GetBicolor();
}
+//----------------------------------------------------------------------------
+void
+VISU_GaussPointsPL
+::SetIsColored(bool theIsColored)
+{
+ myPSMapper->SetPointSpriteResults( theIsColored );
+}
+
//----------------------------------------------------------------------------
float
VISU_GaussPointsPL
::SetMinSize(float theMinSize)
{
myMinSize = theMinSize;
- myPSMapper->SetPointSpriteSize( 0.0 );
myPSMapper->SetPointSpriteMinSize( 1000.0 * myAverageCellSize * myMinSize / 100.0 );
Modified();
::SetMaxSize(float theMaxSize)
{
myMaxSize = theMaxSize;
- myPSMapper->SetPointSpriteSize( 0.0 );
myPSMapper->SetPointSpriteMaxSize( 1000.0 * myAverageCellSize * myMaxSize / 100.0 );
Modified();
this->UseTextures = true;
this->UseShader = true;
+ this->PointSpriteResults = true;
+
this->PointSpriteClamp = 100.0;
this->PointSpriteSize = 0.0;
this->PointSpriteMinSize = 15.0;
VISU_OpenGLPointSpriteMapper* m = VISU_OpenGLPointSpriteMapper::SafeDownCast(mapper);
if( m != NULL )
{
+ this->SetPointSpriteResults( m->GetPointSpriteResults() );
+
this->SetPointSpriteClamp( m->GetPointSpriteClamp() );
this->SetPointSpriteSize( m->GetPointSpriteSize() );
this->SetPointSpriteMinSize( m->GetPointSpriteMinSize() );
}
#endif
//-----------------------------------------------------------------------------
+void VISU_OpenGLPointSpriteMapper::SetPointSpriteResults( bool theResults )
+{
+ this->PointSpriteResults = theResults;
+#ifdef GL_ARB_shader_objects
+ this->SetShaderVariable( "results", theResults );
+#endif
+}
+//-----------------------------------------------------------------------------
void VISU_OpenGLPointSpriteMapper::SetPointSpriteClamp( float theClamp )
{
this->PointSpriteClamp = theClamp;
this->SetShaderVariable( "attrib1", 1.0 );
this->SetShaderVariable( "attrib2", 1.0 );
this->SetShaderVariable( "attrib3", 1.0 );
+ this->SetShaderVariable( "results", this->PointSpriteResults );
this->SetShaderVariable( "clamp", this->PointSpriteClamp );
this->SetShaderVariable( "geomSize", this->PointSpriteSize );
- this->SetShaderVariable( "minSize", this->PointSpriteMinSize );
this->SetShaderVariable( "attrib4", 1.0 );
+ this->SetShaderVariable( "minSize", this->PointSpriteMinSize );
this->SetShaderVariable( "maxSize", this->PointSpriteMaxSize );
this->SetShaderVariable( "magnification", this->PointSpriteMagnification );
}
vtkSetMacro(UseShader, bool);
vtkGetMacro(UseShader, bool);
+ // Description:
+ // Point Sprite drawing mode
+ // (Results - multicolor, Geometry - fixed color)
+ vtkGetMacro(PointSpriteResults, bool);
+
// Description:
// Point Sprite size parameters
vtkGetMacro(PointSpriteClamp, float);
vtkGetMacro(PointSpriteMaxSize, float);
vtkGetMacro(PointSpriteMagnification, float);
+ void SetPointSpriteResults( bool );
void SetPointSpriteClamp( float );
void SetPointSpriteSize( float );
void SetPointSpriteMinSize( float );
void* OpenGLLibrary;
#endif
+ bool PointSpriteResults;
+
float PointSpriteClamp;
float PointSpriteSize;
float PointSpriteMinSize;