[Paraview] problem with Glyph filter using Python scripting

Sylvester Gerardson sylvester.gerardson at gmail.com
Tue Mar 11 04:23:40 EDT 2008


Hi!

I have a problem applying the Glyph filter using Python scripting.
When running the script shown below (taken from Servermanager2.pdf,
slightly modified), the glyphs are shown correctly but the Output
Messages Window appears saying: "Selected proxy value not in the list:
 2D Glyph". Also the "Glyph Type" selection box is empty thus making
it impossible to change the glyph type using the GUI.

Am I doing something wrong here, or is this a bug?

I have tried on both PV3.2.1 (compiled from source) and 3.3cvs on OpenSUSE 10.3.

Thank you for you time.

regards,
Sylvester


view = servermanager.GetRenderView()

sphere = servermanager.sources.SphereSource(registrationGroup="sources",registrationName="sphere")
repSphere = servermanager.CreateRepresentation(sphere,view,registrationGroup='representations')

elev = servermanager.filters.ElevationFilter(Input=sphere,registrationGroup="sources",registrationName="elev")
repElev = servermanager.CreateRepresentation(elev,view,registrationGroup='representations')

source = servermanager.sources.GlyphSource2D(GlyphType=8)
glyph = servermanager.filters.Glyph(Input=elev,
Source=source,registrationGroup="sources",registrationName="glyph")
glyph.SelectInputScalars = [ '0', '0', '0', '0', 'Elevation' ]
glyph.ScaleMode = 0 # Use scalars
repGlyph = servermanager.CreateRepresentation(glyph,view,registrationGroup='representations')


More information about the ParaView mailing list