function absRect($x1, $y1, $x2, $y2) { if($x1 < $x2) { $x = $x1; $w = $x2 - $x1; } else { $x = $x2; $w = $x1 - $x2; } if($y1 < $y2) { $y = $y1; $h = $y2 - $y1; } else { $y = $y2; $h = $y1 - $y2; } rect($x, $y, $w, $h); }
$x2 = $x-$r-R-0.125; line($x2,$y1, $x2,$y2, depth($z1,0,DM)); } ///////////////// // C U T O U T // ///////////////// origin(0,0.75,0); // Button Holes $q = $w / 4.0; circle($q,1.375,0.25-R,depth(0.375,0,DM)); circle($w-$q,1.375,0.25-R,depth(0.375,0,DM)); // Screen Hole $u = (1 + 9.0 / 16.0) / 2.0; rect($hw - $u + R, $h - $th - (1 + 9.0 / 16.0) + R, $hw + $u - R, $h - $th - (3.0/16.0) - R, 0); // Side Dividers line(0,0-R,$w,0-R,depth(0.75,0,DM)); line(0,$h+R,$w,$h+R,depth(0.75,0,DM)); origin(0,0.75 + $h + R * 2.0,0); line(0,$h+R,$w,$h+R,depth(0.75,0,DM)); ?> M30