Hello ITK!<div><br></div><div>I am upgrading to the new wonderful 4.1.0, from 3.20.x. I'm having a few teething problems and wondered if you could push me in the right direction.</div><div><br></div><div>In 3.x, you can write transforms to a filename without an extension, but it seems you can't in 4.x. Here's a program to reproduce the exception:</div>
<div><br></div><div><div>#include "itkRigid2DTransform.h"</div><div>#include "itkTransformFileWriter.h"</div><div><br></div><div>using namespace std; </div><div><br></div><div><br></div><div>int main(int, char *[])</div>
<div>{</div><div> typedef itk::Rigid2DTransform< float > TransformType;</div><div> TransformType::Pointer transform = TransformType::New();</div><div> </div><div> itk::TransformFileWriter::Pointer writer = itk::TransformFileWriter::New();</div>
<div> writer->SetInput(transform);</div><div> writer->SetFileName("test.tfm");</div><div> </div><div> try</div><div> {</div><div> writer->Update();</div><div> }</div><div> catch (std::exception& e)</div>
<div> {</div><div> cerr << "caught command-line parsing error" << endl;</div><div> std::cerr << e.what() << std::endl;</div><div> exit(EXIT_FAILURE);</div><div> }</div><div> </div>
<div> writer->SetFileName("test");</div><div> </div><div> try</div><div> {</div><div> writer->Update();</div><div> }</div><div> catch (std::exception& e)</div><div> {</div><div> cerr << "caught command-line parsing error" << endl;</div>
<div> std::cerr << e.what() << std::endl;</div><div> exit(EXIT_FAILURE);</div><div> }</div><div><br></div><div> </div><div> return EXIT_SUCCESS;</div><div>}</div></div><div><br></div><div><br></div>
<div>The code fails in the second try block with the following message:</div><div><br></div><div><div>/path/to/your/ITK/Modules/IO/TransformBase/src/itkTransformFileWriter.cxx:111:</div><div>itk::ERROR: TransformFileWriter(0x10d6468e0): Can't Create IO object for file test</div>
</div><div><br></div><div>I tried to debug the problem with lldb but to no avail.</div><div><br></div><div>Any pointers to dereference would be greatly appreciated.</div><div><br></div><div>Matt Gibb.</div>