The simplest way is to define your pixel type as<br>    class PTXPoint<br>    {<br>        public:<br>            typedef itk::RGBPixel&lt;unsigned char&gt; ColorType; //note: the ptx format uses unsigned chars for color<br>
<br>            ColorType Color;<br>            double Intensity; <br>    };<br><br>And you instantiate a new meshtraits, like<br>typedef itk::DefaultStaticMeshTraits&lt;PTXPoint, 3, 3, double, double&gt; MeshTraits;// since you want the coordinates type is double<br>
<br>then you define your mesh as<br>typedef itk::Mesh&lt;PTXPoint, 3, MeshTraits&gt;    MeshType;<br><br><br><br><br><br><div class="gmail_quote">On Tue, Sep 1, 2009 at 5:27 AM, David Doria <span dir="ltr">&lt;<a href="mailto:daviddoria%2Bitk@gmail.com">daviddoria+itk@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">I was going to do something like this:<br><br>    class PTXPoint<br>    {<br>        public:<br>
            typedef itk::Point&lt;double, 3&gt; PointType;<br>            typedef itk::RGBPixel&lt;unsigned char&gt; ColorType; //note: the ptx format uses unsigned chars for color<br>
    <br>            PointType Point;<br>            ColorType Color;<br>            double Intensity;<br>            <br>    };<br><br>And then create a mesh of the new PTXPoint type:<br>typedef itk::Mesh&lt;PTXPoint, 3&gt;  MeshType;<br>

<br>But that doesn&#39;t make sense, because the dimensionality of the coordinates is already defined inside PTXPoint. I really just want a <br>typedef itk::Mesh&lt;double, 3&gt;  MeshType;<br><br>but where each point in the mesh has a Color and Intensity associated with it. What&#39;s the best way to do that?<br>

<br clear="all">Thanks,<br><font color="#888888"><br>David<br>
</font><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<br>
<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 ITK FAQ at: <a href="http://www.itk.org/Wiki/ITK_FAQ" target="_blank">http://www.itk.org/Wiki/ITK_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.itk.org/mailman/listinfo/insight-users" target="_blank">http://www.itk.org/mailman/listinfo/insight-users</a><br>
<br></blockquote></div><br>