Quad-ren 0.2


hessiess

Member
Joined
Apr 26, 2008
Messages
219
After a lot of re-writing, Quad-Ren 0.2 is finished. This release adds a global resource manager to clean up resources, and the capability of rendering 2D polygon meshes, not just quads.

Quad-Ren is now located on sourceforge.net.
CODE

http://quad-ren.sourceforge.net/index.php



About Quad-Ren
Quad-Ren is a resolution independent 2D graphics engine that aims to ease the development of bitmap-based applications, primarily games. Applications using Quad-Ren will function the same regardless of screen resolution or aspect ratio, windowed or fullscreen.

It rectifies many of the issues with older methods of 2D game development such as colour key transparency (which inevitably leads to aliasing) and having to draw sprites in a specific order, which Quad-Ren handles using alpha transparency and layers respectfully. Quad-Ren is programmed in, and usable from C++, with a simple object-oriented API and a small, well documented, easy to edit code base.
 
Is color key transparency implemented yet? I was curious as to how you did it (expand the sprite by 1 pixel, keeping alpha at the expanded pixels to 0?), but don't see it in the code at first glance.
 
Last edited by a moderator:
'White Flame' said:
Is color key transparency implemented yet? I was curious as to how you did it (expand the sprite by 1 pixel, keeping alpha at the expanded pixels to 0?), but don't see it in the code at first glance.
No, colour key transparency is not currently implemented, Il probably add a simple key coulor -> alpha converter and the option of using nearest neighbour filtering, but if you want anti-aliased sprites, you are better off using alpha transparency from the get go.
 
Last edited by a moderator:
Drew a tree sprite for an RPG style demo program I have an idea for, it came out quite well, considering I normally suck at 2D.

CODE
http://www.hessiess.dyndns.org/files/Tree.png
 
Quad-ren 0.3 is now avalable, The primary highlight of this release is that the API is now completely documented, see the API Documentation section. There have also bean some minor feature additions such as an FPS counter. Also, the QRDD file reader/writer and math functions have bean moved into the qrdd_file_handler and qr_math objects, making the API 100% object oriented.Quad-Ren is a resolution independent 2D graphics engine that aims to ease the development of bitmap-based applications, primarily games. Applications using Quad-Ren will function the same regardless of screen resolution or aspect ratio, windowed or fullscreen.It rectifies many of the issues with older methods of 2D game development such as colour key transparency (which inevitably leads to aliasing) and having to draw sprites in a specific order, which Quad-Ren handles using alpha transparency and layers respectfully. Quad-Ren is programmed in, and usable from C++, with a simple object-oriented API and a small, well documented, easy to edit code base.
 
I am at home for a couple of days, it looks like I'll be spending them with quad-ren 0.3 ;-)
More input later on :)
 
Last edited by a moderator:
Looks interesting... :)

Long time ago I created a 2D rally game. Cars like from the old GTA games, running over maps. Would love to make the same thing for Pandora.

Need some time to find out how to get started. Maybe dumb question: can I start on my Vista machine and recompile it later on the pandora device?
 
Last edited by a moderator:
QUOTE

I am at home for a couple of days, it looks like I'll be spending them with quad-ren 0.3 ;-)
More input later on.



Looking forewords to your feedback :)

'HaCo' said:
Looks interesting... :)

Long time ago I created a 2D rally game. Cars like from the old GTA games, running over maps. Would love to make the same thing for Pandora.

Need some time to find out how to get started. Maybe dumb question: can I start on my Vista machine and recompile it later on the pandora device?
I am developing Quad-Ren on Arch Linux, but it should be easy enough to compile on any platform with SDL and OpenGL(though you will have to set up your own build system if GNU automake isn't supported).

It will have to be ported to OGL-ES to run on the Pandora, though this should be pretty easy, as the renderer class is only 315 lines long, and around a quarter of that is OpenGL ;). I will wait until the Pandora development process is better documented before attempting to port it myself.

In the long run I am intending to make Quad-Ren easily support multiple API's, simmaler to Irrlicht, though I will not be adding support for anything platform specific like DX.
 
Last edited by a moderator:
'Hessiess' said:
I am developing Quad-Ren on Arch Linux, but it should be easy enough to compile on any platform with SDL and OpenGL(though you will have to set up your own build system if GNU automake isn't supported).

It will have to be ported to OGL-ES to run on the Pandora, though this should be pretty easy, as the renderer class is only 315 lines long, and around a quarter of that is OpenGL ;). I will wait until the Pandora development process is better documented before attempting to port it myself.

In the long run I am intending to make Quad-Ren easily support multiple API's, simmaler to Irrlicht, though I will not be adding support for anything platform specific like DX.
Thanks Hes for your reply. Just installed Debian on an old laptop of me. Wil play around a bit with gcc and c++ before trying out more...
 
Last edited by a moderator:
'HaCo' said:
'Hessiess' said:
I am developing Quad-Ren on Arch Linux, but it should be easy enough to compile on any platform with SDL and OpenGL(though you will have to set up your own build system if GNU automake isn't supported).

It will have to be ported to OGL-ES to run on the Pandora, though this should be pretty easy, as the renderer class is only 315 lines long, and around a quarter of that is OpenGL ;). I will wait until the Pandora development process is better documented before attempting to port it myself.

In the long run I am intending to make Quad-Ren easily support multiple API's, simmaler to Irrlicht, though I will not be adding support for anything platform specific like DX.
Thanks Hes for your reply. Just installed Debian on an old laptop of me. Wil play around a bit with gcc and c++ before trying out more...


Thanks, have you got any feedback?
 
Last edited by a moderator:
'Hessiess' said:
Thanks, have you got any feedback?
Well, I just found out (using Lazy Foo's tutorial) that I don't need a linux machine to play around with SDL. I will try to do his full tutorial and after that I will try your library. :)
 
Last edited by a moderator:
I promised some feedback :p

QuadRen 0.3:
As the name implies, it renders quads, it does this very well. I've been looking for code like this for, eeuh, several weeks :D ;-)
Simple to understand code, it's currently the minimal rendering abstraction layer every game would need IMO.

Maybe you could have a more advanced sample :p

What's on the roadmap?
Are you going to do more subsystems? Sound? Input abstraction/events?
When is the next release? SVN maybe?

I couldn't get it to link with an Anjuta project, it didn't show up in the list with libs on my system.
Works fine in CodeBlocks 8.02.
I am using Ubuntu 8.10.
 
Last edited by a moderator:
QUOTE

What's on the roadmap?


Vers 0.4 is lickly to be relesed in a couple of weeks, this version is going to include an event system. There is also the bigginings of collision detection system in SVN, though it is unlickly to get into version 0.4.

The demo program was just something which was made quickly to demonstrate the usage of the lib, there will be more advanced demo's when I have some free time and make them.

QUOTE

I couldn't get it to link with an Anjuta project.



Sorry, I don't use Anjuta so can't help.
 
Last edited by a moderator:
Hey, there. I'm wondering: why have separate calls for qr_load_sprite() and the convert_data() procedure? Is there anything else that you'd want to do with loaded data other than convert it for use? Just a question. The project's lookin' nice. I may consider using it instead of C/SDL/OpenGL if you get an event manager going...

Best of luck.
 
Looking good - I'll try and get Lerp ported over to use this, as the rotozooming of surfaces is terribly inefficient!

I've got a couple of queries / requests:

1) Is it possible to tint a sprite? Currently when I do the morph effect in my game, I have a load of particles, which each has its own copy of the particle image (that's manually recoloured per frame) - as you can imagine, that's a bit CPU and memory intensive. Ideally I'd just have a sprite that references a single image, and has an RGBA colour used when rendering. Since you're using GL under the hood, you should just be able to set the vert colours, right?

2) I notice you seem to be using floats - have you considered using fixed point instead (/as an option) - like the way Box2D does - it defines a Float32 type which is switchable between a regular intrinsic float type, and a replacement fixed point implementation that's optimised for use on Arm

Keep up the good work - I'll report back with more feedback when I start implementing this into my engine :)
 
Last edited by a moderator:
'RaYdOg' said:
Hey, there. I'm wondering: why have separate calls for qr_load_sprite() and the convert_data() procedure? Is there anything else that you'd want to do with loaded data other than convert it for use? Just a question.
This was done to make a QRDD -> X converter passable. Though i suppose I could add `don't convert' as a optional param to qr_load_sprite().

QUOTE

Is it possible to tint a sprite? Currently when I do the morph effect in my game, I have a load of particles, which each has its own copy of the particle image (that's manually recoloured per frame) - as you can imagine, that's a bit CPU and memory intensive. Ideally I'd just have a sprite that references a single image, and has an RGBA colour used when rendering. Since you're using GL under the hood, you should just be able to set the vert colours, right?


Currently it is not passable, I left out support for vertex colours because I couldn't think of any use for them, guess I was wrong. Il look into this when I port it to ES, as the whole rendering pipeline will have to be re-implemented in shaders anyway. Using vertex colours should work.

QUOTE

I notice you seem to be using floats - have you considered using fixed point instead (/as an option) - like the way Box2D does - it defines a Float32 type which is switchable between a regular intrinsic float type, and a replacement fixed point implementation that's optimised for use on Arm.


Yes, it is currently 100% float based internally, Il wait until the Pandora has bean released before looking into fixed point optimisation, as the FPU may be fast enough.

I have a basic object-oriented event system working, now it just needs cleaning up and documenting.
 
Last edited by a moderator:
I don't know a lot about lower level programming, but would it be possible for you to implement this engine the way pygame does? So that people could use python to interface with Quad-ren? It seems like it may run faster than pygame which is SDL based. I'm sorry if this is a really stupid request since it's quite possible I don't know what I'm talking about.
 
Last edited by a moderator:
'DasFool' said:
I don't know a lot about lower level programming, but would it be possible for you to implement this engine the way pygame does? So that people could use python to interface with Quad-ren? It seems like it may run faster than pygame which is SDL based. I'm sorry if this is a really stupid request since it's quite possible I don't know what I'm talking about.
I don't know much about languages bindings, but there is certainly a way to do that. You would basically create a special header or something like that, and then Python imports it and calls the Quad-ren functions from a Python program.

You'd just need to make those files [probably not too hard] and remember to bundle the shared library with your program.
 
Last edited by a moderator:
I'm thinking about giving Quad-ren a bit of a try .. one thing I'd like to do is very fast texture animation to a simple billboard vertex .. is this something that Quad-ren can do already? I'm dl'ing the project now, haven't inspect it much, but if anyone knows what the likelihood is of getting good texture animation performance through the use of this library, I'd love to hear about it ..
 
Last edited by a moderator:
Back
Top