Hi,<br>I have got a very simple problem.<br>I am trying to run below script in pvpython and trying to visualize an image with it.<br>I have a image reader which returns me two arrays:<br>1) Normals<br>2) Texture Coordinates.<br>
and with these arrays I am trying to visualize the image, but unable to do so, since I am unable to apply the <b>Texture Map</b> returned by the reader.<br>The simple code which i am using is like this:<br><br>from paraview.simple import *<br>
servermanager.LoadPlugin('GeoReferencedImageReaderReaderPlugin.so') # plugin works fine in paraview GUI, image is loaded and displayed properly in paraview GUI<br><br>reader=GeoTIFFReader(FileName='CCITT_2.TIF')<br>
reader.UpdatePipelineInformation()<br>view = servermanager.CreateRenderView()<br>repr = servermanager.CreateRepresentation(reader, view)<br>di = reader.GetDataInformation()<br>pdinfo=di.GetPointDataInformation()<br>print pdinfo<br>
<b># Here I gets two array, array[0] = Normals, array[1]= Texture coordinates</b><br>repr.ColorArrayName=pdinfo.GetArrayInformation(1).GetName() # I know this step is wrong, I need an alternate step here to load texture, instead of coloring it with the data, something like<br>
<b>#repr.Texture=pdinfo.GetArrayInformation(0) # But this doesn't work</b><br>repr.MapScalars=False<br>repr.ColorAttributeType<br>view.ResetCamera()<br>view.StillRender()<br><br>Any Help in this will be very much appreciated.<br>
Cheers<br>Jagjeet<br>