changing graphics modes

BlitzMax Forums/BlitzMax Beginners Area/changing graphics modes

jkrankie(Posted 2005) [#1]
is there any way to change what graphic mode you are in while your program is running? i want to present users with a dialog box where they can change what resolution and weather they want windowed of full screen mode.

if it makes any difference, i'm using bMax1.10 on mac os x

cheers
charlie


Stuart Morgan(Posted 2005) [#2]
To change graphics mode when the program is running I would assume it would be something like this...



But if you change to windowed mode and then change back to fullscreen I get a unhandled memory exception error.

Can anybody tell me if this a bug or am I coding something wrong here?


jkrankie(Posted 2005) [#3]
yep, my program looks similar to that.

i get this error: "2005-06-10 13:09:02.274 boxtest[17583] invalid drawable"

when trying to change to anything, also im starting in windowed mode.


Perturbatio(Posted 2005) [#4]
.
waited far too long to post


Stuart Morgan(Posted 2005) [#5]
waited far too long to post

Is my code correct then? Is it a bug?


Perturbatio(Posted 2005) [#6]
it would appear to be a problem with the graphics command in some manner yes.



I was messing around with it and you can create a fullscreen GL context and switch back to window mode without issue (it does stop rendering the text when you switch to fullscreen for the second time, but that's *probably* a seperate issue).
There is no exception produced using the above.


Yan(Posted 2005) [#7]
...Wot e said...^^^^^^^

Although I didn't have any font problems.


jkrankie(Posted 2005) [#8]
cheers Perturbatio, hadn't realised there was a command called endgraphics

cheers
charlie


Yan(Posted 2005) [#9]
Oh wait, after reading it properly...Not what he said.

The first code sample works perfectly if you set the gl driver first. So probably a bug with the DX7 implementation.



SillyPutty(Posted 2005) [#10]
only the second example works for me

however, on the second interation of the mode change, you cannot see the text in fullscreen mode.


rod54(Posted 2005) [#11]
I can keep clicking on full frame mode (1) and gives new full frame, and it can go to window mode where and if I keep clicking window mode(2) it creates a new window every time but from window mode if I click full frame it exits with out an esc.