// Standard include file // POV-Ray User Bald Eagle // November 2014 // #version 3.7; #ifdef (SDL) // do nothing #else // setup scene file for independent rendering global_settings {assumed_gamma 1.0 ambient_light rgb 0 max_trace_level 255} #include "debug.inc" Set_Debug (true) #include "colors.inc" #include "textures.inc" #include "glass.inc" #include "metals.inc" #include "golds.inc" #include "stones.inc" #include "woods.inc" #include "shapes.inc" #include "shapes2.inc" #include "functions.inc" #include "math.inc" #include "transforms.inc" #declare Feet = 12; //--------------------------------------------------------------------------------------------------------<<<< //--------------------------------------------------------------------------------------------------------<<<< //------------------------------------------------------------- Camera_Position, Camera_look_at, Camera_Angle #declare Camera_Number = 0; //--------------------------------------------------------------------------------------------------------<<<< //--------------------------------------------------------------------------------------------------------<<<< #switch ( Camera_Number ) #case (0) #declare Camera_Position = < -12, 72, -9*Feet> ; // front view #declare Camera_Look_At = < 0, 0, 16*Feet> ; #declare Camera_Angle = 65 ; #break #case (1) #declare Camera_Position = < -1.5*Feet, 30, -2*Feet> ; // Closeup #declare Camera_Look_At = < -1.5*Feet, 30, 0.00> ; #declare Camera_Angle = 65 ; #break #case (2) #declare Camera_Position = < 0.00, 1.00,-20.00> ; // front view #declare Camera_Look_At = < 0.00, 1.00, 0.00> ; #declare Camera_Angle = 65 ; #break #case (3) #declare Camera_Position = < 0*Feet, 2*Feet, 0*Feet> ; // top view #declare Camera_Look_At = < 0.00, 0*Feet, 0*Feet> ; #declare Camera_Angle = 65 ; #break #case (4) #declare Camera_Position = < 0.00, 9*Feet, 27*Feet> ; // mobile view #declare Camera_Look_At = < 0.00, 0*Feet, 33*Feet> ; #declare Camera_Angle = 65 ; #break #case (5) #declare Camera_Position = < 0.00, 6*Feet, 35*Feet> ; // mobile view #declare Camera_Look_At = < 0.00, 6*Feet, 25*Feet> ; #declare Camera_Angle = 65 ; #break #else #declare Camera_Position = < 0.00, 1.00,-20.00> ; // front view #declare Camera_Look_At = < 0.00, 1.00, 0.00> ; #declare Camera_Angle = 65 ; #break #end // of "#switch ( Camera_Number )" ----------------------------- //-------------------------------------------------------------------------------------------------------<<<< //-------------------------------------------------------------------------------------------------------<<<< camera { location Camera_Position right x*image_width/image_height angle Camera_Angle look_at Camera_Look_At } //light_source {<0*Feet, 2*Feet, -10*Feet> color rgb <1, 1, 1>} /* sky -------------------------------------------------------------------- sky_sphere{ pigment{ gradient <0,1,0> color_map{ [0 color rgb <1, 1, 1>*0.2 ]//White [0.4 color rgb <0.14, 0.14, 0.56>]//~Navy [0.6 color rgb <0.14, 0.14, 0.56>]//~Navy [1.0 color rgb <1, 1, 1> *0.2 ]//White } scale 2 } } */ #end // end SDL check //################################################################################################### #declare MyGold = texture { T_Gold_2A finish {phong 1 metallic reflection {0.6}} } #declare DullGold = texture { T_Gold_2A finish {phong 1 metallic } } //#declare MirrorTex = texture {pigment { rgb 0 } finish { diffuse 0 ambient 0 reflection 1 }} #declare MirrorTex = texture{ Polished_Chrome } #declare Felt = texture {pigment {Red*0.3} normal {granite scale 2}} #declare Text = texture {pigment {Red} normal {granite scale 1} finish {phong 1}} #declare Gold = pigment {Yellow} #declare LightBulb_Glass = texture { pigment {rgbf <0.98, 0.98, 0.98, 0.98> } finish {diffuse 0.1 reflection 0.1 specular 0.8 roughness 0.0003 phong 1 phong_size 400 emission 0.9 } } // shade height = 4.625 r=1.95 - 3.875 // filament height = 3.5 #declare Base_Texture = texture { pigment { White*0.002 } finish { phong 0.7 reflection 0.45 brilliance 6 roughness 0.7 } } #declare R1 = 1+3/16; // bulb radius #declare R2 = 0.5625; // neck radius #declare h = 2.3-R1; // neck height #declare R3 = (2*h*R1+h*h+R2*R2)/(2*(R1-R2)); #declare s = (R1*(R2+R3))/(R1+R3); // radius at tangent to the sphere #declare Screw_Base = union { lathe { linear_spline // linear_spline | quadratic_spline | cubic_spline 25, // number of points <0.58, 0.0>, <0.53, -0.07>, <0.53, -0.10>, <0.44, -0.13>, <0.44, -0.16>, <0.49, -0.19>, <0.49, -0.22>, <0.475,-0.25>, <0.44, -0.28>, <0.44, -0.31>, <0.49, -0.34>, <0.49, -0.37>, <0.475,-0.40>, <0.44, -0.43>, <0.44, -0.46>, <0.49, -0.49>, <0.49, -0.52>, <0.475,-0.55>, <0.44, -0.58>, <0.44, -0.61>, <0.475,-0.64>, <0.49, -0.67>, <0.49, -0.70>, <0.325,-0.82>, <0.0, -0.82> translate <0,-(R1+h),0> texture { Base_Texture } } cone { <0, -0.82,0>, 0.325, <0, -0.92, 0>, 0.175 translate <0,-(R1+h),0> pigment { Black } } cylinder { <0, -0.92, 0>, <0, -0.945, 0>, 0.175 translate <0,-(R1+h),0> pigment { Black } } cylinder { <0, -0.945, 0>, <0, -0.95, 0>, 0.175 translate <0,-(R1+h),0> pigment { Copper } } cylinder { <0, -0.95, 0>, <0, -0.98, 0>, 0.075 translate <0,-(R1+h),0> pigment { Copper } } } #declare Filament = sphere_sweep { cubic_spline 7, <-0.3125, 0.7, 0>, 0.1/2, // Control Point <-0.3125, 1.4, 0>, 0.1/2, <-0.3125, 3.3, 0>, 0.1/2, <-0.3125, 3.6, 0>, 0.1/2, < 0.3125, 3.3, 0>, 0.1/2, < 0.3125, 1.4, 0>, 0.1/2, < 0.3125, 0.7, 0>, 0.1/2 // Control Point tolerance 0.1 texture {pigment {rgbf <1, 1, 0, 0>} finish {specular 5 ambient 10 phong 1}} translate -y*1.8 double_illuminate } // end of sphere_sweep //Round_Cone2( point A, radius A, point B, radius B, merge on) #declare Shade = difference { cone {<0, 0, 0>, 1.95, <0, 4.625, 0>, 3.875} cone {<0, 0, 0>, 1.95, <0, 4.625, 0>, 3.875 scale <0.9, 1.2, 0.9>} interior {ior 1.5} texture {pigment {rgbt <1, 0.7, 0, 0.9>} finish {emission 0.7}} double_illuminate } #declare Flare = 0.6; #declare Bulb = union { //object {Screw_Base scale 1.5 translate y*3.5 } difference { object {Round_Cone2( <0, -2.9, 0>, 0.95, <0, 0, 0>, 1.80, 1 ) } object {Round_Cone2( <0, -2.9, 0>, 0.95, <0, 0, 0>, 1.80, 1 ) scale 0.9} texture {LightBulb_Glass} double_illuminate } cylinder {<0, -2.7, 0>, <0, -0.3, 0> 0.125 texture {LightBulb_Glass} double_illuminate} cylinder {<0, -3.5, 0>, <0, -2.7, 0> 0.25 texture {LightBulb_Glass} double_illuminate} /*light_source {<0, 3.5, 0> rgb <1, 1, 1>*0.4 looks_like {Filament} union { object {Filament} sphere {<0, 3.5, 0>, 1.7 pigment {rgbf <1*Flare, 1*Flare, 0.5*Flare, 0.99>} finish {emission 1} } } } }*/ } //===================================================================================================== #declare CeilingLamp = union { // Ceiling Medallion //#include "Medallion.inc" //object {CeilingMedallion scale 1.5 translate <0, 41.5, 0>} // Lamp Body //rod cylinder {<0, -1.63, 0>, <0, 42, 0> 0.25 texture {Gold}} sphere {<0,0,0> (2.750/2) scale y*0.204 translate y*8 texture {Gold}} sphere {<0,0,0> (2.375/2) scale y*0.263 translate y*16 texture {Gold}} sphere {<0,0,0> (1.800/2) scale y*0.347 translate y*24 texture {Gold}} //central lamp body cylinder {<0, -0.5, 0>, <0, 0.5, 0> 2 texture {Gold}} sphere {<0,0,0> (2.750/2) scale y*0.204 translate y*0.5000 texture {Gold}} sphere {<0,0,0> (2.375/2) scale y*0.263 translate y*0.5625 texture {Gold}} sphere {<0,0,0> (1.800/2) scale y*0.347 translate y*0.8125 texture {Gold}} sphere {<0,0,0> (2.750/2) scale y*0.204 translate -y*0.5000 texture {Gold}} sphere {<0,0,0> (2.375/2) scale y*0.263 translate -y*0.5625 texture {Gold}} sphere {<0,0,0> (1.800/2) scale y*0.347 translate -y*0.8125 texture {Gold}} sphere {<0,0,0> 1 scale <0.625, 0.375, 1> translate -y*1.625 texture {Gold}} sphere {<0,0,0> 1 scale <0.250, 0.250, 1> translate -y*1.9375 texture {Gold}} #declare R_Tubing = 0.375; #declare Tube = union { sphere_sweep { cubic_spline 18, < 7.875, 0.250, 0>, R_Tubing, // Control Point < 7.687, -1.000, 0>, R_Tubing, // Bulb fixture attachment point < 7.500, -2.250, 0>, R_Tubing, < 6.250, -3.000, 0>, R_Tubing, < 4.760, -1.890, 0>, R_Tubing, < 4.490, 0.000, 0>, R_Tubing, < 4.000, 0.875, 0>, R_Tubing, < 3.187, 1.250, 0>, R_Tubing, < 2.375, 0.875, 0>, R_Tubing, < 2.000, 0.000, 0>, R_Tubing, // attachment point to Lamp body < 2.250, -0.750, 0>, R_Tubing, < 2.875, -1.000, 0>, R_Tubing, < 3.625, -0.600, 0>, R_Tubing, < 3.625, -0.062, 0>, R_Tubing, < 3.250, 0.250, 0>, R_Tubing, < 2.938, 0.000, 0>, R_Tubing, < 3.125, -0.250, 0>, R_Tubing, < 3.312, -0.500, 0>, R_Tubing // Control Point tolerance 0.1 } // end of sphere_sweep // fixture difference { sphere {<0,0,0> 1 scale <2, 2.375, 2>} box {<-3, 0, -3>, <3, 3, 3>} translate <7.687, 0.4375, 0> texture {Gold} } // Glass difference { cone {<0, 0, 0>, 1.95, <0, 4.625, 0>, 3.875} cone {<0, 0, 0>, 1.95, <0, 4.625, 0>, 3.875 scale <0.9, 1.2, 0.9>} translate <7.687, 0.4375, 0> interior {ior 1.5} texture {pigment {rgbt <1, 0.7, 0, 0.9>} finish {emission 0.7}} double_illuminate } //#if (Lamps) //light_source {<0, 3.5, 0> color rgb <1, 1, 1>*0.4 translate < 7.687, 0.4375, 0>} //#include "OldLightBulb.inc" //light_source {<0, 3.5, 0> looks_like {Bulb} translate <7.687, 0.4375, 0>} #declare Flare = 0.6; light_source {<0, 3.5, 0> rgb <1, 1, 1>*0.4 looks_like { sphere {<0, 0, 0>, 1.7 pigment {rgbf <1*Flare, 1*Flare, 0.5*Flare, 0>} finish {emission 1} double_illuminate} } translate < 7.687, 0.4375, 0>} //#end } // end tubing union object {Tube texture {Gold}} object {Tube texture {Gold} rotate y* 120} object {Tube texture {Gold} rotate y* 240} translate -y*42 // brings top of mounting rod to origin } // end ceiling lamp union #ifndef (SDL) #declare Room = pigment {Gray50} box {<-9*Feet, 0*Feet, 18*Feet>, < 9*Feet, 10*Feet, 18*Feet+4> texture {Room}} box {<-9*Feet, 0*Feet, -9*Feet>, < 9*Feet, 10*Feet, -(9*Feet+4)> texture {Room}} box {<-9*Feet, 0*Feet, -(9*Feet+4)>, <-9*Feet, 10*Feet, 18*Feet+4> texture {Room}} box {< 9*Feet, 0*Feet, -(9*Feet+4)>, < 9*Feet, 10*Feet, 18*Feet+4> texture {Room}} box {<-9*Feet, 0*Feet, -(9*Feet+4)>, < 9*Feet, -1*Feet, 18*Feet+4> texture {Room}} box {<-9*Feet, 10*Feet, -(9*Feet+4)>, < 9*Feet, 11*Feet, 18*Feet+4> texture {Room}} object {CeilingLamp translate <0, 10*Feet, 0>} object {CeilingLamp translate <0, 10*Feet, 9*Feet>} //cylinder {<6, 0, 0>, <6, 20, 0>, 0.125 pigment {Green}} //object {Bulb translate x*6} //rotate -y*45 } //object {Bulb rotate -x*90 translate <6, 12, 0>} //object {Bulb rotate -y*115 translate <-4, 0, -2>} //object {Shade rotate -y*115 translate <-4, 0, -2>} #else // do nothing #end