[Insight-users] Problem on VC compiler

Luis Ibanez luis . ibanez at kitware . com
Thu, 15 May 2003 23:17:27 -0400


Hi Iajesse,

The problem is that RAW is not a file format.
So the ImageFileReader doesn't know what to do
with it.  Please a header for your raw file. You
can use MetaImage, GIPL and VTK for example in
order to create a pair of files : Header + Raw data.


Regards,


  Luis



----------------
iajesse wrote:
> Hi Luis,
>  
> I can compile the example "Image2" now,but I can't run it,I only mod two 
> plaxes, because I use 3D dataset.and the type is raw.
>  
> !   const unsigned int             Dimension = 2;
> with   const unsigned int             Dimension = 3;
>  
> 2   const char * filename = argv[1];
>   reader->SetFileName( filename); 
>  
> with
>     const char * filename = argv[1];
>   reader->SetFileName( "E:\\ITKtem\\S1.raw");
>  
> What should I try next?
> 
> 
> 
> */Luis Ibanez <luis.ibanez@kitware.com>/* wrote:
> 
> 
>     Hi Iajasse,
> 
>     The Examples are built by default as long
>     as at configuration time you enable
> 
>     BUILD_EXAMPLES in the CMake interface.
> 
>     The executables of the examples will be
>     created at the same time that the basic
>     ITK libraries are created. That is, when
>     you built ITK you will get both the libraries
>     and the executables of the examples.
> 
>     You will find the executables in the subdirecotry
> 
>     bin/release
>     bin/debug
> 
>     of the Binary directory you provided to CMake
>     for building ITK.
> 
>     ----
> 
>     If what you want is to build an example
>     independently, then you simply need to
>     modify lightly the CMakeLists.txt file
>     that you used for HelloWorld.cxx.
> 
>     Just search/replace "HelloWorld" for
>     "Image2". Then put this CMakeLists.txt
>     file along with Image2.cxx in one external
>     directory, run CMake on them and built it.
> 
>     ! It will be exactly the same process you just
>     did for HelloWorld.
> 
> 
> 
>     Regards,
> 
> 
>     Luis
> 
> 
> 
>     --------------
>     iajesse wrote:
>      > Thanks for your help,
>      >
>      > The HelloWorld" can run successfully now,but when I want to know
>     how can
>      > I use Examples in my project? For example, I want to use Image2 of
>      > Examples to read the dataset. How to creat the project with itk?
>      >
>      >
> 
> 
> ------------------------------------------------------------------------
> *Do You Yahoo!?*
> "相见不如聊天!不出门一样面对面!网络摄像头对对派送中~赶快用你的雅虎电邮 
> 帐号参与吧…… 
> <http://cn.rd.yahoo.com/mail_cn/tag/?http://cn.messenger.yahoo.com/>