Java-Gaming.org    
Featured games (79)
games approved by the League of Dukes
Games in Showcase (477)
Games in Android Showcase (107)
games submitted by our members
Games in WIP (535)
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  
  [BUG] TextRenderer broken in 1.1.1 (+Workaround)  (Read 1934 times)
0 Members and 1 Guest are viewing this topic.
Offline Andi

Senior Newbie





« Posted 2009-03-16 22:31:08 »

While the TextRenderer works perfectly in my desktop application, in the applet only some dots are visible. When I want to move the text, it even seems to rotate (EDIT: no, that's right, forget it. NO transformation problem!).
I did not investigate more on this problem yet, I just wanted to ask if it is an already known problem!

Unfortunately I could not find any JOGL applets using the TextRenderer on the web - are there examples?

I tried with appletlauncher with the newest JOGL build. The same JOGL build works perfectly for the Java application.

Slam Soccer 2006 - The free football game
Offline Andi

Senior Newbie





« Reply #1 - Posted 2009-03-16 22:36:17 »

Here is a screenshot how it should look (and how it looks in the desktop application):



Here is the applet to try out (do you also see only some dots?):
(if not loading in fullscreen, reload the webpage, then it should work)

http://home.cs.tum.edu/~wengera/jogl/applet.html

The three source files can be also found at:
http://home.cs.tum.edu/~wengera/jogl/

Thanks for testing!

Slam Soccer 2006 - The free football game
Offline bienator

Senior Member




OutOfCoffeeException


« Reply #2 - Posted 2009-03-16 23:42:51 »

works for me - looks like on the screenshot.

Quote
gl.glClear(GL.GL_COLOR_BUFFER_BIT);
...
renderer2.begin3DRendering();
...
...
...
gl.glOrtho(0, getWidth(), 0, getHeight(), 0, 128);

some ideas:
-ether try clearing the depth buffer too or disable depth testing gl.glDisable(GL.GL_DEPTH_TEST); (I think its enabled by default)
-don't set the near frustum pane to exactly 0. Since you are doing 2d rendering something like gl.glOrtho(0, getWidth(), 0, getHeight(), -1, 1); should work better

(I only took a quick look at your code but it looks like you are currently rendering exactly on the frontpane which could cause clipping problems in general)

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline Andi

Senior Newbie





« Reply #3 - Posted 2009-03-18 10:27:37 »

Thanks for testing and your ideas (your ideas could not solve the problem unfortunately). I noticed, that it works perfectly on Windows XP, but not on my Ubuntu 8.10 (GNOME).
On Ubuntu, this official demo works fine, too: http://download.java.net/media/jogl/builds/archive/jsr-231-webstart-current/TextFlow.jnlp
But when I compile it myself (sources from SVN) and run it, I have the exactly same problems as described above (not in an applet, but in a desktop application). Interestingly, I get the following error when running (not on Windows!).

Quote
18.03.2009 10:23:39 com.sun.corba.se.impl.ior.IORImpl getProfile
WARNUNG: "IOP00511201: (INV_OBJREF) IOR must have at least one IIOP profile"
org.omg.CORBA.INV_OBJREF:   vmcid: SUN  minor code: 1201  completed: No
   at com.sun.corba.se.impl.logging.IORSystemException.iorMustHaveIiopProfile(IORSystemException.java:473)
   at com.sun.corba.se.impl.logging.IORSystemException.iorMustHaveIiopProfile(IORSystemException.java:495)
   at com.sun.corba.se.impl.ior.IORImpl.getProfile(IORImpl.java:334)
   at com.sun.corba.se.impl.encoding.CDRInputStream_1_0.read_Object(CDRInputStream_1_0.java:787)
   at com.sun.corba.se.impl.encoding.CDRInputStream_1_0.read_Object(CDRInputStream_1_0.java:761)
   at com.sun.corba.se.impl.encoding.CDRInputStream.read_Object(CDRInputStream.java:231)
   at com.sun.corba.se.impl.resolver.INSURLOperationImpl.getIORFromString(INSURLOperationImpl.java:120)
   at com.sun.corba.se.impl.resolver.INSURLOperationImpl.operate(INSURLOperationImpl.java:130)
   at com.sun.corba.se.impl.orb.ORBImpl.string_to_object(ORBImpl.java:836)
   at org.GNOME.Accessibility.AccessUtil.getRegistryObject(AccessUtil.java:143)
   at org.GNOME.Accessibility.JavaBridge.registerApplication(JavaBridge.java:1099)
   at org.GNOME.Accessibility.JavaBridge.<init>(JavaBridge.java:364)
   at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
   at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
   at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
   at java.lang.reflect.Constructor.newInstance(Constructor.java:532)
   at java.lang.Class.newInstance0(Class.java:372)
   at java.lang.Class.newInstance(Class.java:325)
   at java.awt.Toolkit.loadAssistiveTechnologies(Toolkit.java:786)
   at java.awt.Toolkit.getDefaultToolkit(Toolkit.java:874)
   at java.awt.Window.getToolkit(Window.java:1170)
   at java.awt.Window.init(Window.java:400)
   at java.awt.Window.<init>(Window.java:438)
   at java.awt.Frame.<init>(Frame.java:419)
   at demos.j2d.TextFlow.main(TextFlow.java:67)

Any idea (Ken?), if this is may be the cause for the problem? What's going wrong?

Slam Soccer 2006 - The free football game
Offline Andi

Senior Newbie





« Reply #4 - Posted 2009-03-18 10:58:10 »

Aaaaah... I tried it with older versions of JOGL:

JSR-231 1.1.0-rc3 - February 14Looks OK (but errors (with errors in .so) in console: [1])
JSR-231 1.1.0 - April 22Looks OK (but error in console: [2])
JSR-231 1.1.1-rc1 - May 7Looks OK (but error in console: like [2])
JSR-231 1.1.1-rc2 - May 24Looks OK (but error in console: like [2])
JSR-231 1.1.1-rc3 - July 4Looks OK (but error in console: like [2])
JSR-231 1.1.1-rc4 - October 9Looks BROKEN[3] (error in console: like [2])
JSR-231 1.1.1-rc5 - October 11Looks BROKEN[3] (error in console: like [2])
JSR-231 1.1.1-rc6 - October 19Looks BROKEN[3] (error in console: like [2])
JSR-231 1.1.1-rc7 - February 16Looks OK (but error in console: like [2])
JSR-231 1.1.1-rc8 - February 22Looks BROKEN[4] (error in console: like [2])
JSR-231 1.1.1 - May 22Looks BROKEN[4] (but error in console: like [2])

[1]: http://paste.ubuntuusers.de/394489/
[2]: http://paste.ubuntuusers.de/394490/
[3]: http://home.in.tum.de/~wengera/jogl/rc4.png
[4]: http://home.in.tum.de/~wengera/jogl/rc8.png

I guess that the rror in the console has nothing to do with the bug (since it works with some versions despite the error message).

I could imaging that some features of the video driver are missing within applets (for example, antialiasing does not work on my nvidia Quadro), and the TextRenderer uses some of these features? That's why it fails?

As a workaround, I can use RC7, but the error should be fixed in the new version of JOGL! Or do you have an idea, which things I have to change so it works with 1.1.1, too? Thanks!

Slam Soccer 2006 - The free football game
Offline Hansdampf

Senior Member


Projects: 3


too offending?


« Reply #5 - Posted 2009-03-18 11:01:27 »

works here, but:
it updates only if I scroll the page or drag a window on top.

And it looks like if(updatecount%2==0)clearTheScreenGrey(); so I see nothing but grey background.

FF on Vista, update12

lots of sillystupid games: http://www.emaggame.com
Offline Andi

Senior Newbie





« Reply #6 - Posted 2009-03-18 11:23:53 »

Thanks, I will test that, too (I guess my code is just too bad. I wrote it quickly just to try out if text rendering works).

Workaround for the Bug (tested with my "serious" application, too):

Use 1.1.1-rc7 instead of 1.1.1.
(Webstart available at: http://home.in.tum.de/~wengera/webstart/jogl-1.1.1-rc7 )


I hope, the bug will soon be fixed.


Slam Soccer 2006 - The free football game
Offline gouessej
« Reply #7 - Posted 2009-03-22 12:30:16 »

Thanks, I will test that, too (I guess my code is just too bad. I wrote it quickly just to try out if text rendering works).

Workaround for the Bug (tested with my "serious" application, too):

Use 1.1.1-rc7 instead of 1.1.1.
(Webstart available at: http://home.in.tum.de/~wengera/webstart/jogl-1.1.1-rc7 )


I hope, the bug will soon be fixed.


I even use a very old version of TextRenderer and I don't reproduce this bug.

Offline Cakey

Junior Member





« Reply #8 - Posted 2009-03-22 17:12:48 »

I dunno what version of text renderer I have but it looked fine to me?

Offline Andi

Senior Newbie





« Reply #9 - Posted 2009-03-28 10:39:13 »

As already said, it works fine on Windows, but it is broken on Linux (Ubuntu 8.10). I tested it with two different computers, having two different NVIDIA video cards.

Slam Soccer 2006 - The free football game
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline gouessej
« Reply #10 - Posted 2009-03-29 10:28:26 »

As already said, it works fine on Windows, but it is broken on Linux (Ubuntu 8.10). I tested it with two different computers, having two different NVIDIA video cards.
Ok I'm under Linux but I have only ATI cards. Does it come from the driver??

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.

Riven (11 views)
2014-07-29 18:09:19

Riven (8 views)
2014-07-29 18:08:52

Dwinin (8 views)
2014-07-29 10:59:34

E.R. Fleming (25 views)
2014-07-29 03:07:13

E.R. Fleming (10 views)
2014-07-29 03:06:25

pw (39 views)
2014-07-24 01:59:36

Riven (39 views)
2014-07-23 21:16:32

Riven (26 views)
2014-07-23 21:07:15

Riven (28 views)
2014-07-23 20:56:16

ctomni231 (59 views)
2014-07-18 06:55:21
HotSpot Options
by dleskov
2014-07-08 03:59:08

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:58:24

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:47:22

How do I start Java Game Development?
by ra4king
2014-05-17 11:13:37

HotSpot Options
by Roquen
2014-05-15 09:59:54

HotSpot Options
by Roquen
2014-05-06 15:03:10

Escape Analysis
by Roquen
2014-04-29 22:16:43

Experimental Toys
by Roquen
2014-04-28 13:24:22
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!