5
$\begingroup$

I'm relatively new to Cycles, so maybe I don't understand all its finer points yet. I am trying to create a normal map from a grayscale bump map produced by an OSL script. The script seems to output the grayscale data just fine, as seen here (output through an emission shader for visibility purposes):

enter image description here

But when I try putting that through the bump node, I get nada in the resulting normal output:

enter image description here

Just to be sure I'm doing something stupid, I tried the same node setup but with a noise texture node instead of the script's output for the bump node's "height" input, and got the expected results.

I haven't been able to find much info about the bump node, but is there a reason it can't use the grayscale data from an OSL script for the height info? If so, is there any way to work around that?

$\endgroup$

1 Answer 1

3
$\begingroup$

Add a Texture Coordinates node, and possibly a vector Mapping node and feeding that into your scripts Vector input.

enter image description here

Even for generated coordinates I've seen better results using a texture input and mapping node for vector input over default coordinates received within osl scripts.

$\endgroup$
1
  • $\begingroup$ So simple, plugging the Texture Coordinates node's generated output into the script fixed it. I'll keep this one in mind. Thanks much! $\endgroup$
    – smashuu
    Nov 16, 2013 at 13:45

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .