Not logged in, Join Here! or Log In Below:  
 
News Articles Search    
 


Submitted by Steve Streeting, posted on December 06, 2001




Image Description, by Steve Streeting



Here's a few shots from the Quake3 level rendering of my engine, OGRE (Object-oriented Graphics Rendering Engine).

I know what you're thinking: ok, ok, another Q3A level renderer, yadayadayada... but what makes OGRE a little different is that it's a highly abstracted OO engine which is not designed around BSP scene management, or even indoor rendering - it's designed to be scene oriented rather than level structure oriented, with a class hierarchy dealing with specialisations like using BSPs in an indoor environment. All the features used in the rendering of the Q3 level (material/shader management, geometry buffers, texture loading, curved surfaces) are all generalised and just used by the indoor implementation - this does lead to a bit of conversion overhead as it loads the BSP though.

If you don't want to, you don't have to know that OGRE is using BSPs internally for indoor rendering, just use the top-level interface which is the same for any scene manager, and just give OGRE a hint that you're going to render an indoor scene and it will do all the optimisations internally. Frame rates are pretty good but little optimisation has occurred yet beyond the general culling algorithms so there's room for more. To be honest though I'm pretty pleased with the results - one of the main reasons I implemented a Q3A renderer in the engine is to see whether OGRE's abstracted architecture could handle a large complex scene at a fair speed. I think it does pretty well.

OGRE also abstracts the platform and 3D API - it currently it runs on Win32 under DirectX, but the interface exposes nothing of that - again subclasses deal with the specifics and I've deliberately tried to ensure that the interface will map onto OpenGL easily (probably more easily than DX to be honest! - hmm).

Take a look at http://ogre.sourceforge.net if you like: all source is freely available for non-commercial use.

Cheers
Steve Streeting


[prev]
Image of the Day Gallery
www.flipcode.com

[next]

 
Message Center / Reader Comments: ( To Participate in the Discussion, Join the Community )
 
Archive Notice: This thread is old and no longer active. It is here for reference purposes. This thread was created on an older version of the flipcode forums, before the site closed in 2005. Please keep that in mind as you view this thread, as many of the topics and opinions may be outdated.
 
Spacebender

December 07, 2001, 04:44 AM

Nice to see that someone is using a well-known standard as UML in their documentation :)

Did you use a specific program for the diagrams, or did you draw them by hand in Photoshop or something?

Nice work. I'm also a fan of nice & tidy code, and good documentation (even though it's hard to really write good doc's all the time). Things just get so much easier to read, so why not force yourself into a good habit? :)

 
DooMWiz

December 07, 2001, 04:47 AM

Another post from EGreg: The Blabbering Monkey! ;-)

 
Bunnz

December 07, 2001, 04:52 AM

Looks like the original!!!

Good work!

Have fun
Bunnz

Visit: www.bunnz.com

 
Roch Denis

December 07, 2001, 05:50 AM

Guess a GF with computer know how might not be such a good thing ^_^

 
William van der Sterren

December 07, 2001, 06:58 AM

Steve most likely used Rational Rose (or its "lite" version Visual Modeler which was included with MSVC6Pro) to draw the UML diagrams; Rational Rose uses red lines and pale yellow boxes as a default, unlike most other UML tools :)
See www.rationalsoftware.com

Steve: did you do any roundtrip engineering with Rose? (I'm still looking for an example of a real-world project using 3rd party APIs that is able to benefit from roundtrip engineering with an OO modeling tool).

William

 
d9930380

December 07, 2001, 07:36 AM

You could Try Microsoft's Visio.

 
Gorm Lai

December 07, 2001, 08:37 AM

Or use Together from www.togethersoft.com. When I downloaded it they had a free whiteboard version for download.
It is an OOP tool for Java/C++, with fx. a roundtrip UML editor. Really, really cool. And since it is writteh in java, it also works for us linux geeks.

/Gorm

PS. And no, I am not in any way affiliated with togethersoft.

 
Steve Streeting

December 07, 2001, 08:49 AM

I used Rational Rose, because that's what I use at work. I've also used Select Enterprise and Visio, but despite it's flaws Rose is my favoured tool.

William - I don't use any round-trip engineering for OGRE, I find it a little overbearing in practice. I think modelling works better when it's at the conceptual level rather than using it to document every nuance of the code. I subscibe to the opinion that you should only model enough to explore and document your approach to the problem; when you include all the little implementation details it starts to get so cluttered it obscures the clarity of the conceptual design.

This is just my opinion - one of my projects at work uses so much code generation that you're forced to put everything in the model - this is nice sometimes because the model is always up to date, but sometimes the forced lifecycle of this approach just gets in the way and forces you to model details which normally you'd choose to omit from the model for simplicity.

When I've used reverse engineering to update a model from code, I find it includes lots of unnecessary detail and requires a lot of tweaking to make it behave nicely. I've normally found that it's quicker and more productive to model what you want manually and the results are typically better quality anyway since humans know when to simplify and when not to whilst the parser is pretty dumb.

 
Steve Streeting

December 07, 2001, 08:54 AM

Well hey, you know where the source is! ;)

Glad you like the engine.

 
Steve Streeting

December 07, 2001, 09:05 AM

Re the transparency, this is a result of me not parsing Q3A .shader files yet. OGRE supports all the transparency features needed but doesn't read the material settings in from the .shader files. I'm sorting out this omission at the moment.

I think everybody else has accurately answered the darkness issue you mention! OGRE overbrightens the lightmaps by a factor of 3 before modulating them with the base texture colour. Before I did this it was way too dark. Take a look at the Texture::applyGamma method in the OgreEngine package if you have the source.

 
William van der Sterren

December 07, 2001, 10:14 AM

Thanks for the reply. My experience (Rose, Rhapsody, some trial GDPro, and Software thru Pictures) is:
- round-trip s#cks
--- because you either edit code in an edit box, or you deal with badly formatted source code with ugly markers (except for GDPro);
--- markerless round-trip (GDPro) stops working when you least expect it
--- sooner or later, it barfs when using 3rd party real-world API's or class frameworks (because most of them use some complex macros or compiler extensions).

I probably use Rose in the same way you do (documentation and early sketches), but also use the free Rhapsody because Rose cannot do state machines very well.

William

 
Octopussy

December 07, 2001, 11:22 AM

Even if I didn't try it, Together is said to be a excellent tool.

Alexis.

 
Steve Streeting

December 07, 2001, 12:31 PM

Great, seems like we have the same opinion then!

Is it just me or is 'Software Thru Pictures' one of the most patronising names for a product ever? I just get visions of developers with really fat crayons drawing models with their tongues sticking out the sides of their mouths... ;)

That must be a marketing man's decision - managers must love it ('Hey, I knew software engineering was easy - you just draw pictures!')

Take it easy,
Steve

 
Steve Streeting

December 07, 2001, 12:39 PM

I'd love to get around to an OpenGL implementation, after all I've tried really hard to ensure all the features have OpenGL equivalents and I know how I'd do it, I just don't have the time to implement 2 API implementations at once!

Scripting is currently through Python, although the interfaces are a little out of date.

 
Wilbur

December 07, 2001, 01:40 PM

Hey Thanks Steve I do in fact have Design Patterns. A very good book and it is helping me out tons. I really appreciate your input. I need to find more Software Design books. Things like UML I guess.

 
EGreg

December 07, 2001, 02:23 PM

Where can I download rational rose lite? is it free? :)

-Greg

 
This thread contains 46 messages.
First Previous ( To view more messages, select a page: 0 1 ... out of 1) Next Last
 
 
Hosting by Solid Eight Studios, maker of PhotoTangler Collage Maker.