POV-Ray : Newsgroups : povray.general : A normal question : Re: A normal question Server Time
11 Aug 2024 11:21:19 EDT (-0400)
  Re: A normal question  
From: Rune S  Johansen
Date: 1 Aug 1999 16:09:20
Message: <37a4a970@news.povray.org>
Nathan Kopp wrote:
>"Rune S. Johansen" wrote:
>>
>> I have a problem when I make a texture (say Texture1) with a normal and
use
>> it in a texture_map.
>>
>> I scale the Texture1 hundred times smaller inside a texture_map entry of
>> another texture (say Texture2). I then scale Texture2 hundred times
bigger.
>>
>> Now I thought the normal would look the same in Texture1 and Texture2 but
it
>> doesn't.
>
>My first suggestion is to use a 'bumps' instead of 'bozo' for your normal.
>Using 'bozo' means you are using a slope_map (albiet a default slope_map)
>with a pattern that wasn't intended for use with normals, while
>'bumps' was specifically designed for normals.  Using bumps will fix
>the problem.

That works for the example but unfortunately in my actual scene I need to
use a gradient pattern and I also need to use sine_wave.

>The second suggestion is to use the reset_children warp that is included in
>both UVPov and the Superpatch.  Instead of scaling the children (entries in
>the texture_map) by 1/100, just don't let POV apply the parent's scale
>transformation to the children:
>
>#declare Texture2 =
>texture {
>   gradient x
>   texture_map {
>      [0.5 Texture1 /*scale 1/100*/]  // commented out the scale factor
>      [0.5 Texture1 /*scale 1/100*/]
>   }
>   scale 100
>   warp{reset_children} // this undoes the scale 100 for the child textures
>}
>
>-Nathan

I wasn't aware of that feature. It sounds very convenient.

However, what I'm working on is for an include file for use in multiple
scenes so I have to stick to official POV.

Thanks for the suggestions anyway.

The texture is only scaled small and then big again, so why does the normal
look different (same size but "deeper" bumps)?


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.