Sign in to follow this  

Texture artifacts

This topic is 2071 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, I get some artifacts on my texture when it's applied on a small chunk:

[img]http://www.abload.de/img/unbenannt-208z3y.png[/img]
(Normally there would be a sharp edge between blue and brown)

Does someone know why this happens and how to solve it ?

Share this post


Link to post
Share on other sites
Hi,

seems like z-fighting. Are you drawing the same mesh several times?

What are the near/far plane values written on your screen shot? Are they near/far plane values used for your projection matrix?

Cheers!

Share this post


Link to post
Share on other sites
No, its definatly not z-fighting caused by two chunks. It seems that the texture wrapping runs out of precision.

The values on the screenshot are the near /far- planes of the chunks. I calculate it on how close I'm to the surface, because the accuracy gets lost when i take 0.0000001 to 10000. The closer I get to the surface the smaller are the values for the planes.

Share this post


Link to post
Share on other sites
How many times do you wrap your texture? There is a limitation for the maximum texture coordinate values.
Also, your near and far plane values seem very very low.

Best regards!

Share this post


Link to post
Share on other sites
Single-precision floating point (which GPU's use for rendering) only has an precision of up to seven decimal places or so. 0.0000001 is at the very edge of the precision limit, which explains the patterns you are seeing. You simply can't go any closer without switching to double-precision which is not well supported by mainstream 3D API's currently.

Why do you need to get so close to your texture?

Share this post


Link to post
Share on other sites

This topic is 2071 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this