Using Ogre for 2D games?

Get answers to all your basic programming questions. No Ogre questions, please!
Post Reply
Posts: 4
Joined: Tue Feb 22, 2005 2:16 pm

Using Ogre for 2D games?

Post by DavidAHouse »

I'm pretty new to Ogre, so forgive if this question has been asked a million times ( a relevant search on the forums didn't return anything ). Has any thought been made to creating some 2D objects for Ogre? I know there is a Rectangle2D object in there, but how well could it be modified to support Sprites? I'm thinking the basics for getting a 2D game up and going would be a Sprite class that can render a 3D Quad to the screen using Ortho projection. Ability to specify coordinates in the (x,y) manner, support alpha transparency, and some form of collision detection. Also modifying the particle system to support 2D, and that might be all.

Just looking for some feedback, especially the kind of 'it can be done, but here is what would need to be written'. Or if its not a good idea, post that as well.

User avatar
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 4011
Joined: Fri Sep 19, 2003 6:28 pm
Location: Burgos, Spain
x 2

Post by Kencho »

You can actually do that right now. Use billboards (the particle system doesn't need to change either) for the textured quads for the sprites, and with a simple orthographic projection you're done. Doing this allows you to do some great effects like the ones you can see in "Castlevania: Symphony of the Night" ("Castlevania: Nocturne in the moonlight" in Japan), where scaling, rotation, blending, merging 2D with 3D, particle systems... were used ;)

User avatar
Posts: 132
Joined: Mon Aug 02, 2004 7:40 am
Location: Austin, Texas

Post by bana »

If you then combined that with ParticleEffects I could imagine some cool cool scenarios. :P
A proud member of the OpenFrag Coding Team.

User avatar
OGRE Retired Team Member
OGRE Retired Team Member
Posts: 3067
Joined: Tue Feb 10, 2004 12:53 pm
Location: The Netherlands
x 1

Post by :wumpus: »

It certainly can be done, and with directdraw being deprecated and al, and direct framebuffer access being slow these days compared to the much faster GPU acceleration, I think using a 3D engine for 2D games isn't a that bad idea :)

EGD Eric
Posts: 41
Joined: Mon Dec 13, 2004 4:07 pm
Location: St. Bruno, Quebec, Canada

Post by EGD Eric »

I'm new to Ogre too, so I can't be any help to DavidaHouse, but I'm thinking of making a 2D game with Ogre too. I once programmed a whole 2D asteroids clone using OpenGL.

Posts: 195
Joined: Mon Jul 19, 2004 11:40 pm
Location: England

Post by Tyn »

Congrats in actually getting the big 1.0 done, it's a small percentage of oepn source software projects that seems to stay about and you've managed it for 2 years so far.
"A common mistake that people make when trying to design something completely foolproof is to underestimate the ingenuity of complete fools."
Douglas Adams
2080: Space Colonization

User avatar
Posts: 335
Joined: Sat Mar 01, 2003 11:21 pm
Location: Idaho, USA

Post by neocryptek »

Tyn wrote:Congrats in actually getting the big 1.0 done, it's a small percentage of oepn source software projects that seems to stay about and you've managed it for 2 years so far.
Its been a bit longer than that ;)


User avatar
Posts: 33
Joined: Mon Aug 09, 2004 4:45 am

Post by Haibokusha »

Ive written a good amount of code to deal with sprites and so forth; OGRE handles everything quite nicely, providing that you play by its rules.

fidel castro
Posts: 5
Joined: Thu Mar 10, 2005 3:57 pm

Post by fidel castro »


interessting topic.
my target is also to build a small 2D JumpNRun Game based on OGRE.

are there any experience with it ?
any samples ? (found nothing in CVS)

would be nice to get some links or additonal tips.

@DavidAHouse: any screenshots from your project ?

thx and greez


Posts: 1
Joined: Fri Apr 08, 2005 6:18 am

Post by Rubinstein »

Watch out for Daimonin, it's a 2D isometric game currently ported to use Ogre.
I've heard the new client is already available in CVS, not yet playable though.
There are even some Daimonin related articles here in the Forum...

Post Reply