[vtkusers] Creating an ImageData from the bounds of a PolyData

Francois Bertel francois.bertel at kitware.com
Tue Dec 8 16:20:03 EST 2009


I just changed the description of vtkImageData::SetDimensions() to
make sure noboby uses it anymore.

The next step would be to mark the misleading SetDimensions() as
deprecated and see how much of VTK has to be changed to use
SetExtent() instead, as dimension is just an information derived from
an ivar, not a ivar.

On Tue, Dec 8, 2009 at 3:44 PM, David Gobbi <david.gobbi at gmail.com> wrote:
> On Tue, Dec 8, 2009 at 1:42 PM, David Gobbi <david.gobbi at gmail.com> wrote:
>
>> The Bounds of an image are
>>
>> bounds = { i_min*Spacing[0] + Origin[0], i_max*Spacing[1] + Origin[1], etc. };
>
> Typo.  I should have typed this:
>
> int extent[6] = { i_min, i_max, j_min, j_max, k_min, k_max };
>
> double bounds[6] = { i_min*Spacing[0] + Origin[0], i_max*Spacing[0] + Origin[0],
>  j_min*Spacing[1] + Origin[1], j_max*Spacing[1] + Origin[1],
>  k_min*Spacing[2] + Origin[2], k_max*Spacing[2] + Origin[2] };
>
>  David
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
>



-- 
François Bertel, PhD  | Kitware Inc. Suite 204
1 (518) 371 3971 x113 | 28 Corporate Drive
                      | Clifton Park NY 12065, USA



More information about the vtkusers mailing list