<div dir="ltr">It does not look like you ever set the number of points. From the documentation for vtkPoints::SetPoint<div><br></div><div><span style="color:rgb(0,0,0);font-family:Roboto,sans-serif;font-size:14px;line-height:22px">Insert point into object. No range checking performed (fast!). Make sure you use </span><a class="" href="http://www.vtk.org/doc/nightly/html/classvtkPoints.html#ab290ea156aa2635aa7d2d64998dc04e2" style="color:rgb(70,101,162);font-weight:bold;font-family:Roboto,sans-serif;font-size:14px;line-height:22px">SetNumberOfPoints()</a><span style="color:rgb(0,0,0);font-family:Roboto,sans-serif;font-size:14px;line-height:22px"> to allocate memory prior to using </span><a class="" href="http://www.vtk.org/doc/nightly/html/classvtkPoints.html#a0ca9c77d1efbeb7dff8d15ec34b19192" style="color:rgb(70,101,162);font-weight:bold;font-family:Roboto,sans-serif;font-size:14px;line-height:22px">SetPoint()</a><span style="color:rgb(0,0,0);font-family:Roboto,sans-serif;font-size:14px;line-height:22px">.</span><br></div><div><span style="color:rgb(0,0,0);font-family:Roboto,sans-serif;font-size:14px;line-height:22px"><br></span></div><div><span style="color:rgb(0,0,0);font-family:Roboto,sans-serif;font-size:14px;line-height:22px">Resize allocates memory but I do not believe it sets the number of points. So from the mapper's perspective you still had zero points. InsertNextPoint is slower but it handles adjust the memory and number of points automatically.</span></div><div><span style="color:rgb(0,0,0);font-family:Roboto,sans-serif;font-size:14px;line-height:22px"><br></span></div><div><span style="color:rgb(0,0,0);font-family:Roboto,sans-serif;font-size:14px;line-height:22px">Thanks</span></div><div><font color="#000000" face="Roboto, sans-serif"><span style="font-size:14px;line-height:22px">Ken</span></font></div><div><font color="#000000" face="Roboto, sans-serif"><span style="font-size:14px;line-height:22px"><br></span></font></div><div><span style="color:rgb(0,0,0);font-family:Roboto,sans-serif;font-size:14px;line-height:22px"><br></span></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Jan 18, 2016 at 12:45 PM, MOUSSAUD David 244079 <span dir="ltr"><<a href="mailto:David.MOUSSAUD@cea.fr" target="_blank">David.MOUSSAUD@cea.fr</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div>
<div style="direction:ltr;font-family:Tahoma;color:#000000;font-size:10pt">
<p>Hi,</p>
<p> </p>
<p>I have finally found how to display my colored points.</p>
<p> </p>
<p>Instead of using</p>
<p><font color="#800000"> points</font>->SetPoint(<font color="navy">0</font>,<font color="silver">
</font><font color="navy">0.1</font>,<font color="silver"> </font><font color="navy">0.0</font>,<font color="silver">
</font><font color="navy">0.0</font>);</p>
<p>I have used </p>
<p><span style="COLOR:#800000"> points</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">InsertNextPoint</span><span style="COLOR:#000000">(</span><span style="COLOR:#000080">0.1</span><span style="COLOR:#000000">,</span><span style="COLOR:#c0c0c0">
</span><span style="COLOR:#000080">0.0</span><span style="COLOR:#000000">,</span><span style="COLOR:#c0c0c0">
</span><span style="COLOR:#000080">0.0</span><span style="COLOR:#000000">);</span></p>
<p><span style="COLOR:#000000"></span> </p>
<p><span style="COLOR:#000000">and it works like a charm !</span></p>
<p><span style="COLOR:#000000"></span> </p>
<p><span style="COLOR:#000000">Could someone explain me(us) why, calling this API, it does not make appear the 2 warning messages below ?</span></p>
<p><span style="COLOR:#000000"></span> </p>
<p><span style="COLOR:#000000">Best regards,</span></p>
<p><span style="COLOR:#000000">David.</span></p>
<div style="FONT-SIZE:16px;FONT-FAMILY:Times New Roman;COLOR:#000000">
<hr>
<div style="DIRECTION:ltr"><font color="#000000" size="2" face="Tahoma"><b>De :</b> vtkusers [<a href="mailto:vtkusers-bounces@vtk.org" target="_blank">vtkusers-bounces@vtk.org</a>] de la part de MOUSSAUD David 244079<br>
<b>Envoyé :</b> jeudi 14 janvier 2016 09:51<br>
<b>À :</b> <a href="mailto:vtkusers@vtk.org" target="_blank">vtkusers@vtk.org</a><br>
<b>Objet :</b> [PROVENANCE INTERNET] [vtkusers] opengl2 : set the RGB color to a vertex with vtkPolyData and vtkPolyDataMapper<br>
</font><br>
</div>
<div></div>
<div>
<div style="FONT-SIZE:10pt;FONT-FAMILY:Tahoma;COLOR:#000000;DIRECTION:ltr">
<p>Dear all,</p>
<p> </p>
<p>I'm trying to use the opengl2 backend rendering. I am with the 6.3 release version.</p>
<p> </p>
<p>I have a working code to display 3 colored vertex that works with opengl1 (cf below and attached file).</p>
<p> </p>
<p> </p>
<p><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">//</span><span style="COLOR:#c0c0c0">
</span><span style="COLOR:#008000">Setup</span><span style="COLOR:#c0c0c0"> </span>
<span style="COLOR:#008000">points</span></p>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">points</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000000">=</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800080">vtkSmartPointer</span><span style="COLOR:#000000"><</span><span style="COLOR:#800080">vtkPoints</span><span style="COLOR:#000000">>::</span><span style="COLOR:#000000">New</span><span style="COLOR:#000000">();</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><br></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">//</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">Setup</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">the</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">colors</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">array</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">colors</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000000">=</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800080">vtkSmartPointer</span><span style="COLOR:#000000"><</span><span style="COLOR:#800080">vtkUnsignedCharArray</span><span style="COLOR:#000000">>::</span><span style="COLOR:#000000">New</span><span style="COLOR:#000000">();</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">colors</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000;FONT-STYLE:italic">SetNumberOfComponents</span><span style="COLOR:#000000">(</span><span style="COLOR:#000080">3</span><span style="COLOR:#000000">);</span><span style="COLOR:#c0c0c0"> </span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">colors</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000;FONT-STYLE:italic">SetName</span><span style="COLOR:#000000">(</span><span style="COLOR:#008000">"Colors"</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><br></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">//</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">create</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">a</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">vertex</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">vertex</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000000">=</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800080">vtkSmartPointer</span><span style="COLOR:#000000"><</span><span style="COLOR:#800080">vtkVertex</span><span style="COLOR:#000000">>::</span><span style="COLOR:#000000">New</span><span style="COLOR:#000000">();</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><br></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">//</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">list</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">of</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">all</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">the</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">vertices</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">vertices</span><span style="COLOR:#000000">=</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800080">vtkSmartPointer</span><span style="COLOR:#000000"><</span><span style="COLOR:#800080">vtkCellArray</span><span style="COLOR:#000000">>::</span><span style="COLOR:#000000">New</span><span style="COLOR:#000000">();</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><br></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">nb_points</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000000">=</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000080">3</span><span style="COLOR:#000000">;</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">points</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">Resize</span><span style="COLOR:#000000">(</span><span style="COLOR:#800000">nb_points</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">vertices</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">Initialize</span><span style="COLOR:#000000">();</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">colors</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000;FONT-STYLE:italic">Initialize</span><span style="COLOR:#000000">();</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><br></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">points</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">SetPoint</span><span style="COLOR:#000000">(</span><span style="COLOR:#000080">0</span><span style="COLOR:#000000">,</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000080">0.1</span><span style="COLOR:#000000">,</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000080">0.0</span><span style="COLOR:#000000">,</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000080">0.0</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">vertex</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">GetPointIds</span><span style="COLOR:#000000">()-></span><span style="COLOR:#000000">SetId</span><span style="COLOR:#000000">(</span><span style="COLOR:#000080">0</span><span style="COLOR:#000000">,</span><span style="COLOR:#000080">0</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">vertices</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">InsertNextCell</span><span style="COLOR:#000000">(</span><span style="COLOR:#800000">vertex</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">colors</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">InsertNextTuple3</span><span style="COLOR:#000000">(</span><span style="COLOR:#000080">255</span><span style="COLOR:#000000">,</span><span style="COLOR:#000080">0</span><span style="COLOR:#000000">,</span><span style="COLOR:#000080">0</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><br></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">points</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">SetPoint</span><span style="COLOR:#000000">(</span><span style="COLOR:#000080">1</span><span style="COLOR:#000000">,</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000080">0</span><span style="COLOR:#000000">,</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000080">0.1</span><span style="COLOR:#000000">,</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000080">0.0</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">vertex</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">GetPointIds</span><span style="COLOR:#000000">()-></span><span style="COLOR:#000000">SetId</span><span style="COLOR:#000000">(</span><span style="COLOR:#000080">0</span><span style="COLOR:#000000">,</span><span style="COLOR:#000080">1</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">vertices</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">InsertNextCell</span><span style="COLOR:#000000">(</span><span style="COLOR:#800000">vertex</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">colors</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">InsertNextTuple3</span><span style="COLOR:#000000">(</span><span style="COLOR:#000080">0</span><span style="COLOR:#000000">,</span><span style="COLOR:#000080">255</span><span style="COLOR:#000000">,</span><span style="COLOR:#000080">0</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><br></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">points</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">SetPoint</span><span style="COLOR:#000000">(</span><span style="COLOR:#000080">2</span><span style="COLOR:#000000">,</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000080">0</span><span style="COLOR:#000000">,</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000080">0.0</span><span style="COLOR:#000000">,</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000080">0.1</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">vertex</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">GetPointIds</span><span style="COLOR:#000000">()-></span><span style="COLOR:#000000">SetId</span><span style="COLOR:#000000">(</span><span style="COLOR:#000080">0</span><span style="COLOR:#000000">,</span><span style="COLOR:#000080">2</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">vertices</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">InsertNextCell</span><span style="COLOR:#000000">(</span><span style="COLOR:#800000">vertex</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">colors</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">InsertNextTuple3</span><span style="COLOR:#000000">(</span><span style="COLOR:#000080">0</span><span style="COLOR:#000000">,</span><span style="COLOR:#000080">0</span><span style="COLOR:#000000">,</span><span style="COLOR:#000080">255</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><br></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">//</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">Create</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">a</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">polydata</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">object</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">and</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">add</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">everything</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">to</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">it</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">polydata</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000000">=</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800080">vtkSmartPointer</span><span style="COLOR:#000000"><</span><span style="COLOR:#800080">vtkPolyData</span><span style="COLOR:#000000">>::</span><span style="COLOR:#000000">New</span><span style="COLOR:#000000">();</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">polydata</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000;FONT-STYLE:italic">SetPoints</span><span style="COLOR:#000000">(</span><span style="COLOR:#800000">points</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">polydata</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">SetVerts</span><span style="COLOR:#000000">(</span><span style="COLOR:#800000">vertices</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">polydata</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">GetPointData</span><span style="COLOR:#000000">()-></span><span style="COLOR:#000000">SetScalars</span><span style="COLOR:#000000">(</span><span style="COLOR:#800000">colors</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><br></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">mapper</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000000">=</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800080">vtkSmartPointer</span><span style="COLOR:#000000"><</span><span style="COLOR:#800080">vtkPolyDataMapper</span><span style="COLOR:#000000">>::</span><span style="COLOR:#000000">New</span><span style="COLOR:#000000">();</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><br></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">mapper</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">SetInputData</span><span style="COLOR:#000000">(</span><span style="COLOR:#800000">polydata</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><br></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">actor</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000000">=</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800080">vtkSmartPointer</span><span style="COLOR:#000000"><</span><span style="COLOR:#800080">vtkActor</span><span style="COLOR:#000000">>::</span><span style="COLOR:#000000">New</span><span style="COLOR:#000000">();</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">actor</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000;FONT-STYLE:italic">SetMapper</span><span style="COLOR:#000000">(</span><span style="COLOR:#800000">mapper</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">actor</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">GetProperty</span><span style="COLOR:#000000">()-></span><span style="COLOR:#000000;FONT-STYLE:italic">SetPointSize</span><span style="COLOR:#000000">(</span><span style="COLOR:#000080">5</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><br></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">//</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">Setup</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">window</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">renderWindow</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000000">=</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800080">vtkSmartPointer</span><span style="COLOR:#000000"><</span><span style="COLOR:#800080">vtkRenderWindow</span><span style="COLOR:#000000">>::</span><span style="COLOR:#000000">New</span><span style="COLOR:#000000">();</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><br></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">//</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">Setup</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#008000">renderer</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">renderer</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#000000">=</span><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800080">vtkSmartPointer</span><span style="COLOR:#000000"><</span><span style="COLOR:#800080">vtkRenderer</span><span style="COLOR:#000000">>::</span><span style="COLOR:#000000">New</span><span style="COLOR:#000000">();</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">renderWindow</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000;FONT-STYLE:italic">AddRenderer</span><span style="COLOR:#000000">(</span><span style="COLOR:#800000">renderer</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><br></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">renderer</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">AddActor</span><span style="COLOR:#000000">(</span><span style="COLOR:#800000">actor</span><span style="COLOR:#000000">);</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#800000">renderer</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000">ResetCamera</span><span style="COLOR:#000000">();</span></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><br></pre>
<pre style="MARGIN:0px;TEXT-INDENT:0px"><span style="COLOR:#c0c0c0"> </span><span style="COLOR:#808000">this</span><span style="COLOR:#000000">-></span><span style="COLOR:#000000;FONT-STYLE:italic">SetRenderWindow</span><span style="COLOR:#000000">(</span><span style="COLOR:#800000">renderWindow</span><span style="COLOR:#000000">);</span></pre>
<p> </p>
<p>When I compile the same project with my vtk library compiled with the opengl2 backend rendering,</p>
<p> </p>
<p>I have this error :</p>
<p> </p>
<p>ERROR: In C:\work\lib\vtk\VTK-6.3.0\VTK-6.3.0\Rendering\OpenGL2\vtkOpenGLPolyDataMapper.cxx, line 1223<br>
vtkOpenGLPolyDataMapper (0000000000501B90): Error setting 'vertexMC' in shader VAO.</p>
<p>ERROR: In C:\work\lib\vtk\VTK-6.3.0\VTK-6.3.0\Rendering\OpenGL2\vtkOpenGLPolyDataMapper.cxx, line 1250<br>
vtkOpenGLPolyDataMapper (0000000000501B90): Error setting 'scalarColor' in shader VAO.</p>
<p> </p>
<p>For information, I've tried the same with a vtkPlyReader based project and I've succeed to render it with opengl2 backend (and it works very much better !)</p>
<p> </p>
<p>Best Regards,</p>
<p>David.</p>
<p> </p>
<p> </p>
</div>
</div>
</div>
</div>
</div>
<br>_______________________________________________<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" 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" rel="noreferrer" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Search the list archives at: <a href="http://markmail.org/search/?q=vtkusers" rel="noreferrer" target="_blank">http://markmail.org/search/?q=vtkusers</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/vtkusers" rel="noreferrer" target="_blank">http://public.kitware.com/mailman/listinfo/vtkusers</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature">Ken Martin PhD<div>Chairman & CFO<br>Kitware Inc.<br>28 Corporate Drive<br>Clifton Park NY 12065<br>518 371 3971<div><br></div><div><span style="font-size:10pt;font-family:Tahoma,sans-serif">This communication,
including all attachments, contains confidential and legally privileged
information, and it is intended only for the use of the addressee. Access to this email by anyone else is
unauthorized. If you are not the intended recipient, any disclosure, copying,
distribution or any action taken in reliance on it is prohibited and may be
unlawful. If you received this communication in error please notify us
immediately and destroy the original message.
Thank you.</span></div></div></div>
</div>