[vtkusers] Mac Qt vtk difficulties

Mike Jackson imikejackson at gmail.com
Fri Aug 18 11:14:57 EDT 2006

On 8/18/06, John Biddiscombe <biddisco at cscs.ch> wrote:
> Dear anyone,
> I have built an app on a MAC 10.4.7, (powerpc I believe), but although
> the vtk window appears correctly and I can interact with it and zoom
> etc, when I adjust sliders and text edits on screen in the gui, the vtk
> window does not ever update correctly and in fact when I switch to
> various special displays, I get nonsense out. I tried tweaking the build
> options for the application to use Carbon on/off, use X on/ off, use
> Cocoa on/off, I,ve used the MAC_OSX_BUNDLE option in cmake as well as
> /usr/X11R6/..GL or framework GL, and although the application runs fine,
> its as though opengl is just knackered inside the app and it doesn't
> work properly.
> Changing various opengl build options sometimes results in an app which
> bombs out on start with "bus error" - not terribly helpful, but probably
> related to the wrong GL calls being sent somehow (mixed framework GL and
> X11R6 GL linkage perhaps)
> Anyway. I am unable to debug the application because this XCode thingy
> seems completely useless and I've given up on it. The same code builds
> and runs fine under linux and windows.
> Does anyone have any idea what I'm talking about and what I might try to
> solve the problem? (Note that I must have rebuilt Qt/VTK and the app in
> question several dozen times with various configurations so I'm tending
> to lean towards the conclusion that macs just don't work very well.)
> thanks
> JB
> --
> John Biddiscombe,                            email:biddisco @ cscs.ch
> http://www.cscs.ch/about/BJohn.php
> CSCS, Swiss National Supercomputing Centre  | Tel:  +41 (91) 610.82.07
> Via Cantonale, 6928 Manno, Switzerland      | Fax:  +41 (91) 610.82.82

I'll get the flame out of the way early.. Macs are perfectly capable..
it might just be the operator.... ;-)

Now.. Sounds like you are using QT with VTK. So this tells us that we
need to compile VTK with CARBON ON, COCOA OFF, X OFF. QT is based on
Carbon which is why we are going to build it this way.

Make sure QT is built correctly, ie for your architecture (PPC or
Intel). If you do not know your arch, then click on the the Blue Apple
Icon in the Upper left corner of the screen. Select "About this Mac".
A new window will pop up that will tell you what type of system you
are running on.

Xcode will do the right thing when compiling in debug mode and only
compile for the arch that you are running on.

Are there any errors in the console
(/Applications/Utilities/Console.app) that might point to something
like a missing library or a library that "Can't be found" ?

What version of QT are you using?

What is a "Special Display"? Is this just another window or this is
some physical device?

If you are building a Native Mac App bundle then you will want to link
against the OpenGL.framework.

Do you have your slots/signals in QT hooked up correctly?

There is an Xcode users list (lists.apple.com) if you have specific
Xcode problems. They are really helpful over there.

If you dislike Xcode, there is always Eclipse with the CDT plugin to
do C++ code.

Mike Jackson
imikejackson _at_ gee-mail dot com

More information about the vtkusers mailing list