cplusplus
.com
TUTORIALS
REFERENCE
ARTICLES
FORUM
C++
Tutorials
Reference
Articles
Forum
Forum
Beginners
Windows Programming
UNIX/Linux Programming
General C++ Programming
Lounge
Jobs
Forum
Beginners
Text output for OpenGL.
Text output for OpenGL.
May 27, 2011 at 2:58am UTC
CyberBrain
(3)
I'm trying to make a simple game in OpenGL but I can't figure out how to
Output text on the screen and ask for user input.
I've found references online and complicated examples, bu when I tried them out they didn't seem to work.
My question is, is there a simple way to output text and take user input in OpenGL?
May 27, 2011 at 5:21am UTC
xander333
(641)
You should use a library for that...would make it a whole lot easier!
http://www.sfml-dev.org/
http://www.libsdl.org/
I suggest SFML.
Last edited on
May 27, 2011 at 5:28am UTC
May 27, 2011 at 8:09am UTC
hanst99
(2869)
If you're using windows, either wglUseFontOutlines (
http://msdn.microsoft.com/en-us/library/dd374393%28v=vs.85%29.aspx)
or wglUseFontBitmaps (
http://msdn.microsoft.com/en-us/library/dd374392%28v=vs.85%29.aspx)
to create display lists which you can use to draw text.
May 27, 2011 at 7:25pm UTC
CyberBrain
(3)
Do those work with Dev-c++?
May 27, 2011 at 9:02pm UTC
hanst99
(2869)
Dev C++ is just an IDE, which means it has nothing to do with it. So: Yes.
but this:
http://cplusplus.com/forum/articles/36896/
Last edited on
May 27, 2011 at 9:02pm UTC
May 27, 2011 at 9:42pm UTC
brokenbot
(271)
I second sfml. I'm going to be messing around with SDL though too.
http://www.sdltutorials.com
is nice as well. sfml only gives the basics. But fun if you want to hack(don't know if i used that right) it out.
Topic archived. No new replies allowed.