CaseyB
04-04-2006 19:06:32
I am having an issue where groups of tiles will flicker. It looks as though they are switching between visible and not each frame. I took two screen shots to show what it looks like.
As you can see, even when the tiles that are flickering are visible, it doesn't fill in completely. Where should I begin looking for an answer to this issue?
Crashy
04-04-2006 19:40:15
Any shadow mode used?
Could you also post the terrain cfg file? And your computer specs?
CaseyB
04-04-2006 20:00:41
I do use Additive Stencil Shadows. I am running it on a Dell XPS600 P4 3.56GHz with dual GeForce 6800's each having 256MB. Here is my terrain config file:GroupName=PLSM2
Width=4
Height=4
Data2DFormat=HeightField
LandScapeFileName=Cleveland
FileSystem=../Media/materials/textures
NumTextureFormatSupported=19
TextureFormatSupported0=Image
TextureFormatSupported1=BaseTexture
TextureFormatSupported2=Splatting
TextureFormatSupported3=Splatting5
TextureFormat=Image
ImageFilename=ClevelandTexture
ScaleX=15000
ScaleY=1000
ScaleZ=15000
Deformable=no
VertexCompression=yes
VertexProgramMorph=yes
VertexNormals=yes
NumMatHeightSplat=4
MaterialHeight1=15
MaterialHeight2=50
SplatFilename0=splatting_sand.png
SplatFilename1=splatting_grass.png
SplatFilename2=splatting_rock.png
SplatFilename3=splatting_snow.png
# where to put camera on load.
BaseCameraViewpoint.x=935.0f
BaseCameraViewpoint.y=24000.0f
BaseCameraViewpoint.z=-432.0f
Baselookat.x=0.0f
Baselookat.y=0.0f
Baselookat.z=0.0f
Falagard
04-04-2006 20:51:40
Might wanna try disabling stencil shadows and find out if that's the prob.
CaseyB
04-04-2006 21:15:08
Nope, it still flickers, I am going to try going through and disabling things one by one and see if I can find it.
CaseyB
04-04-2006 21:34:27
When I set VertexProgramMorph=no OR VertexCompression=no OR VertexNormals=no I get this error. But it goes away in some cases
-----------------------------------
Details:
-----------------------------------
Error #: -2005530516
Function: D3D9RenderSystem::_render
Description: Failed to DrawPrimitive : Invalid call.
File: ..\src\OgreD3D9RenderSystem.cpp
Line: 2458
Stack unwinding: <<beginning of stack>>
Here's what it doesVPM | VC | VN | Result
------------------------
no | no | no | works
no | no | yes | works
no | yes | no | error
no | yes | yes | error
yes | no | no | error
yes | no | yes | error
yes | yes | no | error
yes | yes | yes | works
But the combinations that work still flicker.
tuan kuranes
05-04-2006 11:59:29
Are you sure you did disable shadows before new tests ?
Does demo using same terrain does that too ?
Does other texture mode give same results ?
Are you using multiples camera ?
CVS or SDK ?
CaseyB
05-04-2006 16:53:34
I did disable shadows and it still flickered, so I enabled them again.
I can't run the PLSM demo, it keeps crashing with this error-----------------------------------
Details:
-----------------------------------
Error #: 7
Function: TextAreaOverlayElement::setFontName
Description: Could not find font BlueHighway.
File: ..\src\OgreTextAreaOverlayElement.cpp
Line: 337
Stack unwinding: <<beginning of stack>>
What do you mean by texture mode?
I only have 1 camera and I am using he CVS version of Ogre and the PLSM.
I will disable shadows and run through my previous tests again.
CaseyB
05-04-2006 17:08:18
Ok, here's what I foundwhen I redid my tests with shadows disabled:VPM | VC | VN | Result
------------------------
no | no | no | works, Flickers
no | no | yes | works, Flickers
no | yes | no | error
no | yes | yes | error
yes | no | no | error
yes | no | yes | error
yes | yes | no | error
yes | yes | yes | works, Flickers
Falagard
05-04-2006 18:02:07
I got the same bluehighway error btw.
CaseyB
05-04-2006 20:07:31
I went through the overlays and changed all occurances of BlueHighway to Arial and then added the arial.ttf file to the filesystem and it crashed with the same error, except it said Arial instead.
Falagard
05-04-2006 20:15:07
I commented out the overlay creation code..
//Overlay *o = OverlayManager::getSingleton().getByName( "PagingLandScape2/DebugOverlay" );
//o-> show();
//showDebugOverlay(true);
and then checked anywhere isVisible() was being called on the overlay and always returned false:
if ( false && OverlayManager::getSingleton().getByName( "PagingLandScape2/DebugOverlay" ) -> isVisible())
CaseyB
05-04-2006 20:44:48
Ok, using your suggestions I got it to run and I pointed it at my cfg and everything and there was no flickering!
Falagard
05-04-2006 20:54:44
Well, that's sorta good news.
tuan kuranes
06-04-2006 08:20:58
blue highway is ogre cvs font change (license problem), Ogre 1.2rc2 will not have any other font.
christianboutin.com
10-04-2006 01:42:58
Anyone found out anything more on the problem (other than it just went away by itself)?
I got the same bad flickering problem. It seems the terrain segment that are rendered when the program start will be paged in/out correctly but everything outside that perimeter will either be paged out or will flickering on and off every frame.
It happens in my own code, not in the terrain viewer strangely. Well, I'll start back with the viewer and work my way down. If anyone did find out what causes that I'd appreciate to hear about it though. Would save me some searching
Cheers!
C.
christianboutin.com
10-04-2006 02:11:19
I've found an explanation for my own blinking/flickering problem. I have 2 cameras in my scene. If both cameras are within range of a terrain section it will be on, if both cameras are out of range of a terrain section it will be off, if only 1 camera is within range of a terrain section it will blink/flicker. That's why I thought terrain sections that were originally loaded behaved properly : these tiles were always within range of camera 1.
tuan kuranes
10-04-2006 08:09:14
Can you achieve to reproduce it in demo ?
CaseyB
10-04-2006 16:14:09
Sorry for not getting back to you, it's been a busy weekend! But that was exactly the problem I had! I couldn't explain it as well as you though!
I had the main player camera and a second that I used as a "Minimap." I accidentally placed the minimap camera 200 units away from the player in the X direction and I had issues with flicker. When I was going through my code to try to track down the flickering, I noticed my error and fixed it along with moving some code around. Just general cleaning up and when I recompiled the flickering went away!
CaseyB
12-04-2006 20:27:41
tuan kuranes
13-04-2006 09:23:54
thanks for the clear report.
I will try to reproduce and fix the bug.
CaseyB
13-04-2006 16:08:28
Let me know of there is anything else that I can do to help!
tuan kuranes
21-04-2006 21:42:40
fixed in cvs and source pack.