[ITK] [ITK-users] Error in itk::BinaryMask3DMeshSource when using Mesh with arbitrary CellDataType

Sepideh's Gmail sepideh.movaghati at gmail.com
Sat Nov 21 20:47:06 EST 2015


Hello, 

I am facing a problem working with itk::Mesh objects. This class is templated on the TMeshTrait which itself is templated on TCellPixelType. 
Since I can define an arbitrary Cell/PointDataType for my mesh, I created an itk::Mesh with CellDataType being std::pair<int,int> without any problem.
However, when I tried to use my mesh type as the OutputMeshType of itk::BinaryMask3DMeshSource filter I got type-casting error. Looking at itkBinaryMask3DMeshSource.hxx source code, I noticed that this filter is initializing Cell data to 0.0, meaning it assumes the CellDataType to always be castable to double (which my std::pair<> type was obviously not>. 

I wonder why this filter is written in away that constrains the available flexibility in itk::Mesh type. 

Thanks for your help in advance.
Regards,
Sepide
_____________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html

Kitware offers ITK Training Courses, for more information visit:
http://www.kitware.com/products/protraining.php

Please keep messages on-topic and check the ITK FAQ at:
http://www.itk.org/Wiki/ITK_FAQ

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/insight-users


More information about the Community mailing list