Full screen problems in 10.5

Hi all,

Firstly Hi, my name is Ian Hooper from Perth, Western Australia. I’m new to these forums, joined up because I’ve got a hair-puller of a problem with some of my OpenGL code running in Cocoa on OS X 10.5.

Basically it’s little app which plays Quicktime video in an OpenGL context using the QTOpenGLTextureContextCreate stuff, a little like the QTQuartzPlayer example from Apple, except it does some fancy stuff with the video and supports full screen via initWithFormat:shareContext: and using my own event loop…

All was well under 10.4, but since the upgrade to 10.5 the switching to fullscreen has become pretty unreliable. Occasionally it works as it should, usually I get horrible memory-dump type garbage on screen (like chopped up pieces of my textures), and sometimes I just get a black screen and a lockup. It seems quite random.

So far the frequency of it faulting seems proportional to the amount of work OpenGL is doing (e.g low res video fails less than high res video), so maybe it’s something to do with the opengl context change while there’s still stuff in the GL pipeline?

I realise this is a bit of an unusual/specific problem, but if anyone has any ideas I’m all ears!

(For interest, I’ve tried the new enterFullScreenMode: method in 10.5 but I still get problems. And I’m hoping to stick with the 10.4 way of doing things for backwards compatibility, some of the userbase might object to an OS upgrade!)

If you have multiple threads (the CVDisplayLink thread being an obvious place to get one) I’d guess thread problems. In that case, the OpenGL Profiler’s “break on thread conflict” checkbox might help you out.

Otherwise, there’s not much to say, I think, without more information about the issue… certainly I’ve seen no such thing myself.

In general, I’ve found that you sometimes you need to free and then rebuild your textures and remap them to your geometry…between switching from full screen and “windowed”

Ya, I think thats because there is a new context. I recall having to do that with glut before.

Though, with the new 10.5 calls this no longer appears to be an issue. That is, my app seems happy going from fullscreen back to window mode. Must be shared context magic going on.

Yeah it sounds like a possibility, I’ll give the rebuild-whole-context idea a go and see if that solves it… Cheers for the suggestions.

This topic was automatically closed 183 days after the last reply. New replies are no longer allowed.