Jump to content

Shader detail loss at distance ??


Recommended Posts

Hey guys, I'm just learning about shading in vops and rendering in mantra and I'm working on a bark shader for a tree. The shader shows up fine when the camera is near the tree but, when it is farther from the tree, the detail is lost. Like I said, I am new to this and am not really sure what is going on. I guess it is some sort of level of detail issue, but I have had no luck figuring it out. If anyone knows how I can fix this or can even just tell me what this issue is called so I can google it, that would be great. You can render with cam1 and cam2 in the attached file to see what I mean.

Thanks

hcs

bark_shader.hipnc

Edited by hcs
Link to comment
Share on other sites

hello,

increase the the z-importance in mantra render node

This measures geometry in 3D. The Z-Importance can be used to bias the z-component of the surface. A Z-Importance of 0 means that the x and y components of the object will be the only metric in determining the size of the object. This is roughly equivalent to raster space measurement.

By increasing the Z-Importance to 1, the z measurement becomes more meaningful. It is possible to increase the Z-Importance beyond 1.

If you think of a grid in the XY plane, the z-importance has no effect. However, if the grid is nearly in the XZ plane, z-importance has more influence on the dicing. With a Z-Importance of 0, only the projected measurements will be used, which will result in long, thin strips being created. With a Z-Importance of 1, the grid will be more uniformly sub-divided. With a value greater than 1, more divisions will be performed in Z.

This is important when displacement mapping is being performed. Increasing the Z-Importance will improve quality on displacement shaded ground planes (for example).

  • Like 1
Link to comment
Share on other sites

You do not have a position plugged into Displace Along Normal and therefore it is using the point position in Camera Space to do the displacement. This is why it changes when you move the camera.

To fix you need to grab the position from a Global Variables and set it to Displacement, then transform it to object space and then plug it into Displace Along Normal.

  • Like 1
Link to comment
Share on other sites

Thanks for the responses guys.

Increasing z-importance definitely makes the shader look better. At first it didn't appear to but when I increased the shading quality as well I could see a clear difference.

Erik_JE, I tried doing what you suggested (transforming the position from global displacement variables to object space and plugging it into the displace along normal node) but for some reason the tree no longer renders at all. I also tried having the displacement part of the shader get its position from that same global variables, but the tree didn't render that way either so I left it plugged into only the displace along normal node. I'm probably missing something very obvious but I can't think what it is...

bark_shader_2.hipnc

Link to comment
Share on other sites

Thanks for the responses guys.

Increasing z-importance definitely makes the shader look better. At first it didn't appear to but when I increased the shading quality as well I could see a clear difference.

Erik_JE, I tried doing what you suggested (transforming the position from global displacement variables to object space and plugging it into the displace along normal node) but for some reason the tree no longer renders at all. I also tried having the displacement part of the shader get its position from that same global variables, but the tree didn't render that way either so I left it plugged into only the displace along normal node. I'm probably missing something very obvious but I can't think what it is...

Actually I am wrong. I am so used to using surface position for displacement noises. In this case tho when you use UVcoords it is not needed cause the displacement amount do not depend on the surface position directly.

If you wan't more detail you can also try increasing the Pixel Samples in the mantra node.

Edited by Erik_JE
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...