POV-Ray : Newsgroups : povray.binaries.images : Amber : Re: Amber Server Time
25 Apr 2024 19:55:17 EDT (-0400)
  Re: Amber  
From: Ive
Date: 6 Apr 2021 18:06:34
Message: <606cdb6a$1@news.povray.org>
Am 4/6/2021 um 23:29 schrieb Norbert Kern:
> I love this amber material!
> It works perfectly for me (never seen amber in my life beside Jurassic Park).
> And you only used HRDI lighting (I assume), which makes it more impressive.
> 
> I would love to see the material code for my materials project...
> 
> 

Thanks, Norbert.

here you go...

It needs /very/ high quality aa/focal blur settings to make the 
micro-normals for slighly blurred reflections/refractions work. Also 1 
POV-Ray unit needs to equals 1 cm.

Use and modify it freely.

===================================================================

// ********************
//  Amber
// ********************

// micro-normals for the surface
#declare P_Micro0 = pigment {
   bumps
   color_map {
    [0.0 rgb 0.95]
    [1.0 rgb 1.0 ]
   }
   scale 0.9
}

#declare P_Micro1 = pigment {
   cells turbulence .5
   color_map {
     [0.0 rgb 0.88]
     [1.0 rgb 1.0 ]
   }
   scale 0.01
}

#declare P_Micro2 = pigment{
   crackle turbulence 1
   color_map{
     [0.000 rgb 0.72]
     [0.005 rgb 0.72]
     [0.012 rgb 1.0 ]
     [1.000 rgb 1.0 ]
   }
   scale 5
}

// combine the normals
#declare P_Surface = pigment{
   average turbulence 0
   pigment_map {
     [1.0 P_Micro0]
     [0.1 P_Micro1]
     [0.1 P_Micro1 rotate  45*x]
     [0.1 P_Micro1 rotate -45*x]
     [0.1 P_Micro1 rotate  90*z]
     [0.1 P_Micro1 rotate  45*y]
     [0.1 P_Micro1 rotate -45*y]
     [1.0 P_Micro2]
     [0.7 P_Micro2 rotate 45]
   }
   scale 0.1
}

// Amber surface normal
#declare N_Surface = normal{pigment_pattern{P_Surface} 0.4}


// Amber Material
#declare M_Amber = material {
   texture {
     pigment {rgbf <0.90, 0.79, 0.40, 0.89> }
     finish {
       ambient    0.0
       diffuse    0.09
       specular   0.25
       roughness  0.005
       brilliance 2
       reflection {0.0 1.0 fresnel on}
       conserve_energy
     }
     normal {N_Surface}
   }
   interior {
     ior 1.6
     fade_power 1001
     fade_distance 2.5
     fade_color <0.90, 0.79, 0.40>
   }
}

==============================================================================


Post a reply to this message

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