Java-Gaming.org Hi !
Featured games (83)
games approved by the League of Dukes
Games in Showcase (522)
Games in Android Showcase (127)
games submitted by our members
Games in WIP (589)
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  Game Development / Performance Tuning / Re: Slow JOGL Performance on new Macbook PRO on: 2011-07-04 08:41:09
FYI: 3ms is still slow, and is no indication whatsoever that lines are suddenly accelerated.

Yeah, I figured it's not necessarily that lines are accelerated, it's just that this is essentially a board game so if after all the additional stuff I need to draw it ends up being about 10ms, I'm more than happy with that.  At any rate, your post helped me a lot.  Thank you.
2  Game Development / Performance Tuning / Re: Slow JOGL Performance on new Macbook PRO on: 2011-07-03 18:51:59
Thanks guys!  Your advice really helped.  The problem was indeed far too many calls to glBegin, vertex, and end.  Reading the articles on vertex arrays and buffers led me to another one on display lists and simply switching the sequence of begin, 6 x vertex and end into a single list and calling that multiple times, even within the same transforms, and matrix stack functions, and even still using GL_LINE_LOOP, yielded a render time of around 3 ms!!!!  Now I know I've chosen the simplest, probably least beneficial way of doing this, and have more options up my sleeve for later.

Cheers!
3  Game Development / Performance Tuning / Slow JOGL Performance on new Macbook PRO on: 2011-07-03 09:54:50
Hi,

Newbie here so please be gentle Smiley

I'm trying to build a hex-mapped turn-based game.  I started out with processing and ran into performance problems, rendering the map taking 800ms each time.  I built a stand-along program that uses JOGL 2 that only draws the hex-map and as soon as there are many hexes, it takes a very long time to draw, i.e. 1200ms to draw 1200 hexes (30 rows, 40 columns).
The JOGL display function is really simple, it clears the background, and then draws the hexes in a loop.  Each hex is drawn by using a glBegin(GL_LINE_LOOP) call, followed by 6 glVertex2d for each vertex, and finished off with a glEnd.  I push the matrix at the beginning of each render and at the beginning of each row, and then pop them out respectively.

My machine is a brand new Macbook PRO and I simply don't understand how this is taking so long.  I ran the JOGL Gears demo from JNLP, and maximised the window, and it runs very smoothly.  So, on the assumption that a whole lot more lines and quads are being rendered in the Gears demo, I must be doing something wrong.

Any advice?

Thanks in advance!
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.

xFryIx (62 views)
2014-11-13 12:34:49

digdugdiggy (41 views)
2014-11-12 21:11:50

digdugdiggy (34 views)
2014-11-12 21:10:15

digdugdiggy (30 views)
2014-11-12 21:09:33

kovacsa (53 views)
2014-11-07 19:57:14

TehJavaDev (56 views)
2014-11-03 22:04:50

BurntPizza (55 views)
2014-11-03 18:54:52

moogie (70 views)
2014-11-03 06:22:04

CopyableCougar4 (71 views)
2014-11-01 23:36:41

DarkCart (156 views)
2014-11-01 14:51:03
Understanding relations between setOrigin, setScale and setPosition in libGdx
by mbabuskov
2014-10-09 22:35:00

Definite guide to supporting multiple device resolutions on Android (2014)
by mbabuskov
2014-10-02 22:36:02

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
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!