SCIInstitute / Cleaver

A MultiMaterial Tetrahedral Meshing Library and Application
https://cleaver.readthedocs.io
Other
41 stars 18 forks source link

SaveNRRDFile is using AbstractScalarField + ITK Version broken. #46

Open jonbronson opened 7 years ago

jonbronson commented 7 years ago

NRRDTools::saveNRRDFile is now using AbstractScalarField which is in general not guaranteed to be a 3D array of scalar values. This creates a black-box sampling that the user cannot control and needs to be reverted back to either a Concrete FloatField or a possibly a templatized method ScalarField.

jonbronson commented 7 years ago

Function signature restricted back to FloatFields in change f5f02a674da7ac12a25655dc6a1a4ec977884065

The ITK version of the save method is still incorrect, as it's using the geometry bounds of the scalar field rather than the data field. Origin and scale/spacing information is also lost.

jonbronson commented 7 years ago

Fixed sampling size of the ITK version of SaveNRRDFile to properly use dataBounds size instead of geometry bounds size in change 9b6f37f920f95130e3b2c83896d6dbe164b3831c

jonbronson commented 7 years ago

Remaining open issues with ITK Version of SaveNRRDFile:

Lowering priority.