// Persistence Of Vision raytracer version 3.5 - glasspot.pov //============================================================ // Waterpots used for washing brushes - WIP March 2003 // Thomas Lieven 2003 // http://www.webkenya.com //------------------------------------------------------------- //--------------- //CONFIGURATION //-------------- // Required the mlpov version with the kitchen_probe.hdr - NEEDED // Required the mlpov version for the gradient focal blur - NOT USED // ---------------------------------------------------------- #version unofficial mlpov 0.8; #include "glass.inc" #include "glass_old.inc" #include "textures.inc" #include "colors.inc" #include "metals.inc" #include "woods.inc" #include "functions.inc" // =============================================================== // DECLARE VALUES // =========================================== #declare focalp=0; //1=switch the mlpov gradient-focal blur - very slow (just to try - not needed) #declare mediap=0; //1=media on - not needed (just to try - not needed) #declare photonp=1; //1=photon on #declare ground=1; //0=smooth ground, 1= reflective grey ciment #declare POT1=1; //make pot1 #declare POT2=1; //make pot2 #declare PINC=0; //make pinceau (not finished) // =============================================================== // ENVIRONMENT // =========================================== // GLOBAL SETTINGS // --------------- global_settings {assumed_gamma 0.95 #if (photonp) photons {spacing 0.0055 //autostop 0 jitter 0.5 max_trace_level 15} #else #end} // ----------------------- // HDR SPHERE & BACKGROUND // ----------------------- sphere {0,300 pigment { image_map { hdr "D:\POV\Wip_pov3.5\hdr_light_probe_pictures\kitchen_probe.hdr" once interpolate 2 map_type 7 } rotate <0,145,0> scale 1.2} finish { ambient 0.9815 diffuse 0 } hollow no_image} background { color rgb <1, 1, 1>*1.05 } // ------ // GROUND // ------ //ROUGH & REFLECTIVE TEXTURE #declare tex_01 =material {texture {pigment {marble rotate <0, 0, 90> scale 50 turbulence .25 color_map {[0.0 color rgb 0][1.0 color rgb <.95, .925, .95>]}} finish {specular 0.05 roughness .0105 reflection {0, 0.06} conserve_energy ambient 0.2 diffuse 0.45} } } //SMOOTH TEXTURE #declare tex_00 = material {texture {pigment {color rgb 1}}} plane {y, 0.02 # if (ground=1) material {tex_01 scale 0.05} scale 1} #else material {tex_00} scale 1} #end // ------ // CAMERA // ------ camera {location <0,2,-4> look_at <0.75, 0, 0> angle 30 #if (focalp=1) focal_point <0.75,0,0> aperture 3 blur_samples 4000 bokeh_pigment {gradient y color_map { [0.02 color rgb 1][0.05 color rgb 0] } scale .55 translate <.5,.5,0>} confidence 0.965 variance 1/500 } #else } #end // ----- // MEDIA // ----- #if (mediap) sphere {0,4 hollow texture {pigment {rgbf 1}} interior { media { scattering {1, rgb <0.011,0.011,0.011>*3} intervals 1 samples 5 method 3} }} #else #end // ----- // LIGHT // ----- //SPOTLIGHT LARGE light_source { 0*x color rgb <1,1,1>*1 spotlight translate <40, 80, 40> point_at <1, 0, 0> radius 0.5 tightness 20 falloff 1.5 } // ================================================================ // OBEJCTS AND TEXTURE // =============================== // ***************** // TEXTURE GLASS POT // ***************** #declare COLORGLASS = <0.9,0.9,1.25,0.09,0.088>; #declare COLORLIQUID1 = <1.15,.864,.85,0.953>; #declare COLORLIQUID2 = <0.75,.764,1.35,0.953>; #declare COLORLIQUIDFADE = <0.898,.894,0.95,0.9>; //********************************************************** //TRY TO APPLY AN IMAGE TO THE GLASS - Not used in the scene //*********************************************************** //IMAGE MAP LOGO NOT ONCE //----------------------- #declare ImageMap=pigment {image_map {png "logo.png" once map_type 3 filter all 0.35 } rotate <0,0,0> scale 0.39 translate <0,0.277,0>} //IMAGE MAP LOGO NOT ONLY ONCE //---------------------------- #declare ImageMap2=pigment {image_map {png "logo2.png" once map_type 3 filter all 1.95 } rotate <0,0,0> scale <0.45,0.2,0.45> translate <0,0.317,0>} //---------------------------- #declare ImageMap3=pigment {image_map {jpeg "logo.jpg" once map_type 4} rotate <0,0,0> scale <0.35,0.2,0.35> translate <0,0.317,0>} #declare ClearPart=pigment {rgbf <1.05,0.985,0.985,0.995>} // ********************************************************** //-------------- // TEXTURE GLASS //-------------- #declare tex21 = texture {pigment {color rgbf <1,0.5,0,0.95>} finish {specular 0.7 roughness 0.001 ambient 0.2 diffuse 0.1 reflection { 0.03, 0.51 } conserve_energy }} #declare tex22 = texture { pigment {gradient y pigment_map { [0.18 ClearPart] // [0.18 ImageMap2] // [0.95 ImageMap2] [0.95 ClearPart]}} finish {specular 0.7 roughness 0.001 ambient 0.2 diffuse 0.1 reflection { 0.03, 1 } conserve_energy }} #declare interior2 = interior {ior 1.45 fade_distance 0.50 fade_power 1} //------ //LIQUID //------ #declare TxtLiq1 =texture {pigment { color rgbf COLORLIQUID1 } finish {ambient 0.3 diffuse 0.06 phong 0.2 phong_size 20 specular 0.5 roughness 0.01} } #declare TxtLiq2= texture {pigment { color rgbf COLORLIQUID2 } finish {ambient 0.3 diffuse 0.06 phong 0.2 phong_size 20 specular 0.5 roughness 0.01} } #declare IntLiq2 = interior{ior 1.05 fade_power 1 fade_color rgbf <1,0.55,0.525> caustics 0.8} // ************************ // MAKE GLASSPOTS (1 AND 2) // ************************ // ------------- // DECLARE LATHE // ------------- #declare L=lathe {cubic_spline 10, <-0.1,-2.5>, <0,-2>, <0.5,-1.95>, <1,-1.85>, <2, -1.75>, <3, 0>, <2.5,4>, <3, 5>, <2.5, 5>, <2, 0> translate <0,2,0> scale 0.1} // ---------- // MAKE POT 1 // ---------- #declare outPot1 = difference { object {L} object {L scale <0.95,1,0.95> translate <0,0.052,0>} texture {tex22} interior {interior2} } #declare inPot1= intersection { plane {y,0.45 texture {pigment {color rgbf <1,0.8,0.89,0.6>}} finish {phong 0.95 phong_size 20 ambient 0.2 diffuse 0.5}} object {L scale <0.95,1,0.95> translate <0,0.052,0>} texture {TxtLiq1} interior {IntLiq2} scale 0.9999} #declare Pot1 = union { object {outPot1 } object {inPot1}} #if (POT1) object {Pot1 photons {target collect on refraction on reflection on } } #else #end // ---------- // MAKE POT 2 // ---------- #declare outPot2 = difference { object {L} object {L scale <0.95,1,0.95> translate <0,0.052,0>} texture {tex22} interior {interior2} } #declare inPot2= intersection { plane {y,0.40 texture {pigment {color rgbf <0.75,0.76,1.35,0.5>}} finish {phong 0.95 phong_size 20 ambient 0.2 diffuse 0.5}} object {L scale <0.95,1,0.95> translate <0,0.052,0>} texture {TxtLiq2} interior {IntLiq2} scale 0.9999} #declare Pot2 = union { object {outPot2 } object {inPot2}} #if (POT2) object {Pot2 photons {target collect on refraction on reflection on } rotate y*50 translate <1,0,0>} #else #end // ---------- // PENCIL // ---------- #declare L2=lathe {linear_spline 9, <0,0>, <0.2,1>, <0.3,2>, <0.2,3>, <0.2,3.5>, <0.15,3.75>, <0.25,4>, <0.2,12>, <0,17> translate <0,2,0> scale 0.1} #declare txtHead=texture{pigment{radial frequency 95 turbulence 0.015 lambda 3 color_map{[0 Clear][0.5 rgb<1,0.7,0.2>*0.4][1 Clear]}} finish{ambient 0 diffuse 1 specular 0.2 roughness 0.001} scale <1,4,1>} #declare T_Wood10b = texture {T_Wood10 rotate x*90 scale 0.42 finish {ambient 0.5 diffuse 0.4 specular 0.3 roughness 0.05}} #declare T_Wood8b = texture {T_Wood8 rotate x*90 scale 0.62 finish {ambient 0.3 diffuse 0.8 specular 0.6 roughness 0.005 phong 1 phong_size 20}} #if (PINC) object {L2 texture {gradient y texture_map{ [0 txtHead] [0.485/1.4 txtHead] [0.485/1.4 T_Silver_5E] [0.585/1.4 T_Silver_5E] [0.585/1.4 T_Wood10b] [1 T_Wood10b ]} scale 1.4} photons {target collect off } rotate z*14 translate <0,-0.21,0>} object {L2 texture {gradient y texture_map{ [0 txtHead] [0.485/1.8 txtHead] [0.485/1.8 T_Chrome_3E] [0.585/1.8 T_Chrome_3E] [0.585/1.8 T_Wood8b] [1 T_Wood8b]} scale 1.8} photons {target collect off } scale 0.75 rotate <15,0,-5> translate <0,-0.168,0> } #else #end