I have an SDL opengl Mac OSX program and I am having difficulty
drawing a window as I resize it.
I enabled SDL_VIDEORESIZE using the flag SDL_RESIZABLE, but I still
don’t get events AS I resize the window on Mac OSX. I never seem to
get any SDL_VIDEOEXPOSE events either. I need to be sent events with
the new window size as I resize it so that I can redraw the window
properly. During my main event check loop, SDL_PollEvent (&event)
gets no events as I am resizing. One SDL_VIDEORESIZE event only
comes after I stop resizing the window.
Is there a bug or am I not doing something right?
Thanks in advance.
-Trevor Agnitti
http://www.lackeyccg.com
P.S. Is there a searchable archive of this SDL mailing list. The
archive I saw online isn’t searchable.
Trevor Agnitti wrote:
During my main event check loop, SDL_PollEvent (&event) gets
no events as I am resizing. One SDL_VIDEORESIZE event only comes after
I stop resizing the window.
That’s the intended behavior. It works that way on Windows too.
Continuous SDL_VIDEORESIZE events while resizing (as it works on X11)
would be a nice addition, but I’m not sure if it should be enabled by
default as re-setting video mode and redrawing might be too expensive
for some applications. It certainly wouldn’t work very well with the way
SDL_SetVideoMode is currently implemented in the Quartz backend - the
window is destroyed and recreated on each call (AFAIR).
Implement it and submit a patch if you want it badly enough, I suppose.
The part about the resize events shouldn’t be too hard as far as I know
Cocoa and the source of SDL’s Quartz backend, the SetVideoMode part may
be more complicated.
P.S. Is there a searchable archive of this SDL mailing list. The
archive I saw online isn’t searchable.
http://dir.gmane.org/gmane.comp.lib.sdl
http://search.gmane.org/
-Christian
P.S. Is there a searchable archive of this SDL mailing list. The
archive I saw online isn’t searchable.
Also the search button on the SDL website. 
-Sam Lantinga, Senior Software Engineer, Blizzard Entertainment