View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0002974VTK(No Category)public2006-03-18 17:062016-08-12 09:54
Reporterbryan 
Assigned ToDave DeMarle 
PrioritynormalSeveritymajorReproducibilityalways
StatusclosedResolutionmoved 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version 
Summary0002974: vtkProgrammableSource doesn't work with StructuredGrids
DescriptionvtkProgrammableSource, used from the python bindings, apparently cannot product valid StructuredGrid datasets. The GetStructuredGridOutput() method returns a StructuredGrid object which cannot be rendered.

The script below illustrates this. This script should create a 25-by-25 grid. However, nothing is rendered, even though the output of the Source appears correct (when 'printed').

By contrast, if I create a StructuredGrid manually and use the same function to create the pointSet, it works fine.

Only tested this on linux so far. The problem is the same on VTK-4.2 & 5.0.0

Below is the example (python) code:
------------------------------------------
import vtk

source = vtk.vtkProgrammableSource()
def Execute():
    grid = source.GetStructuredGridOutput()
    points = vtk.vtkPoints()

    nx,ny = 25,25
    
    for i in xrange(nx):
        for j in xrange(ny):
            points.InsertNextPoint(i/5.0,j/5.0,0.0)
            
    grid.SetDimensions(nx,ny,1)
    grid.SetPoints(points)

source.SetExecuteMethod(Execute)
    
map = vtk.vtkDataSetMapper()
map.SetInput(source.GetStructuredGridOutput())

act = vtk.vtkActor()
act.SetMapper(map)

ren = vtk.vtkRenderer()
ren.AddActor(act)

renwin = vtk.vtkRenderWindow()
renwin.AddRenderer(ren)

iren = vtk.vtkRenderWindowInteractor()
iren.SetRenderWindow(renwin)
iren.Start()
TagsNo tags attached.
Project
Type
Attached Files

 Relationships

  Notes
(0030953)
Jean-Christophe Fillion-Robin (manager)
2013-06-05 17:48

Does the problem still occur with VTK 5.10 ? VTK 6 ?
(0031221)
Dave DeMarle (administrator)
2013-07-22 19:20

The problem was that you needed to announce the structured extent in the request information pass. If you that doesn't work in 6.0.0, please reopen.
(0036845)
Kitware Robot (administrator)
2016-08-12 09:54

Resolving issue as `moved`.

This issue tracker is no longer used. Further discussion of this issue may take place in the current VTK Issues page linked in the banner at the top of this page.

 Issue History
Date Modified Username Field Change
2008-11-30 09:12 Mathieu Malaterre Assigned To Mathieu Malaterre => David Cole
2011-01-19 09:57 David Cole Assigned To David Cole =>
2011-06-16 13:11 Zack Galbreath Category => (No Category)
2013-06-05 17:48 Jean-Christophe Fillion-Robin Note Added: 0030953
2013-07-22 19:20 Dave DeMarle Note Added: 0031221
2013-07-22 19:20 Dave DeMarle Status backlog => expired
2013-07-22 19:20 Dave DeMarle Assigned To => Dave DeMarle
2016-08-12 09:54 Kitware Robot Note Added: 0036845
2016-08-12 09:54 Kitware Robot Status expired => closed
2016-08-12 09:54 Kitware Robot Resolution open => moved


Copyright © 2000 - 2018 MantisBT Team