Sign in to follow this  
LittleFreak

Engine structures

Recommended Posts

Ive been working on an engine for awhile and I be using a similar structure as the engine shown in the book "3D Game Engine Programming" but as Ive gone along Im not sure if that structure will work completely for me. I was wondering where else I could find engine structure examples. Ive scene 2 books but they use a OpenGL structure and Ive skim through them and found that the openGL engine structure is a bit differnt the directx(which Im using) and I am not quite ready to translate my engine over to openGL as well (planned for later). Any one know so websites or books that discuss directx engine structures. Thank you.

Share this post


Link to post
Share on other sites
The structure of your entire game will vary very little based on the graphics API you're using.

Share this post


Link to post
Share on other sites
I'm sure the structure will very if the OpenGL engines are done in C, as opposed to the DirectX engines being done in C++. Is this the difference?

Share this post


Link to post
Share on other sites
If your not sure about the structure of the engine suiting you, then you must have some ideas about how you think it ought to be, or why its wrong?

there is no incorrect/correct solution to engine design, other than if it adheres to the goals you set for it.

A 3D engine can take many forms, there are literally hundreds on the internet, each with its own unique design, these have been developed by programmers who have come up with their own ideas on how things should be done. I would encourage you to have a go yourself and see what you can come up with, and how well it can work given a pratical application, changing the design when it doesn't work how you would like it too work :)

The best start for engine design is too establish a pipeline, a sequence of events that needs to take place, and in which order; then everything stems from that one source; draw it on a bit of paper if you have to, as long as you have a clear idea how you want it too behave, anything goes. the further you get into the implementation/design to more the original pipeline gets modified; its a gradual process.

Share this post


Link to post
Share on other sites
As noted, your engine's game logic should be entirely unaware of the details of your rendering engine. Nothing in your engine--aside from the rendering--should care about or have any knowledge of what graphics API you are using.

The rendering engine should probably implement some interface that makes sense for your needs, and you should implement it in whichever graphics API you wish to use. If you want to switch to OpenGL, you can simply reimplement that interface with OpenGL and be done with it.

Look at OGRE 3D for a clean example of renderer interfaces.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this