@sivan: complexity depends on the restrictions you dont want to have tongue

i.e.:
- Load mesh, if its a new mesh: create a pointer to an empty entity_instancelist. The model saves the pointer. The list_pointer is also registerd for the engine

-on visiblity cheeck for entity:
if its visible:
add the entity to the list of its model

on drawing:
engine runs through all registerd entity_instancelists. On each list, it creates the instance buffers
1 static buffer linking to the mesh
1 dynamic buffer with an entry array. One entry per entity in current instancelist. each entry holds position, rotation, texture.

then these 2 instance buffers are send to the instancing drawcall.

for the entities, you have to write a shader which incoorporates thes instancebuffers. Because the given instance mesh is rendered for each entry. the entry is given to the shader(which param is specified in the instancebuffers)

Basic instancing, restricted to position, rotation, texture

Important: the above is the rough description on doing it in DX11. In DX9 it might be a bit different. But i dont think its TOO diferent.


MY Website with news of my projects:
(for example my current
Muliplayer Bomberman,
GenesisPrecompiler for LiteC
and TileMaster, an easy to use Tile editor)
Sparetime-Development