[Insight-developers] Re: Examples/GaussianFilter

Luis Ibanez ibanez@cs.unc.edu
Tue, 10 Apr 2001 14:30:55 -0400


"Miller, James V (CRD)" wrote:
> I tried to build your example 


Glad to know that somebody tried !   :-)



> 
> First some comments on the README.
> 
> I build Fltk using the dsw in the visual_c directory of the download.  It built without issue.
> However, this method does not do any installation.  So you might want to mention that when you run
> CMakeSetup, the include directory and lib directory for Fltk will be marked NOTFOUND and that the
> user should edit the cache file that is presented.

Humm... 
What it means to mark them "NOTFOUND" ?
is that a CMake command ?
What I did is to add the FIND_INCLUDE_DIR and FIND_LIBRARY_DIR 
commands on the CMakeLists.txt files.
The problem I encounter with that is that CMake by default look
in to a "Debug" or "Release" directory, and fltk just use fltk/lib.


 
> It looks like step 2.2 of the README could be done on the 
> repository version of CMakeLists.txt.
> MetaImage is already listed in the SUBDIRS sections anyway. 

That sounds good to me, but MetaImage is essentially for I/O 
while FLTK is GUI.  I assume that the content of /Unsuported
will continue growing. Now we have :  vtk, vispack, MetaImage 
and FltkImageViewer.... and an user may want to use one of 
those independently of the others.



> Perhaps we need a standard way of putting these lines in the
> CMakeLists.txt file and commenting them out.  This would make 
> it easier for someone to add them to their builds since they 
> would only have to uncomment a line.  Or better yet, perhaps 
> a way to specify --with-GaussianFilter to configure and some 
> kind of gui for the windows to select whether these other
> systems should be built.

That will be great !
If CMake can in some way take care of that, it will simplify a 
lot the installation for programs that require unsupported and/or 
extra toolkits. 



> 
> It also looks like step 2.3 of the README could be done in the 
> repository version of CMakeLists.txt.
> Does IView belong under MetaImage?
> 

Well, maybe not, IView is in fact a viewer in itself, and
FltkImageViewer is using several of the classes in there,
specially SliceView and GlSliceView. Probably we could create 
an IView directory at the same level of MetaImage.


> Finally, the sticky points...
> 
> In building FltkImageViewer.lib, VC++ complains that fltkGlDrawer.h 
> cannot be found.  Are all the files checked into the repository?
>

Oops !
That's my mistake.  
Now is checked in. Sorry about that.
I have in fact a set of other files to check in the FltkImageViewer
directory, as soon as they are more stable.


> 
> Before I put FltkImageViewer in the CMakeLists.txt file, I was getting a link error that
> GaussianFilter could not find MetaImageIO.lib or something like that.  So I suspect that there is a
> CMakeLists.txt file problem with GaussianFilter not listing all the libraries that it needs (or where
> to find them).  However, I cannot reproduce this error now due to the above compiler error in
> FltkImageViewer.

That's strange,

MetaImageIO.lib is the result of the CMakeList.txt in
/Unsupported/MetaImage.

It is indicated in GaussianFilter/CMakeList.txt:

- in LINK_LIBRARIES() as MetaImageIO
- in LINK_DIRECTORIES() the directory 
${ITK_BINARY_DIR}/Unsupported/MetaImage
- in INCLUDE_DIRECTORIES() the directory
${ITK_SOURCE_DIR}/Unsupported/MetaImage


Maybe I forgot to include it somewhere else ...
but this is working for me.






Thanks for trying the example.