Drawing Order
I really want to implement drawing order in my node based graphics engine in vsge.
Node based meaning, that I actually have a nodetree, each node containing a pointer to the parent and a children list. This means that each node handles drawing of the children, so the graphics engine only calls the base drawing function (which draws its children, which draw their children).
Now back to drawing order. If I don’t use the z-Buffer which isn’t supported by allegro itself, therefore requires a lot of weird work wit openGL and I wouldn’t be able to use the allegro blitting functions with it.
My idea was to create a list out of the nodetree and sort it by a z-coordinate. I would have to do that every frame though, which can’t be good for performance.
This post was imported from tumblr