z-buffer? ugly stairway steps

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
LordNaikon
Posts: 164
Joined: Wed May 05, 2004 5:34 pm
Location: Germany Berlin
Contact:

z-buffer? ugly stairway steps

Post by LordNaikon »

i don't know how this effect is called in english so my tries to search of a solution were without success.

Image

i have this ugly effect if i try to set water within my terrain
from a closer view it look's like that.

Image

and far away so

Image

what can i do ? it should be a straight coastal line without these ugly edge
Last edited by LordNaikon on Wed Oct 06, 2004 6:36 am, edited 2 times in total.
q|^.^|p beeing every time friendly to everyone
sys: 2500+Barton 512MB 6600GT WinXP
Peter Müller
Posts: 292
Joined: Sun Mar 14, 2004 5:28 pm
Location: Germany
Contact:

Post by Peter Müller »

don't know how to avoid this. perhaps you could cut off the landscape under the wather.
And then you draw the water first and than the landscape.
http://www.games-forge.de - Die Community für Nachwuchsprogrammierer
LordNaikon
Posts: 164
Joined: Wed May 05, 2004 5:34 pm
Location: Germany Berlin
Contact:

Post by LordNaikon »

I HAVE IT !!

the fullscreen mode iss the rogue ! if i run it in windowed mode i have nice coastal line !!

the 2nd error or strangely thing with the fullscreen mode!
Image
Last edited by LordNaikon on Wed Oct 06, 2004 6:37 am, edited 2 times in total.
q|^.^|p beeing every time friendly to everyone
sys: 2500+Barton 512MB 6600GT WinXP
Peter Müller
Posts: 292
Joined: Sun Mar 14, 2004 5:28 pm
Location: Germany
Contact:

Post by Peter Müller »

Sorry, don't know, what could matter this effect
http://www.games-forge.de - Die Community für Nachwuchsprogrammierer
Marcus
Posts: 2
Joined: Sat May 22, 2004 4:36 pm

Post by Marcus »

Hi, sorry dass ich auf deutsch antworte, aber ich hab keine Ahnung wie ich das mit meinem besch*** englisch ausdrücken soll.
Ich kenne dein problem. Habe ich selber gehabt als ich meine TerrainEngine für OpenGL programmierte. Letztendlich hat nur die erhöhing der Z Buffer tiefe und die erhöhung der Pixeltiefe auf jeweils 32bit abhilfe geschaft.
du kannst es ja mal versuchen, ich bin mir aber nicht sicher es funktioniert, dass es aber im fullscreenmode nicht und im windowed schon funtioniert deutet schon darauf hin.

Marcus
dingo
Posts: 95
Joined: Tue Mar 09, 2004 5:02 am
Location: Brisbane, Australia
Contact:

Post by dingo »

Not following the deutsche 100% but I beleive in English the term would be an Artefact.

And I think it might be to do with the fact that the fullscreen z-buffer and windowed z-buffer are usually set separately.

I'd just double check the setup of the fullscreen mode and it's screen attributes (zbufer, coulour depth, stencil etc)

BTW make sure you have enough resolution in the z-buffer. ie don't include the zbuffer in calcs less than 1. It takes too much of the resolution for stuff near the camera.

BTW you could use the stencil buffer to explictly turn pixels off or on from drawn polys.

Hope that helps
-= Want your C code to control real life robots? www.users.on.net/~symes =-
LordNaikon
Posts: 164
Joined: Wed May 05, 2004 5:34 pm
Location: Germany Berlin
Contact:

Post by LordNaikon »

thx @Marcus & dingo

i was searching for a funktion or a flag in the docu but i don't find them.
i only find a boolean flag how enabled or disabled the zbuffer in

driver->beginScene(...., true, ....) // the second parameter

:? i think you use this funktion so can you tell mell how?
q|^.^|p beeing every time friendly to everyone
sys: 2500+Barton 512MB 6600GT WinXP
Peter Müller
Posts: 292
Joined: Sun Mar 14, 2004 5:28 pm
Location: Germany
Contact:

Post by Peter Müller »

@LordNaikon:
You wrote an terrain engine? Please, let me see!
http://www.games-forge.de - Die Community für Nachwuchsprogrammierer
LordNaikon
Posts: 164
Joined: Wed May 05, 2004 5:34 pm
Location: Germany Berlin
Contact:

Post by LordNaikon »

You wrote an terrain engine? Please, let me see!
NO i don't! i only used the engine included terrain secene node
q|^.^|p beeing every time friendly to everyone
sys: 2500+Barton 512MB 6600GT WinXP
Peter Müller
Posts: 292
Joined: Sun Mar 14, 2004 5:28 pm
Location: Germany
Contact:

Post by Peter Müller »

LordNaikon wrote:
You wrote an terrain engine? Please, let me see!
NO i don't! i only used the engine included terrain secene node
Is the terrain scene node an standard node of the Irrlicht Engine 0.6? Never seen this in the documentation :?
http://www.games-forge.de - Die Community für Nachwuchsprogrammierer
Unarekin
Posts: 60
Joined: Thu Apr 22, 2004 11:02 pm

Post by Unarekin »

Peter Müller wrote:
LordNaikon wrote:
You wrote an terrain engine? Please, let me see!
NO i don't! i only used the engine included terrain secene node
Is the terrain scene node an standard node of the Irrlicht Engine 0.6? Never seen this in the documentation :?
Yes, it is. It's a bit buggy, though.
LordNaikon
Posts: 164
Joined: Wed May 05, 2004 5:34 pm
Location: Germany Berlin
Contact:

Post by LordNaikon »

wow never seen so many quotes at all :P


Code: Select all

video::IImage* iHeightMap = driver->createImageFromFile("terrain.JPG");
video::IImage* iTerrain = driver->createImageFromFile("terrain_texture.jpg");

scene::IAnimatedMesh* iTerrainMesh = smgr->addTerrainMesh("iTerrainMesh", iTerrain, iHeightMap,core::dimension2d< f32 >(100.0f, 100.0f),5000.0f); 
scene::ISceneNode* iTerrainNode = smgr->addOctTreeSceneNode(iTerrainMesh);
q|^.^|p beeing every time friendly to everyone
sys: 2500+Barton 512MB 6600GT WinXP
Peter Müller
Posts: 292
Joined: Sun Mar 14, 2004 5:28 pm
Location: Germany
Contact:

Post by Peter Müller »

Year, actually playing a bit with the ITerrainSceneNode.

@Unarekin:
You call this http://irrlicht.sourceforge.net/phpBB2/ ... php?t=2551 a bit buggy ;)
http://www.games-forge.de - Die Community für Nachwuchsprogrammierer
Unarekin
Posts: 60
Joined: Thu Apr 22, 2004 11:02 pm

Post by Unarekin »

Peter Müller wrote:Year, actually playing a bit with the ITerrainSceneNode.

@Unarekin:
You call this http://irrlicht.sourceforge.net/phpBB2/ ... php?t=2551 a bit buggy ;)
Sure. :)
Peter Müller
Posts: 292
Joined: Sun Mar 14, 2004 5:28 pm
Location: Germany
Contact:

Post by Peter Müller »

What sould the detail map do? There's no difference between using it and setting NULL.
http://www.games-forge.de - Die Community für Nachwuchsprogrammierer
Post Reply