[Insight-users] Re: ITK and C++ Builder (Segmentation and GUI), how glue it together?

sandarak at wp.pl sandarak at wp.pl
Thu Apr 28 04:13:46 EDT 2005


Hi Gabriel

Yes. I was trying to get ITK and Builder to work together But with no
final success. It would compile and as far as I remember some simple
examples would work but others would generate Access Violation Error.
So I'm using FLTK to make GUI. Another good thing about using FLTK is
that are many examples of working applications which use it.

- first important thing is that you have to use C++ Builder 5.x.
Builder 6 (as I've read in mialing list) can't compile templated code

- Compiler which comes with C++ Builder 5 is ver 5.5.0 and it won't
compile ITK. You have to download the compiler from Borland site (it's
free) and overwrite files from binary directory of builder with the
ones from the compiler you downloaded (it's version 5.5.1).

- If you want to build itk, you have to use MinSizeRel flag in cmake.
It's ( as I've read on mailng list) because of some restrictions of
borland linker to work with projects bigger than 32 MB (or some value
near 30MBs)

- You have to set "include directories" and "link directories"
manually, because CMake doesn't generate C++ Builder projects.
You also have to add libraries manually to the project

- You also have to change settings of compiler and linker in the
project file to resemble those which Cmake uses. (But Builder will
change them automatically after you open project, which is rather
disastrous and I don't know how to change this behaviour)

What Can I say. Trying to get ITK work together with Builder is a waste
of time and energy in my opinion. And you probably wont get much help
from mailing list because ITK can be compiled using Borland Compiler but
not using C++ builder enviroment.

If it's possible I suggest you migrate to MS Visual 6.0 and use it as
compiler and debug tool. Use FLTK to create GUI. And VTK to visualize.


Regards

Michal

> Hi Michal Postrozny,

> Googling I found your posting regarding C++ Builder joing ITK libraries.
> I was wondering if I got any valuable answer from Insight-List. If so, I
> will really appreciate if you can share the hint.

> Best Regards

> Gabriel
> UBC - ECE Department
> Vancouver, B.C. Canada






More information about the Insight-users mailing list