Discussion:
Draw 2D text labels over 3D rendering?
Add Reply
Rui Maciel
2010-05-31 00:39:22 UTC
Reply
Permalink
Raw Message
I have a 3D model where I also render some nodes. Now I wanted to draw text near those nodes to
pass it off as labels. What's the best way to get this to work?


Thanks in advance,
Rui Maciel
ferdinan@mseval101.com
2010-05-31 10:11:55 UTC
Reply
Permalink
Raw Message
I have a 3D model where I also render some nodes.  Now I wanted to draw text near those nodes to
pass it off as labels.  What's the best way to get this to work?
Thanks in advance,
Rui Maciel
jbwest
2010-05-31 14:23:22 UTC
Reply
Permalink
Raw Message
Post by Rui Maciel
I have a 3D model where I also render some nodes. Now I wanted to draw
text near those nodes to
pass it off as labels. What's the best way to get this to work?
Thanks in advance,
Rui Maciel
A real simple way would be bitmapped text -- see the GLUT source for
bitmapped text or other text packages.
The advantage is that it's always upright & readable, regardless of the
scene rotation, and quick.

jbw
Tsani
2010-05-31 15:26:24 UTC
Reply
Permalink
Raw Message
Post by jbwest
Post by Rui Maciel
I have a 3D model where I also render some nodes. Now I wanted to draw
text near those nodes to
pass it off as labels. What's the best way to get this to work?
Thanks in advance,
Rui Maciel
A real simple way would be bitmapped text -- see the GLUT source for
bitmapped text or other text packages.
The advantage is that it's always upright & readable, regardless of the
scene rotation, and quick.
jbw
If you want to put the text on the nodes themselves, then you can
capture a font using glReadBuffer(GL_FRONT_LEFT) and do glReadPixels
then use use that to make a texture font. It is not a real simple way
of using fonts, but if you eventually you may want to move around your
data-set without 2D text overlapping all over the place...
Tsani
2010-06-01 13:16:54 UTC
Reply
Permalink
Raw Message
Post by Rui Maciel
I have a 3D model where I also render some nodes. Now I wanted to draw text near those nodes to
pass it off as labels. What's the best way to get this to work?
Thanks in advance,
Rui Maciel
There's a great book on the subject, with many pictures entitled:

Information Visualization: Beyond the Horizon. By Chaomei Chen.
Uwe Kotyczka
2010-06-04 06:53:39 UTC
Reply
Permalink
Raw Message
I have a 3D model where I also render some nodes.  Now I wanted to draw text near those nodes to
pass it off as labels.  What's the best way to get this to work?
Under Windows I have done that in my real apps as well
as in my sample app:
http://home.arcor.de/kotyczka/opengl_en.html

I do not remember the details, but if you wish you can
take a look at the source code. The text labels move
around if the object is rotated.

HTH
Rui Maciel
2010-06-04 12:58:59 UTC
Reply
Permalink
Raw Message
Post by Uwe Kotyczka
Post by Rui Maciel
I have a 3D model where I also render some nodes. Now I wanted to draw
text near those nodes to pass it off as labels. What's the best way to
get this to work?
Under Windows I have done that in my real apps as well
http://home.arcor.de/kotyczka/opengl_en.html
I do not remember the details, but if you wish you can
take a look at the source code. The text labels move
around if the object is rotated.
HTH
Unfortunately it appears that that doesn't apply to my case, as I'm developing a linux app. Damn.


Thanks anyway,
Rui Maciel
Tsani
2010-06-04 23:54:19 UTC
Reply
Permalink
Raw Message
Post by Rui Maciel
Post by Uwe Kotyczka
Post by Rui Maciel
I have a 3D model where I also render some nodes. Now I wanted to draw
text near those nodes to pass it off as labels. What's the best way to
get this to work?
Under Windows I have done that in my real apps as well
http://home.arcor.de/kotyczka/opengl_en.html
I do not remember the details, but if you wish you can
take a look at the source code. The text labels move
around if the object is rotated.
HTH
Unfortunately it appears that that doesn't apply to my case, as I'm developing a linux app. Damn.
Thanks anyway,
Rui Maciel
There's some damned linux code you could use for this somewhere around
here:
http://nehe.gamedev.net/data/lessons/lesson.asp?lesson=13
...
http://nehe.gamedev.net/data/lessons/lesson.asp?lesson=17
u***@web.de
2016-12-13 18:51:14 UTC
Reply
Permalink
Raw Message
Post by Uwe Kotyczka
Under Windows I have done that in my real apps as well
http://home.arcor.de/kotyczka/opengl_en.html
Update: Now it can be found at
http://kotyczka.000webhostapp.com/opengl_en.html
Uwe Kotyczka
2017-01-02 00:10:09 UTC
Reply
Permalink
Raw Message
Post by u***@web.de
Post by Uwe Kotyczka
Under Windows I have done that in my real apps as well
http://home.arcor.de/kotyczka/opengl_en.html
Update: Now it can be found at
http://kotyczka.000webhostapp.com/opengl_en.html
Moved once again to
http://kotyczka.webspace4free.net/opengl_en.html
Uwe Kotyczka
2018-05-30 23:00:00 UTC
Reply
Permalink
Raw Message
Post by Uwe Kotyczka
Post by u***@web.de
Post by Uwe Kotyczka
Under Windows I have done that in my real apps as well
http://home.arcor.de/kotyczka/opengl_en.html
Update: Now it can be found at
http://kotyczka.000webhostapp.com/opengl_en.html
Moved once again to
http://kotyczka.webspace4free.net/opengl_en.html
It seems that free webhosting services do not last very long nowadays.
Now it can be found at
http://kotyczka.byethost24.com/opengl_en.html
Uwe Kotyczka
2018-05-30 23:00:29 UTC
Reply
Permalink
Raw Message
Post by Uwe Kotyczka
Post by u***@web.de
Post by Uwe Kotyczka
Under Windows I have done that in my real apps as well
http://home.arcor.de/kotyczka/opengl_en.html
Update: Now it can be found at
http://kotyczka.000webhostapp.com/opengl_en.html
Moved once again to
http://kotyczka.webspace4free.net/opengl_en.html
It seems that free webhosting services do not last very long nowadays.
Now it can be found at
http://kotyczka.byethost24.com/opengl_en.html

Loading...