Yes, I did set the number of components and number of tuples explicitly. However, the texture is not positioned right.<br><br>I think it because I used a picture which doesn&#39;t belong to the dataset. So, my question is, should I process the image in some way before I map it onto the model? if so, what should I do?<br>
<br>Thank you very much.<br><br>Wenlong<br><br><div class="gmail_quote">2011/11/18 youpie <span dir="ltr">&lt;<a href="mailto:meriadegp@yahoo.fr">meriadegp@yahoo.fr</a>&gt;</span><br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
You mean you work on the texture loaded ?<br>
<br>
I make a little mistake in my last answer.<br>
<br>
Not good :<br>
<div class="im">creat a vtkFloatArray with size of vtkPoints size and associate the good<br>
coordinate texture for each point.<br>
<br>
</div>good :<br>
creat a vtkFloatArray with size of 2 * vtkPoints size and associate the good<br>
coordinate texture for each point. So don4y forget :<br>
 floatArray-&gt;SetNumberOfComponents(2);<br>
        floatArray-&gt;SetNumberOfTuples( vtkPoints size);<br>
        floatArray-&gt;SetTuple2(i, tx, ty);<br>
<span class="HOEnZb"><font color="#888888"><br>
<br>
<br>
--<br>
View this message in context: <a href="http://vtk.1045678.n5.nabble.com/Texture-Mapping-with-2D-Texture-Coordinates-tp4997298p5003697.html" target="_blank">http://vtk.1045678.n5.nabble.com/Texture-Mapping-with-2D-Texture-Coordinates-tp4997298p5003697.html</a><br>

</font></span><div class="HOEnZb"><div class="h5">Sent from the VTK - Users mailing list archive at Nabble.com.<br>
_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.vtk.org/mailman/listinfo/vtkusers" target="_blank">http://www.vtk.org/mailman/listinfo/vtkusers</a><br>
</div></div></blockquote></div><br>