#version unofficial 3.8; // yuqk #if (file_exists("version.inc")) #include "version.inc" #end #if (!defined(Fork_yuqk)) #error "This POV-Ray SDL code requires the yuqk fork." #end global_settings { assumed_gamma 1 } #declare Grey50 = srgb <0.5,0.5,0.5>; background { Grey50 } #declare Camera00 = camera { perspective location <3,3,-3.001> sky y angle 35 right x*(image_width/image_height) look_at <0,0,0> } #declare White = srgb <1,1,1>; #declare Light00 = light_source { <50,150,-250>, White } #declare Red = srgb <1,0,0>; #declare CylinderX = cylinder { -1*x, 1*x, 0.01 pigment { Red } } #declare Green = srgb <0,1,0>; #declare CylinderY = cylinder { -1*y, 1*y, 0.01 pigment { Green } } #declare Blue = srgb <0,0,1>; #declare CylinderZ = cylinder { -1*z, 1*z, 0.01 pigment { Blue } } #declare sq = function (x) { x*x } #declare Fn01m = function (x,y,z) { min( (sq(sqrt(x*x + y*y) - 3) + z*z - 0.4 ), (sq(sqrt((x - 4.5)*(x - 4.5) + z*z) - 3) + y*y - 0.4), (sq(sqrt((x + 4.5)*(x + 4.5) + z*z) - 3) + y*y - 0.4), (sq(sqrt((y + 4.5)*(y + 4.5) + z*z) - 3) + x*x - 0.4), (sq(sqrt((y - 4.5)*(y - 4.5) + z*z) - 3) + x*x - 0.4), (sq(sqrt(x*x + y*y) - 5) + z*z - 0.4 ) ) } #declare Iso99 = isosurface { function { Fn01m(x,y,z) } contained_by { box { -8.2,8.2 } } threshold 0 accuracy 0.0005 max_gradient 10 pigment { Green } scale 0.19 } //--- scene --- camera { Camera00 } light_source { Light00 } object { CylinderX } object { CylinderY } object { CylinderZ } object { Iso99 }