<HTML><HEAD></HEAD>
<BODY dir=ltr>
<DIV dir=ltr>
<DIV style="FONT-SIZE: 12pt; FONT-FAMILY: 'Calibri'; COLOR: #000000">
<DIV>Hi,</DIV>
<DIV> </DIV>
<DIV>sorry for cross-posting but no one is answering to my question on the 
vtkusers list.</DIV>
<DIV> </DIV>
<DIV><FONT face="Times New Roman">As you can see running this code the plane is 
visualized without texture.</FONT></DIV>
<DIV><FONT face="Times New Roman"></FONT> </DIV>
<DIV><FONT face="Times New Roman">I think the problem is in rendering a texture 
on a vtkFollower. </FONT></DIV>
<DIV><FONT face="Times New Roman">Can someone open a bug on 
Mantis?</FONT> </DIV>
<DIV><FONT face="Times New Roman"><FONT face=Calibri></FONT> </DIV>
<DIV><BR>#include <vtkImageData.h><BR>#include 
<vtkJPEGReader.h><BR>#include <vtkPolyDataMapper.h><BR>#include 
<vtkPolyData.h><BR>#include <vtkSmartPointer.h><BR>#include 
<vtkTextureMapToPlane.h><BR>#include <vtkPlaneSource.h><BR>#include 
<vtkTexture.h><BR>#include <vtkRenderer.h><BR>#include 
<vtkRenderWindow.h><BR>#include 
<vtkRenderWindowInteractor.h><BR>#include 
<vtkFollower.h><BR>#include <vtkVersion.h><BR><BR>int main ( int 
argc, char *argv[] )<BR>{<BR>// Parse command line arguments<BR>if ( argc != 2 
)<BR>{<BR>std::cerr << "Usage: " << argv[0] << " Filename" 
<< std::endl;<BR>return EXIT_FAILURE;<BR>}<BR><BR>std::cout << "VTK 
version:" << vtkVersion::GetVTKVersion() << 
std::endl;<BR><BR>std::string inputFilename = argv[1];<BR><BR>// Read the image 
which will be the texture<BR>vtkSmartPointer<vtkJPEGReader> jPEGReader 
=<BR>vtkSmartPointer<vtkJPEGReader>::New();<BR>jPEGReader->SetFileName 
( inputFilename.c_str() );<BR><BR>// Create a 
plane<BR>vtkSmartPointer<vtkPlaneSource> plane 
=<BR>vtkSmartPointer<vtkPlaneSource>::New();<BR>plane->SetCenter(0.0, 
0.0, 0.0);<BR>plane->SetNormal(0.0, 0.0, 1.0);<BR><BR>// Apply the 
texture<BR>vtkSmartPointer<vtkTexture> texture 
=<BR>vtkSmartPointer<vtkTexture>::New();<BR>texture->SetInputConnection(jPEGReader->GetOutputPort());<BR><BR>vtkSmartPointer<vtkTextureMapToPlane> 
texturePlane 
=<BR>vtkSmartPointer<vtkTextureMapToPlane>::New();<BR>texturePlane->SetInputConnection(plane->GetOutputPort());<BR><BR>vtkSmartPointer<vtkPolyDataMapper> 
planeMapper 
=<BR>vtkSmartPointer<vtkPolyDataMapper>::New();<BR>planeMapper->SetInputConnection(texturePlane->GetOutputPort());<BR><BR>vtkSmartPointer<vtkFollower> 
texturedPlane 
=<BR>vtkSmartPointer<vtkFollower>::New();<BR>texturedPlane->SetMapper(planeMapper);<BR>texturedPlane->SetTexture(texture);<BR><BR><BR>// 
Visualize the textured plane<BR>vtkSmartPointer<vtkRenderer> renderer 
=<BR>vtkSmartPointer<vtkRenderer>::New();<BR>renderer->AddActor(texturedPlane);<BR><BR>renderer->SetBackground(.1, 
.2, .3); // Background color dark 
blue<BR>renderer->ResetCamera();<BR><BR>texturedPlane->SetCamera(renderer->GetActiveCamera());<BR><BR><BR>vtkSmartPointer<vtkRenderWindow> 
renderWindow 
=<BR>vtkSmartPointer<vtkRenderWindow>::New();<BR>renderWindow->AddRenderer(renderer);<BR><BR>vtkSmartPointer<vtkRenderWindowInteractor> 
renderWindowInteractor 
=<BR>vtkSmartPointer<vtkRenderWindowInteractor>::New();<BR>renderWindowInteractor->SetRenderWindow(renderWindow);<BR><BR>renderWindow->Render();<BR><BR>renderWindowInteractor->Start();<BR><BR>return 
EXIT_SUCCESS;<BR>}</FONT><BR></DIV>
<DIV> </DIV>
<DIV> </DIV></DIV></DIV></BODY></HTML>