[SOLVED] Random pixel flickering on model bug

I noticed pixels flickering on a model when moving the camera. Since I could not find the bug / reason for it myself I made up a small demo, where the bug happens (at least on my machine, see screenshot).

Anybody knows why this is happening?

Download: PixelFlickerBug.rar

That is old bug like same another users have problem with sphere earth with red line or pixel flickering.

That is why I recommend you need to use DesktopGL version.

SharpDX is okay for Windows 7.
SharpDX is not okay for Windows ( 8 ?? and ) 10.

I made a second version starting from the Visual Studio MonoGame DesktopGL template.

I copied the effect, model and the Game1.cs (concatenated “GL” to the namespace).

Modified the effect to have this at the top:

#if OPENGL
    #define SV_POSITION POSITION
    #define VS_SHADERMODEL vs_3_0
    #define PS_SHADERMODEL ps_3_0
#else
    #define VS_SHADERMODEL vs_4_0_level_9_1
    #define PS_SHADERMODEL ps_4_0_level_9_1
#endif

The flickering is still there… :confused:

Download: PixelFlickerBugGL.rar

Yes I have tried - I found that model has issue ( I try Blender with new cube and flip normal inside. Than I check if pixel doesn’t flicker.

But I don’t know if you have sandbox.fbx has many vertices you should make 8 vertices - if it doesn’t flicker. But I have tried. Nothing pixel flickering.

You can try models by Blender and It has fbx binary 7.4 version. I think MonoGame has bug because latest version of fbx binary 7.5. I will check if it doesn’t work.


It looks fine for me. I think sure you need export from Blender ( Fbx binary 7.4 )

I think you found the issue. The model is maybe mesed up. I will try to fiddle around with it in blender a bit…

fiddle? No it is binary of fbx binary 7.4

  1. Create cube!

  2. switch edit mode!

  3. Change Vertices to Face!

  4. Leave all face of cube!

  5. Select face you would like and delete face!

  6. Select all face and flip normal to inside or outside if you like!

  7. Export selected model to fbx binary 7.4!

  8. Open Pipeline Tool and rebuild again!

  9. Build your Game of MonoGame and check - if it doesn’t flicker.

That is easy steps!

1 Like

I think the model consists of small square polygons whose vertices are not shared with the neighbours. So I guess what makes it flicker in the end are precision errors of the vertices which are close together.

I have to find out how to texture the model, I am a blender noob :slight_smile:

It is really easy You know if you are blender noob than you can find easy explanation like Blender Artist Community - Or Getting started of Blender!

It is example https://www.youtube.com/watch?v=B-O8F1wqonQ

And You will know I have captured about UV mapping = it is no texture - Like it is easy without texture. If you want add texture than you can export UV Layout and export model fbx than you can paint with Substance Painter or open your favorite paint editor like Gimp or PhotoShop.

Than you can load texture into Blender and more… Good luck!

https://en.wikibooks.org/wiki/Blender_3D:_Noob_to_Pro/What_is_a_Mesh%3F
https://docs.blender.org/manual/en/dev/getting_started/index.html

Youtube
Good explanation!

If you listen youtube than you will know how do you step to step. And more tutorials how do you understand…

1 Like

So I found out, there is an option in Blender to remove those duplicate vertices.

Here is the model which no longer should have the flickering issue: sandbox.fbx

Now did you check? No pixel flickers?

Good! Now it is resolved? And did you try with DirectX ( WindowsDX )?

Yes, I tried both DesktopGL and DirectX. Both don’t have flickering any longer with the repaired model. :slight_smile: