Z Buffering
I''m starting an isometric engine and so far I''ve decided on using isocubes as the base unit (visually looks like a hex tile shape but is tesselated like a diamond tile). For flat tiles (e.g. floor) this reduces to a usual diamond shape but the cube boundaries allow (e.g.) wall segments to be entirely constructed within one tile (instead of using multiple diamond shapes to construct it). I am happy with this currently from a level design perspective.
However, looking forward, I''m thinking about the troubles of layering moving graphics (e.g. players) within the scene specifically when doing highly interactive tasks like walking through doors. The solution presented (often briefly) in the materials I have read online seems to involve careful design of tiles and marking of over-unders.
The problems I see with this approach are that: a) the solution is non-generic so tiles need to be carefully constructed and therefore, b) more work is required, and c) complex 3d shapes would be prohibitively complex.
I was wondering about using a Z-Buffer? Each tile and player sprite could have a Z-Buffer associated with it and at render time, a custom routine could be used to render the sprite when a overlap is detected (simple flag system because floor tiles don''t need this). The Z-Buffer''s would be adjusted for their relative positions in world space and then the routine would draw appropriately.
Problems with this are:
* DirectDraw does not support Z-Buffers and D3D wouldn''t work because the buffers are acting in different spaces (screen versus world).
* I use 3D studio 3 to create my tiles. I can''t work out how to create Z-Buffers for a render.
Does anyone know how to get 3D studio max to output Z-Buffers? If not, are there 3d renderers out there that do? Plus, I''ve found 3DS Max to not be very ''pixel accurate''. Obviously you have to take aliasing off but even then there''s a fair amount of tweaking needed for some tiles.
What are people''s thoughts on my idea in general and is there anything obvious that I''ve missed?
Thanks
Joe
joe@nyrsound.com
Looks more like a API/3ds exporting problem than an isometrc problem to me. I don''t understand what u said about that z-buffer stuff. If u use DirectDraw u must implement some kind of z-buffer on your own (sorting problem). If u use Direct3D8 u can let directx handle that problem (only if u use textures with alpha u get problems). But i am a beginner so ... !
The Z buffer can be an of screen buffer of your own creation
with nothing to do with directX and just do your own blt
routine to check the z buffer before outputing the pixel.
As for 3d max I am not totally sure about the outputing
of the Z buffer but it will probably be under something
called G-Buffer (Geometry Buffer) - I Know this feature
is supported in RayDream Studio.
Hope this helps.
with nothing to do with directX and just do your own blt
routine to check the z buffer before outputing the pixel.
As for 3d max I am not totally sure about the outputing
of the Z buffer but it will probably be under something
called G-Buffer (Geometry Buffer) - I Know this feature
is supported in RayDream Studio.
Hope this helps.
Jonus: It should be a problem common to advanced isometric engine design. The z-buffer is for sub tile interactions rather than tile interactions. D3D won''t help because you are not using it for sub tile geometry (the tile IS the geometry).
MButchers: I thought I''d have to use my own blitting routine. Shame. I still haven''t found anything in 3DS Max to help me out but thanks for the G-Buffer tip.
Joe
MButchers: I thought I''d have to use my own blitting routine. Shame. I still haven''t found anything in 3DS Max to help me out but thanks for the G-Buffer tip.
Joe
Michael Duffy from http://www.studioblue.com/ has tried a software z-buffer for his isometric engine. He strongly discourages it''s use though, due numerous problems - you might be able to find his posts with something like deja.com.
It''s quite some time ago, and was either in the comp.games.development.* or rec.games.programmer newsgroup hierarchy.
BuschnicK
It''s quite some time ago, and was either in the comp.games.development.* or rec.games.programmer newsgroup hierarchy.
BuschnicK
Life would be much easier if I had the source code.blackfish.sourceforge.net
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement