
Is there any problem if the same function that calls "mainloop" returns a value? Ex.: main :: IO () main = do msg <- startGL putStrLn msg startGL :: IO String startGL = do -- init GLUT -- create window -- declare callback procedures mainloop return "ok"

Andre W B Furtado wrote:
Is there any problem if the same function that calls "mainloop" returns a value? [...]
Well, it depends on your definition of "problem". :-) GLUT.mainLoop never returns! This is a slightly annoying part of GLUT and there are ways around it, but only if you hack GLUT: http://www.google.com/search?q=cache:vRkp-yfjq5Q:web2.iadfw.net/sjbaker1/software/glut_hack.html+glutMainLoop&hl=en (Has anybody a "real" and actual URL of this?) Cheers, S.

Is there any problem if the same function that calls "mainloop" returns a value? [...]
Well, it depends on your definition of "problem". :-) GLUT.mainLoop never returns! This is a slightly annoying part of GLUT and there are ways around it, but only if you hack GLUT:
http://www.google.com/search?q=cache:vRkp-yfjq5Q:web2.iadfw.net/sjbaker1/sof tware/glut_hack.html+glutMainLoop&hl=en
(Has anybody a "real" and actual URL of this?)
Is the following URL the one you're talking about? http://www.sjbaker.org/steve/software/glut_hack.html
participants (2)
-
Andre W B Furtado
-
Sven Panne