// Last edited on 2010-10-15 13:50:50 by stolfilocal // Some target objects. // Caller must define light_ambient (min 0.0 max 1.0) // FUNNY POOL BALL, WHITE // All dimensions in millimeters // The peedastal that holds the ball in place: #declare TG_funny_pool_ball_white_holder_radius = 8.0; // Arbitrary. #declare TG_funny_pool_ball_white_holder_height = 6.0; // From bottom of ball to floor. #local r = TG_funny_pool_ball_white_holder_radius; #local h = TG_funny_pool_ball_white_holder_height; #local R = BL_funny_pool_ball_radius; #local eps = 0.01; // Fudge distance to avoid coincident surfaces. #declare TG_funny_pool_ball_white_holder_texture = BL_plastic_texture( < 0.2000, 0.4000, 1.0000 >, 0.050, 0.010 ) #declare target_funny_pool_ball_white_holder = // Holder for the white pool ball target. // The holder is modeled by a cylinder with a spherical cavity. difference{ cylinder{ <0,0,0+eps>, <0,0,h+R>, r-eps } sphere{ <0,0,h+R>, R+eps } texture{ TG_funny_pool_ball_white_holder_texture } } #declare target_funny_pool_ball_white = // White "funny pool" ball on its holder. // The ball is centered on the Z-axis with the BOTTOM on the origin. union{ object{ target_funny_pool_ball_white_holder } object{ funny_pool_ball_white translate (h+R)*z } }