Jump to content

Hair-like struktures and noise


Recommended Posts

I'm rendering some hair-like geometry. They are just 4 point open polygon curves copied to a sphere and they have a width attribute going from 0.006 at the root to 0.001 at the tip. They also have a black to white ramp applied via point attributes which then get referenced by a constant shader. The camera moves slowly.

When I render this setup, I get noise at the tips of each "hair", which becomes even worse when applying DOF.

I tried rendering with super sample up to 7x7, jitter down to 0 and shading rate up to 2 in various combinations, but the noise is always there.

Here is a short closeup (tga) sequence of the noise with and without DOF.

Any ideas how to get rid of this?

Thanks!

Achim

Link to comment
Share on other sites

two guesses of mine :huh: :

i) the ends are just too fine and we run into sampling problems of very fine structes: increase the width to .002 and apply a slight transparency ramp on the tips of the hair like structures -> the tips should be transparent. The effect should be similar to very fine ends, but the rendering should have less flickering.

ii) maybe somewhere in the shader you have a sampling of the ramp. usually a uv-coordinate of 1.01 is the same as 0.01 --> the texture ramp gets blurred slightly due to sampling of the texture and some of the black parts of the root gets blurred to the tip. This could only happen if you use a texture file for the ramp though.

Jens

btw. the rendering looks nice otherwise :). Any chance we might see the final animation some time ?!

Link to comment
Share on other sites

Hey Jens, thanks for tip number 1. I'll try and see if it improves the noise. What values for jitter and shading rate would you recommend in this case?

Concerning tip 2, the ramp is not created via a texture, its created via point attributes and Y-size before I copy them to the sphere.

The animation has to be finished 5th of August, I'll post it some days later.

Thanks again

Achim

Link to comment
Share on other sites

Not really, I have very little experience with mantra. I don't think the shading rate will change much here, I guess most problems here are related to the very fine structes and rather high contrasts. This is pretty much the worst case scenario for any renderer.

As far as I know the renderer kinda shoots a ray from camera space onto your scene and tries to find the first collision of that ray with your scene geometry. If the structure is very fine compared to a single pixel in the rendering there is a decreasing smaller chance the ray will hit your hair structure (with each sample it varies slightly the position of the start position of that ray and averages the returned values). Thus I don't think jittering (just some extra randomisation of the inital start position of the rays to get rid of pattern related noise) will help much here and the only way to bypass that problem is to either increase the hair width to ~1 pixel and compensate it with transparency (doesn't matter really if the renderer either finds out via 50 samples that in 5 samples it did hit the hair structure --> it contributes 1/10 of the final color on that pixel or if you just make it 90% transparent and ~pixel size 1 and it still contributes 10% of the final color. If you solve it via lots of samples there is the chance that at times it'll only find 3/50 hits and other times 7/50... Anyhow I guess you get the idea.

If you add DOF on it anyhow, I'd just increase the upper width even further until you see the difference really and possibly render these structures seperatly if you still need a very high sampling to get rid of the noise.

Jens

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...