Slick Forums

Discuss the Slick 2D Library
It is currently Wed Jun 19, 2013 6:58 pm

All times are UTC




Post new topic Reply to topic  [ 8 posts ] 
Author Message
 Post subject: RFE: Sprite Group
PostPosted: Sun Nov 12, 2006 7:48 pm 
Offline
Site Admin
User avatar

Joined: Thu Jan 01, 1970 12:00 am
Posts: 3143
Add a stateful collection of sprites being rendered that can be backed by a vertex array (or VBO) for optimised rendering. This will come with a bunch of restrictions but will allow certain circumstances to render supper quick Smile

Kev


Top
 Profile  
 
 Post subject:
PostPosted: Thu May 03, 2007 8:42 pm 
Offline
Oldbie

Joined: Tue Nov 28, 2006 6:18 pm
Posts: 429
Could you describe what you mean by a VBO (what is that?) and a vertex array?

Sounds like something that could optimize SlickSet's sorted sprite rendering by quite a bit.


Top
 Profile  
 
 Post subject:
PostPosted: Thu May 03, 2007 9:02 pm 
Offline
Site Admin
User avatar

Joined: Thu Jan 01, 1970 12:00 am
Posts: 3143
Vertex Array and VBO (vertex buffer object) are a way of batching drawing geometry (and hence sprites) in OpenGL. If the concept of a Sprite and a SpriteGroup existed then the drawing could be greated optimised into few GL calls (this wouldn't speed it up as much as it sounds, but it could be quite a saving for large numbers of sprites).

However, it's something that needs to be written against OpenGL - it really belongs in the core if it's going to get done. I've been shying away from anything "engine" related - like managed sprites. It's really not the aim of Slick to be an engine.

Kev


Top
 Profile  
 
 Post subject:
PostPosted: Thu May 03, 2007 9:57 pm 
Offline
Game Developer

Joined: Sun Nov 12, 2006 11:18 pm
Posts: 890
Location: Germany
Kev, seems like you would need it (for ROY?).
Why not create some kind of extension of Sprite/SpriteGroup that uses the Callables to protect the VBO stuff?
This way you could get what you want. Or does it need to get into Slick way deeper?

_________________
Right Angle Games | Marte Engine
Back to the past | Star Cleaner | SpiderTrap


Top
 Profile  
 
 Post subject:
PostPosted: Thu May 03, 2007 10:06 pm 
Offline
Site Admin
User avatar

Joined: Thu Jan 01, 1970 12:00 am
Posts: 3143
Don't need it for ROY particularly. Callables are only for users to use, if we were to add it to Slick we'd integrate it fully - like the use of pbuffers or fbos.

Kev


Top
 Profile  
 
 Post subject:
PostPosted: Mon May 04, 2009 5:25 pm 
Offline
Regular

Joined: Tue Mar 03, 2009 11:53 pm
Posts: 123
I suppose this RFE has been frozen...:) But, given the recent discussion about performance, I tried to set up a sort of VBO preallocated sprite engine, but with no success. I have little experience with OpenGL (though I have some with DirectX), and even following the instructions on lwjgl.org I couldn't manage to show anything on screen.

Do you have some clue about setting up a working VBO in Slick's context? I'd like to try to implement this kind of sprites:)

thanks in advance:)

_________________
Carotinho


Top
 Profile  
 
 Post subject:
PostPosted: Tue May 05, 2009 6:28 am 
Offline
Site Admin
User avatar

Joined: Thu Jan 01, 1970 12:00 am
Posts: 3143
I've never used VBOs in a slick context before.

Kev


Top
 Profile  
 
 Post subject:
PostPosted: Tue May 05, 2009 7:45 am 
Offline
Regular

Joined: Tue Mar 03, 2009 11:53 pm
Posts: 123
Hi!

Thanks for answering:) Yesterday I succeeded at building a single lwjgl app with a running interleaved VBO. I was messing with offsets (dear old sizeof). Later I'll try this in Slick.

Thanks:)

_________________
Carotinho


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 8 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group