<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#FFFFFF">
Hi Vladimir,<br>
<br>
Thanks for your efforts. Definitely looking forward to using MINC
with ITK and decided to give it a try today, but get compiler
errors:<br>
<br>
InsightToolkit-4.1.0/Modules/External/minc/volume_io/Prog_utils/time.c:
In function 'current_cpu_seconds':<br>
InsightToolkit-4.1.0/Modules/External/minc/volume_io/Prog_utils/time.c:85:
error: expected '=', ',', ';', 'asm' or '__attribute__' before
'first'<br>
InsightToolkit-4.1.0/Modules/External/minc/volume_io/Prog_utils/time.c:85:
error: 'first' undeclared (first use in this function)<br>
InsightToolkit-4.1.0/Modules/External/minc/volume_io/Prog_utils/time.c:85:
error: (Each undeclared identifier is reported only once<br>
InsightToolkit-4.1.0/Modules/External/minc/volume_io/Prog_utils/time.c:85:
error: for each function it appears in.)<br>
InsightToolkit-4.1.0/Modules/External/minc/volume_io/Prog_utils/time.c:86:
error: 'clock_t' undeclared (first use in this function)<br>
InsightToolkit-4.1.0/Modules/External/minc/volume_io/Prog_utils/time.c:86:
error: expected ';' before 'current'<br>
InsightToolkit-4.1.0/Modules/External/minc/volume_io/Prog_utils/time.c:97:
error: 'current' undeclared (first use in this function)<br>
make[2]: ***
[Modules/External/minc/CMakeFiles/ITKIOMINC.dir/volume_io/Prog_utils/time.c.o]
Error 1<br>
make[1]: *** [Modules/External/minc/CMakeFiles/ITKIOMINC.dir/all]
Error 2<br>
make: *** [all] Error 2<br>
<br>
It seems like time.h is not getting included because HAVE_SYS_TIME_H
and HAVE_UNISTD_H are defined, but TIME_WITH_SYS_TIME is not, even
though my system has both sys/time.h and time.h. If I comment out
the pre-processing directives so that both get included the code
compiles with warnings:<br>
<br>
InsightToolkit-4.1.0/Modules/External/minc/test/../ezminc/minc_io_exceptions.h:
In constructor 'minc::generic_error::generic_error(const char*, int,
const char*, int)':<br>
InsightToolkit-4.1.0/Modules/External/minc/test/../ezminc/minc_io_exceptions.h:31:
warning: declaration of 'code' shadows a member of 'this'<br>
InsightToolkit-4.1.0/Modules/External/minc/test/../ezminc/minc_io_exceptions.h:31:
warning: declaration of 'msg' shadows a member of 'this'<br>
InsightToolkit-4.1.0/Modules/External/minc/test/../ezminc/minc_io_exceptions.h:31:
warning: declaration of 'line' shadows a member of 'this'<br>
InsightToolkit-4.1.0/Modules/External/minc/test/../ezminc/minc_io_exceptions.h:31:
warning: declaration of 'file' shadows a member of 'this'<br>
InsightToolkit-4.1.0/Modules/External/minc/test/itkMINCImageIOTest.cxx:
At global scope:<br>
InsightToolkit-4.1.0/Modules/External/minc/test/itkMINCImageIOTest.cxx:44:
warning: 'void RandomPix(vnl_random&, double&)' defined but
not used<br>
<br>
Unfortunately linking fails (full text in attachment):<br>
<br>
../../../../lib/libITKIOMINC-4.1.a(minc_1_rw.cpp.o): In function
`minc::minc_1_writer::open(char const*,
std::vector<minc::dim_info, std::allocator<minc::dim_info>
> const&, int, nc_type, int)':<br>
minc_1_rw.cpp:(.text+0x2633): undefined reference to `H5Iget_type'<br>
../../../../lib/libITKIOMINC-4.1.a(minc_1_rw.cpp.o): In function
`minc::minc_1_reader::open(char const*, bool, bool, bool)':<br>
minc_1_rw.cpp:(.text+0x2c15): undefined reference to `H5Iget_type'<br>
../../../../lib/libITKIOMINC-4.1.a(netcdf_convenience.c.o): In
function `miclose':<br>
netcdf_convenience.c:(.text+0x1300): undefined reference to
`H5Iget_type'<br>
../../../../lib/libITKIOMINC-4.1.a(netcdf_convenience.c.o): In
function `miopen':<br>
netcdf_convenience.c:(.text+0x18f1): undefined reference to
`H5check_version'<br>
netcdf_convenience.c:(.text+0x1929): undefined reference to
`H5check_version'<br>
../../../../lib/libITKIOMINC-4.1.a(hdf_convenience.c.o): In function
`hdf_access':<br>
hdf_convenience.c:(.text+0x50): undefined reference to
`H5Eauto_is_v2'<br>
hdf_convenience.c:(.text+0x69): undefined reference to
`H5Eget_auto2'<br>
hdf_convenience.c:(.text+0x74): undefined reference to
`H5Eset_auto2'<br>
... <snip hundreds of lines> ...<br>
<br>
Regards,<br>
Steven<br>
<br>
On 03/21/12 17:20, Vladimir S. FONOV wrote:
<blockquote cite="mid:4F6A4609.1010007@gmail.com" type="cite">Hello
Everybody,
<br>
<br>
<br>
I have managed to create an External module for ITKv4 to add MINC1
and MINC2 io support.
<br>
<br>
Unfortunately installation requires tweaking CMake/UseITK.cmake
<br>
<br>
So, for those who are interested in trying it out:
<br>
after obtaining sources of ITKv4, apply provided patch ( it adds
minc file format to the list of recognized formats) and clone minc
into external module directory:
<br>
<br>
<br>
patch < add_minc_file_format.patch
<br>
cd Modules/External/
<br>
git clone git://github.com/vfonov/minc.git
<br>
<br>
<br>
To compile you would need to have netcdf library installed in the
system, module will use HDF5 bundled with ITK.
<br>
<br>
As you can see the whole minc project is inserted as a module, if
you think that it would be better idea to have only ITK - wrapper
interface in the module let me know.
<br>
<br>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_____________________________________
Powered by <a class="moz-txt-link-abbreviated" href="http://www.kitware.com">www.kitware.com</a>
Visit other Kitware open-source projects at
<a class="moz-txt-link-freetext" href="http://www.kitware.com/opensource/opensource.html">http://www.kitware.com/opensource/opensource.html</a>
Kitware offers ITK Training Courses, for more information visit:
<a class="moz-txt-link-freetext" href="http://www.kitware.com/products/protraining.php">http://www.kitware.com/products/protraining.php</a>
Please keep messages on-topic and check the ITK FAQ at:
<a class="moz-txt-link-freetext" href="http://www.itk.org/Wiki/ITK_FAQ">http://www.itk.org/Wiki/ITK_FAQ</a>
Follow this link to subscribe/unsubscribe:
<a class="moz-txt-link-freetext" href="http://www.itk.org/mailman/listinfo/insight-users">http://www.itk.org/mailman/listinfo/insight-users</a>
</pre>
</blockquote>
<br>
<p></p>
<p>The information in this e-mail is intended only for the person to whom it is<br>
addressed. If you believe this e-mail was sent to you in error and the e-mail<br>
contains patient information, please contact the Partners Compliance HelpLine at<br>
http://www.partners.org/complianceline . If the e-mail was sent to you in error<br>
but does not contain patient information, please contact the sender and properly<br>
dispose of the e-mail.</p></body>
</html>