Java-Gaming.org    
Featured games (81)
games approved by the League of Dukes
Games in Showcase (495)
Games in Android Showcase (114)
games submitted by our members
Games in WIP (563)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  3D and bitmap text in JOGL  (Read 2231 times)
0 Members and 1 Guest are viewing this topic.
Offline shaddam_IV

Junior Member




Java makes me happy the way C# doesn't!


« Posted 2003-12-02 02:57:00 »

Hi all,

What, if anything, are all of you doing to add 3D and/or bitmap text to your JOGL programs?  Normally, this is an OS specific thing.  How are you working around it?

It looks like GLUT might be a possible solution.  If this is the case, do you have to distribute glut.dll with everything?

Thanks,
Shaddam IV

There are 10 kinds of people in the world.  Those that understand binary and those that don't.
Offline pepijnve

Junior Member




Java games rock!


« Reply #1 - Posted 2003-12-02 07:01:47 »

For bitmap text, I made a wrapper for AWT fonts, that renders each character into a separate bitmap. I then just use the technique described in chapter eight of the OpenGL programmer's guide (cfr. section 'Fonts and display lists'
For 3D text you could also use GLF. There's a port of it in one of the nehe lessons. Lesson 15 IIRC.
Offline gregorypierce

Senior Member




I come upon thee like the blue screen of death....


« Reply #2 - Posted 2003-12-02 17:24:55 »

How'd the bitmap/texture text work for you performance wise? I was considering adding that to my engine, but never got around to doing it - spending a lot of time working on tools.

http://www.gregorypierce.com

She builds, she builds oh man
When she links, she links I go crazy
Cause she looks like good code but she's really a hack
I think I'll run upstairs and grab a snack!
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline pepijnve

Junior Member




Java games rock!


« Reply #3 - Posted 2003-12-03 06:13:15 »

I'm not sure about the performance, since I haven't had time to benchmark it yet, but it seems ok.
I implemented the mosaic texture/quads technique too, but I wasn't really happy with the quality I got from that, so I dropped it.
Offline gregorypierce

Senior Member




I come upon thee like the blue screen of death....


« Reply #4 - Posted 2003-12-03 18:06:05 »

Yeah, I did the mosaic method and I wasn't pleased with the limitations and the quality. That's the system I have in place now, but I hate it. I used it to avoid texture memory fragmentation - that's why I was curious about your performance.

http://www.gregorypierce.com

She builds, she builds oh man
When she links, she links I go crazy
Cause she looks like good code but she's really a hack
I think I'll run upstairs and grab a snack!
Offline tom
« Reply #5 - Posted 2003-12-03 22:13:52 »

what quility issues did you have with mosaic method? Don't see why it should give any less quility than any other method.

Offline gregorypierce

Senior Member




I come upon thee like the blue screen of death....


« Reply #6 - Posted 2003-12-04 02:08:07 »

Compositing all of the fonts into one big texture caused some issues when the resulting texture was broken up into mipmaps - halo'ing and such.

http://www.gregorypierce.com

She builds, she builds oh man
When she links, she links I go crazy
Cause she looks like good code but she's really a hack
I think I'll run upstairs and grab a snack!
Offline pepijnve

Junior Member




Java games rock!


« Reply #7 - Posted 2003-12-04 06:01:49 »

Tom: when I use the bitmaps (glBitmap, not textures) my text is very crisp. I was never able to get quite the same result using textures.
Offline tom
« Reply #8 - Posted 2003-12-04 12:44:19 »

ok. I see Smiley

I use the mosaic mothod I think. The font is created in adobe photoshop, then parsed inn and stored in a single texture with each character getting there own rectangle inside the texture. I guess it could be generated by using awt, but I wanted it to be flexible enough to support hand made bitmap fonts. And adobe does nice antialiasing Smiley

It is used by my menus and overlays. I've limited the use of the font so that it is never scaled, and is drawn in screen space. I don't use mipmapping and I disable all filtering. I also make sure that it is properly aligned with the screen, so that the texture is mapped 1:1 to the screen. If I did not do this it looked like crap, because it got scaled and mangled.

But I agree that this method is not an option when using mipmaps.

Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

Dwinin (28 views)
2014-09-12 09:08:26

Norakomi (57 views)
2014-09-10 13:57:51

TehJavaDev (74 views)
2014-09-10 06:39:09

Tekkerue (37 views)
2014-09-09 02:24:56

mitcheeb (57 views)
2014-09-08 06:06:29

BurntPizza (45 views)
2014-09-07 01:13:42

Longarmx (28 views)
2014-09-07 01:12:14

Longarmx (34 views)
2014-09-07 01:11:22

Longarmx (34 views)
2014-09-07 01:10:19

mitcheeb (40 views)
2014-09-04 23:08:59
List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06

List of Learning Resources
by SilverTiger
2014-07-31 11:54:12

HotSpot Options
by dleskov
2014-07-08 01:59:08
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!