[vtkusers] Rendering large 2d numpy array as DEM with several level of details

gmas giumas at yahoo.it
Sun Sep 6 00:40:39 EDT 2015

I am struggling with a quite simple task. How can I implement several LODs
for rendering a 2D numpy array?

        w = 1585
        h = 1262
        np_array = np.random.random(w*h)
        data = vtk.vtkImageData()
        data.SetDimensions(w, h, 1)
        data.GetPointData().SetScalars(numpy_to_vtk(np_array, deep=True,

        mapper = vtk.vtkDataSetMapper()
        mapper.ScalarVisibilityOn()  # set the visibility on the scalar
        actor = vtk.vtkLODProp3D()
        actor.AddLOD(mapper, 0.0)
        # actor.AddLOD(low_mapper, 0.0)  <<< How can I implement a
low-resolution mapper for vtkImageData??? 


I have not been able to find working examples. Which filters could be

View this message in context: http://vtk.1045678.n5.nabble.com/Rendering-large-2d-numpy-array-as-DEM-with-several-level-of-details-tp5733747.html
Sent from the VTK - Users mailing list archive at Nabble.com.

More information about the vtkusers mailing list