POV-Ray : Newsgroups : povray.general : procedural texture as a bump map? : Re: procedural texture as a bump map? Server Time
30 Jul 2024 16:15:56 EDT (-0400)
  Re: procedural texture as a bump map?  
From: Tim Attwood
Date: 3 Nov 2008 18:05:30
Message: <490f83ba$1@news.povray.org>
"Dave VanHorn" <mic### [at] gmailcom> wrote in message 
news:web.490f6fef945e846aa08ed15e0@news.povray.org...
>
> I thought there was a way to do this, so that my wood would have apparent
> surface rippling, but I don't seem to be finding it.  I've done 
> "embossing"
> before, where I used a BMP of the text, applied it as a bump map, and then 
> as a
> texture, to "paint" the object..
>
> I'd like to be able to turn this:
> #declare Floor_Texture = texture { pigment { P_WoodGrain18A color_map {
> M_Wood18A }}}
>                         texture { pigment { P_WoodGrain12A color_map {
> M_Wood18B }}}
>                         texture { pigment { P_WoodGrain12B color_map {
> M_Wood18B }}
>                                 }
> into apparent disturbance of the normal so that the wood surface does not 
> appear
> to be a perfectly flat surface, up close.

#declare N_WoodGrain12a = normal {
    bozo
    turbulence 0.04
    lambda 2.5
    omega 0.1
    octaves 7
    scale <0.5, 0.05, 0.05>
};

#declare N_WoodGrain12b = normal {
   wood
   turbulence <0.1, 0.04, 1>
   scale <0.15, 0.5, 1>
   rotate x*2
};

#declare N_WoodGrain18a = normal {
    wood
    turbulence 0.02
    octaves 4
    lambda 4
    scale 0.1
    rotate <2, 0, 0>
};

#declare Floor_Texture = material {
   texture { pigment { P_WoodGrain18A color_map {M_Wood18A }}}
   texture { pigment { P_WoodGrain12A color_map {M_Wood18B }}}
   texture { pigment { P_WoodGrain12B color_map {M_Wood18B }}
      normal {
         average
         normal_map {
            [1  N_WoodGrain18a]
            [1  N_WoodGrain12a]
            [1  N_WoodGrain12b]
         }
      }
      finish {Shiny}
   }
};


Post a reply to this message

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