Rob Posted May 14, 2012 Share Posted May 14, 2012 We created a large modular cave for our game but when im moving around inside the cave random section at bottom and top of the screen seem to dissapear Anyone knows whats causing this? It seems like some kind of occlusion but im not sure I think it is because the polygons of the non tesselated mesh seems to be behind the player while the tesselated polygons are infront of the player any way to fix this? I find it quite strange that it calculates the occlusion on the low poly version instead of the tesselated version Ive attached a screenshot of the issue Link to comment
Rob Posted May 16, 2012 Author Share Posted May 16, 2012 I already fixed it myself by using larger polygons inside the cave, now the polygons still do dissappear every now and then but its barely noticable Link to comment
Guest anet Posted May 17, 2012 Share Posted May 17, 2012 Have you tried to change ZNear value for your player? Does it change anything? See this page https://developer.un...#setZNear_float for reference Link to comment
Rob Posted May 22, 2012 Author Share Posted May 22, 2012 I changed the near clipping in the engine under Tool > Camera but this didnt help Link to comment
Guest anet Posted May 23, 2012 Share Posted May 23, 2012 And do these random holes appear in editor mode? or in game mode? Editor has it's own player and when you change settings under Tool > Camera, you change editor Player's settings. Link to comment
Rob Posted May 23, 2012 Author Share Posted May 23, 2012 Editor mode, I didnt check it ingame mode even after changing the settings the problem persisted Here is another screenshot of the problem on the left you see the dissapearing polygon, so when I turn the tesselation scale slider to 0 the polygon moves out of my view as seen on the right Link to comment
Guest anet Posted May 23, 2012 Share Posted May 23, 2012 I've consulted our CTO. You need to correct a constant in the following shader: data/core/shaders/default/mesh/control_base.shader Replace 1.2f with a greater value. But you should note, that this fix will cause a performance drop. Link to comment
manguste Posted May 24, 2012 Share Posted May 24, 2012 Just to get you the idea of what's going on: you seem to have a very high extrusion that causes this bug. Ulf is right, in most cases tessellation is not used to change the relief this drastically. Maybe it makes sense to make your coarse meshes more extruded. Tessellation is done only for polygons in the view frustum, plus some polygons right outside it so you will not see gaps when tessellated polygons are displaced too far. This constant defines over what distance outside the view frustum polygons are tessellated as well. So basically the higher this value, the longer it takes for the graphics card to draw the frame. Link to comment
Rob Posted May 24, 2012 Author Share Posted May 24, 2012 Yeah we found out the hard way that tesselation isnt good for macro detail, but it gave us a good and easy way to see what we wanted our cave to look like! we already changed the cave mesh so it has the rocky details itselfand the tesselation can be used for micro details to smooth things out Thanks for all the help tho! Link to comment
manguste Posted May 24, 2012 Share Posted May 24, 2012 Good it's cleared up now :) I'll add it to docs, i.e. tessellation material description to avoid further confusion. Link to comment
Recommended Posts