POV-Ray : Newsgroups : povray.text.scene-files : From Clipped_by bug?! question at p.g. Server Time
28 Jul 2024 20:24:46 EDT (-0400)
  From Clipped_by bug?! question at p.g. (Message 1 to 1 of 1)  
From: Bob Hughes
Subject: From Clipped_by bug?! question at p.g.
Date: 27 Apr 1999 06:57:04
Message: <372589B7.5BA22157@aol.com>
//BEGIN

// this shows a demonstration of clipped_by within various parts of a
union CSG

//1 for 1st union clipping, 2 for 2nd union clipping, 3 for 3rd
"combined" union
#declare CT=1;

background {color rgb 1}

// pointlight at camera position
#declare LCX = 5
#declare LCY = 10
#declare LCZ = -10

light_source { <LCX,LCY,LCZ> color rgb <1.5,1.5,1.5>
}
camera
{
  location  <LCX,LCY,LCZ>
  angle 22.5
  look_at   <0.0 , 0.0 , 0.0>
}

//test objects
#declare Clipping_Test = union {
 union {
  cylinder {
   -y,y,1 scale <.75,1.25,.75>
  }
  sphere {
   0,1
  }
#if (CT=1)
  clipped_by {
   plane {
    y, 0
   }
  }
#end
  pigment {rgbft <1.5,0,0,0,0>}
 } //first union
 union {
  box {
   -1,1
   rotate x*0
  }
  box {
   -1,1
   rotate x*45
   rotate y*45
  }
  pigment {rgbft <0,0,1,.25,.75>}
#if (CT=2)
  clipped_by {
   plane {
    y, 0
   }
  }
#end
 }  //second union
#if (CT=3)
  clipped_by {
   plane {
    y, 0
   }
  }
#end
} //third union

object {Clipping_Test}

//END


-- 
 omniVERSE: beyond the universe
  http://members.aol.com/inversez/homepage.htm
 mailto:inv### [at] aolcom?Subject=PoV-News


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.