Files |  Tutorials |  Articles |  Links |  Home |  Team |  Forum |  Wiki |  Impressum

Aktuelle Zeit: Do Mai 16, 2024 01:32

Foren-Übersicht » English » English Programming Forum
Unbeantwortete Themen | Aktive Themen



Ein neues Thema erstellen Auf das Thema antworten  [ 4 Beiträge ] 
Autor Nachricht
 Betreff des Beitrags: Amatueur graphics dabbler
BeitragVerfasst: Mo Okt 13, 2003 05:26 
In many pay on-line games the names of the players appear over their heads. The fonts increase and decrease in size as the players move closer or farther away, and they stay perfectly centered. Can anyone point me to some sample code on how this is done in OpenGl. I have tried several approaches on my own, but the results are terribble. Usually the font noticeably jumps in size, and the centering based on character length causes the name to jiggle to the left and right.

David Grouchy


Nach oben
  
Mit Zitat antworten  
 Betreff des Beitrags:
BeitragVerfasst: Mo Okt 13, 2003 09:44 
Offline
DGL Member
Benutzeravatar

Registriert: Mo Sep 23, 2002 19:27
Beiträge: 5812
Programmiersprache: C++
What approaches did you try?I also used fonts over the heads of players in the multiplayermode of a game I wrote and had no problems with the font jumping or jiggling.
I use a normal billboard over the player's head and draw it in 3D.

_________________
www.SaschaWillems.de | GitHub | Twitter | GPU Datenbanken (Vulkan, GL, GLES)


Nach oben
 Profil  
Mit Zitat antworten  
 Betreff des Beitrags:
BeitragVerfasst: Di Okt 14, 2003 03:57 
I was using bitmaped fonts. I wanted to be able to change the text dynamically during play, and this seemed the easiest way. The buildboard sounds like a texture mapped to box, with everything but the letters being transparent. I can see how this would solve all the problems I spoke of.

David Grouchy


Nach oben
  
Mit Zitat antworten  
 Betreff des Beitrags:
BeitragVerfasst: Mi Okt 15, 2003 10:22 
Offline
DGL Member
Benutzeravatar

Registriert: Mi Jul 17, 2002 12:07
Beiträge: 976
Wohnort: Tübingen
Hallo!
In all cases i would use Outline Fonts. You can size, color and texture them. You should only translate over the player model, billboard and draw the text!



Hab ich irgendwelche Fehler gemact? :oops:

_________________
"Du musst ein Schwein sein in dieser Welt, sangen die Prinzen, das ist so 1.0. Du musst auf YouTube zeigen, dass dir dein Schweinsein gefällt, das ist leuchtendes, echtes Web 2.0."
- Hal Faber

Meine Homepage: http://laboda.delphigl.com


Nach oben
 Profil  
Mit Zitat antworten  
Beiträge der letzten Zeit anzeigen:  Sortiere nach  
Ein neues Thema erstellen Auf das Thema antworten  [ 4 Beiträge ] 
Foren-Übersicht » English » English Programming Forum


Wer ist online?

Mitglieder in diesem Forum: 0 Mitglieder und 4 Gäste


Du darfst keine neuen Themen in diesem Forum erstellen.
Du darfst keine Antworten zu Themen in diesem Forum erstellen.
Du darfst deine Beiträge in diesem Forum nicht ändern.
Du darfst deine Beiträge in diesem Forum nicht löschen.
Du darfst keine Dateianhänge in diesem Forum erstellen.

Suche nach:
Gehe zu:  
  Powered by phpBB® Forum Software © phpBB Group
Deutsche Übersetzung durch phpBB.de
[ Time : 0.018s | 17 Queries | GZIP : On ]