My Planet and Normal Maps artefacts

Hello guys, my Name is Alex, live in Austria and i try to make a lovely full size Planet using XNA 4.0.

2012 i made the first steps, and now i continue, because i saw Battlescape on Kickstarter :smiley:

Here some Screenshots:
I use the ChunkedLOD approach for Level of Detail, now i have big troubles with the NormalMapping.

Because i generate the Noise on the GPU, and for the normalmap i render the same Heightmap with a higher resolution and pass this Image into the Normal map Shader. When im at the ground ( or LOD-Level > 13) the float precision is not enough i think:

The normalmap shader look like:

float4 NormalPixelShader(in VertexOutput input) : COLOR0
float2 uv = input.UV;

uv.y = 1 - uv.y;

float du = 1.0 / PatchWidth;

float l = tex2D(heightmapSampler, uv + float2(-du, 0));
float r = tex2D(heightmapSampler, uv + float2(du, 0));
float t = tex2D(heightmapSampler, uv + float2(0, du));
float b = tex2D(heightmapSampler, uv + float2(0, -du));

float3 normal = normalize(float3((l - r) * NormalScale, 1.0, (b - t) * NormalScale));
return float4(normal * 0.5 + 0.5, 1.0);


Anybody have an Idea?

sorry for my bad English, i hope you can understand what i mean :))

Best regards


Welcome to the forums, @montify!

It’s great to see new faces around here.

I don’t know a lot about programming at all, but you might want to check out this thread:

It may have what you’re looking for. If not, I’m sure @Navyfish or @JoergZdarsky would be willing to help out!

Thank you for the answer.

I think why i have artefacts on the normal map.

because SimplexNoise on GPU are still fine on higher Lod level.

Are @Navyfish / @JoergZdarsky the developer from Battlescape?

I know this site for many years, very sad that the old blog is offline so many usefull information :sweat:

You mean this one: ?

No, we just all share the same hobbies in doing procedural terrain / planets. The thread which Arkenbrien suggested is indeed very usefull and full of valuable information especially of NavyFish, I’d underline his recommendation to look at it. Will look at your problem.

Thank you for answer guys :wink:
I decided the maxLOD level is 13…

Here is a actual screenshot with traces <3