Java-Gaming.org    
Featured games (79)
games approved by the League of Dukes
Games in Showcase (475)
Games in Android Showcase (106)
games submitted by our members
Games in WIP (530)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
   Home   Help   Search   Login   Register   
  Show Posts
Pages: [1]
1  Games Center / Featured Games / Re: Quantum - Free RTS on: 2010-08-08 21:26:37
Hi,
I started to optimize the game (using OpenAL for sound, smaller code cleanups). Has someone the changes made by the other people (I think it was feuerkugel in the quantum forum)? I lost them.
bye
Cymric
2  Java Game APIs & Engines / Java 2D / Re: Problems with Swing, OGL, 6uN, 1.6.0 and active rendering on: 2007-12-09 13:08:33
Hi,
obviously, the problem is that the SynchronizedEventQueue was blocked 100% of the time, so only a small amount of the Events was processed. A little sleep solved the problem. I think of a better solution, but not today ;-)
bye
Roland
I have the performance decrease if I open an JInternalFrame (e.g. TrainList), but the main problem is that the GUI with certain configuration no longer reacts on input. The InternalFrame gets rendered to an internal image, I disabled "doubleBuffering" in the  RepaintManagerForActiveRendering, so in the profiler it looks a bit better. With jdk 6uN build 08 and opengl rendering pipeline the problem vanished completely. The framerate in all configuration (directx, opengl, jdk1.6, 6uN) is now always the same (around 50fps).
3  Java Game APIs & Engines / Java 2D / Re: Problems with Swing, OGL, 6uN, 1.6.0 and active rendering on: 2007-12-09 12:40:29
Hello,
perhaps I misunderstood something about the rendering logic. It uses active rendering and all painting in the EDT is denied. So the fix only affects the first painting.

I have the performance decrease if I open an JInternalFrame (e.g. TrainList), but the main problem is that the GUI with certain configuration no longer reacts on input. The InternalFrame gets rendered to an internal image, I disabled "doubleBuffering" in the  RepaintManagerForActiveRendering, so in the profiler it looks a bit better. With jdk 6uN build 08 and opengl rendering pipeline the problem vanished completely. The framerate in all configuration (directx, opengl, jdk1.6, 6uN) is now always the same (around 50fps).
bye
Roland

Good to hear. Although I'd still suggest to disable double buffering
and create BS on the EDT instead of the rendering thread.

Did you see any performance improvements with the fix?

4  Java Game APIs & Engines / Java 2D / Re: Problems with Swing, OGL, 6uN, 1.6.0 and active rendering on: 2007-12-09 00:35:50
Hi,
you were right, the first paint was in the EDT. If I ignore paints in the EDT, it works.
Thank you
   Roland

I'd trace and see what happens there on the first repaint.

Something there goes awry and you actually painting to the
screen, not to your BufferStrategy as you think you do.
Most likely because of a race condition between EDT and your
code disabling double-buffering and creating the BS.

One thing I'd suggest - when you create the BufferStrategy and disable
the double-buffering, make sure you are doing it on the EDT - I think
now you are doing it on the rendering thread.

5  Java Game APIs & Engines / Java 2D / Re: Problems with Swing, OGL, 6uN, 1.6.0 and active rendering on: 2007-12-05 23:33:37
I have added the program and a save game (1.sav, must be put in the same dir as the jar) to sourceforge https://sourceforge.net/project/showfiles.php?group_id=209321  (a new project called freerails2).
If you use the DirectX rendering pipeline you start with a white playfield. Looks like a bug ...

to start the program:
>java -Dsun.java2d.opengl=True -Dsun.java2d.trace=count -jar jfreerails-20071205-2306.jar
select single player, 1.sav and windowed modus
bye
Roland
6  Java Game APIs & Engines / Java 2D / Problems with Swing, OGL, 6uN, 1.6.0 and active rendering on: 2007-12-05 23:00:29
Hello,
I started to optimize freerails. First I only wanted to make the game logic much faster, but now I'm lost in swing  Wink
Using the OpenGL rendering pipeline in 1.6.0_03 or the DirectX rendering pipeline in 1.6.0_10-b08 (from the Java SE 6 Update N site) I have the following problem:
The game works and the fps is around 100, everything works ok, as long as I don't open an internal dialog (of type JInternalFrame), then the whole swing gui responds very slow. The weird thing is that the game still runs at 100fps (but now with maximum cpu load), but e.g. mouse events have a delay of 2-4 seconds.
One thing is that the number of events in the SynchronizedEventQueue rises (from 1-2 events/second to 700events/s). Almost all of this came from revalidate() (see stack trace below). The problem occurs with JLabel.setText(). If I generate all possible JLabels at start (at this point the text can have only some values) and instead return them in getListCellRendererComponent(), the GUI does again responds to mouse actions.
If I don't use the OpenGL rendering pipeline, I still have the many Events, but no GUI response problem.
AND I don't have the problem in 6uN build 08 with the OpenGL rendering pipeline!

Had anyone similiar problems?

bye
 Roland

1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
22  
23  
24  
25  
26  
27  
28  
29  
30  
31  
32  
33  
34  
35  
36  
37  
38  
39  
40  
41  
42  
43  
44  
45  
46  
47  
48  
49  
50  
51  
Stacktrace:
at jfreerails.client.top.SynchronizedEventQueue.postEvent(SynchronizedEventQueue.java:49)
   at java.awt.EventQueue.invokeLater(EventQueue.java:954)
   at javax.swing.SwingUtilities.invokeLater(SwingUtilities.java:1264)
   at javax.swing.JComponent.revalidate(JComponent.java:4796)
   at javax.swing.JLabel.setText(JLabel.java:325)
   at jfreerails.client.view.TrainSummaryJPanel.getListCellRendererComponent(TrainSummaryJPanel.java:99)
   at javax.swing.plaf.basic.BasicListUI.paintCell(BasicListUI.java:195)
   at javax.swing.plaf.basic.BasicListUI.paintImpl(BasicListUI.java:304)
   at javax.swing.plaf.basic.BasicListUI.paint(BasicListUI.java:227)
   at javax.swing.plaf.ComponentUI.update(ComponentUI.java:143)
   at javax.swing.JComponent.paintComponent(JComponent.java:763)
   at javax.swing.JComponent.paint(JComponent.java:1027)
   at javax.swing.JComponent.paintChildren(JComponent.java:864)
   at javax.swing.JComponent.paint(JComponent.java:1036)
   at javax.swing.JViewport.paint(JViewport.java:747)
   at javax.swing.JComponent.paintChildren(JComponent.java:864)
   at javax.swing.JComponent.paint(JComponent.java:1036)
   at javax.swing.JComponent.paintChildren(JComponent.java:864)
   at javax.swing.JComponent.paint(JComponent.java:1036)
   at jfreerails.client.view.TrainListJPanel.paint(TrainListJPanel.java:300)
   at javax.swing.JComponent.paintChildren(JComponent.java:864)
   at javax.swing.JComponent.paint(JComponent.java:1036)
   at javax.swing.JComponent.paintChildren(JComponent.java:864)
   at javax.swing.JComponent.paint(JComponent.java:1036)
   at javax.swing.JLayeredPane.paint(JLayeredPane.java:564)
   at javax.swing.JComponent.paintChildren(JComponent.java:864)
   at javax.swing.JComponent.paintToOffscreen(JComponent.java:5129)
   at javax.swing.RepaintManager$PaintManager.paintDoubleBuffered(RepaintManager.java:1382)
   at javax.swing.RepaintManager$PaintManager.paint(RepaintManager.java:1313)
   at javax.swing.RepaintManager.paint(RepaintManager.java:1128)
   at javax.swing.JComponent.paint(JComponent.java:1013)
   at javax.swing.JComponent.paintChildren(JComponent.java:864)
   at javax.swing.JComponent.paint(JComponent.java:1036)
   at javax.swing.JComponent.paintChildren(JComponent.java:864)
   at javax.swing.JComponent.paint(JComponent.java:1036)
   at javax.swing.JLayeredPane.paint(JLayeredPane.java:564)
   at javax.swing.JComponent.paintChildren(JComponent.java:864)
   at javax.swing.JComponent.paint(JComponent.java:1036)
   at java.awt.Component.lightweightPaint(Component.java:2896)
   at java.awt.Container.lightweightPaint(Container.java:1878)
   at java.awt.GraphicsCallback$PeerPaintCallback.run(GraphicsCallback.java:67)
   at sun.awt.SunGraphicsCallback.runOneComponent(SunGraphicsCallback.java:60)
   at java.awt.Component.paintAll(Component.java:2881)
   at java.awt.GraphicsCallback$PaintAllCallback.run(GraphicsCallback.java:43)
   at sun.awt.SunGraphicsCallback.runOneComponent(SunGraphicsCallback.java:60)
   at sun.awt.SunGraphicsCallback.runComponents(SunGraphicsCallback.java:90)
   at java.awt.Container.paintComponents(Container.java:1865)
   at jfreerails.client.top.GameLoop.run(GameLoop.java:106)
   at jfreerails.launcher.Launcher$1.run(Launcher.java:259)
   at java.lang.Thread.run(Thread.java:619)
Pages: [1]
 

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

The first screenshot will be displayed as a thumbnail.

ctomni231 (34 views)
2014-07-18 06:55:21

Zero Volt (30 views)
2014-07-17 23:47:54

danieldean (25 views)
2014-07-17 23:41:23

MustardPeter (27 views)
2014-07-16 23:30:00

Cero (42 views)
2014-07-16 00:42:17

Riven (44 views)
2014-07-14 18:02:53

OpenGLShaders (33 views)
2014-07-14 16:23:47

Riven (34 views)
2014-07-14 11:51:35

quew8 (30 views)
2014-07-13 13:57:52

SHC (66 views)
2014-07-12 17:50:04
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!