POV-Ray : Newsgroups : povray.newusers : intersection makes grainy picture : intersection makes grainy picture Server Time
4 Nov 2024 21:20:29 EST (-0500)
  intersection makes grainy picture  
From: Erwin Kalvelagen
Date: 26 Nov 2002 12:39:57
Message: <3de3b1ed$1@news.povray.org>
I am trying to create a body defined by:

  z <= x
  z <= y
  z >= x+y-1
  x,y,z in [0,1]

It seems to work, but the result is a very "grainy" picture.
A single mesh looks fine, but the intersection does not
seem to render as cleanly.


#include "colors.inc"    // The include files contain
#include "stones.inc"    // pre-defined scene elements

#include "textures.inc"    // pre-defined scene elements
#include "shapes.inc"
#include "glass.inc"
#include "metals.inc"
#include "woods.inc"

  camera {
    location <4, 2, -4>
    look_at 0
    angle 30
  }
  background { color White }
  light_source { <3, 3, -3> White }


intersection {

  mesh {
     triangle { <0,0,0> <1,1,0> <0,0,1> }
     triangle { <1,1,0> <0,0,1> <1,1,1> }
     triangle { <0,0,0> <1,0,0> <1,1,0> }
     triangle { <0,0,1> <1,0,1> <1,1,1> }
     triangle { <0,0,0> <1,0,0> <0,0,1> }
     triangle { <1,0,0> <0,0,1> <1,0,1> }
     triangle { <1,0,0> <1,1,0> <1,0,1> }
     triangle { <1,0,1> <1,1,0> <1,1,1> }
     inside_vector  <0.5, 0.25, 0.5>
  }


  mesh {
     triangle { <0,0,0> <0,0,1> <0,1,1> }
     triangle { <1,0,0> <1,0,1> <1,1,1> }
     triangle { <0,0,0> <0,1,1> <1,1,1> }
     triangle { <0,0,0> <1,0,0> <1,1,1> }
     triangle { <0,0,0> <0,0,1> <1,0,0> }
     triangle { <0,0,1> <1,0,0> <1,0,1> }
     triangle { <0,0,1> <0,1,1> <1,1,1> }
     triangle { <0,0,1> <1,0,1> <1,1,1> }
     inside_vector  <0.5, 0.25, 0.5>
  }


  mesh {
     triangle { <1,0,0> <0,0,1> <1,1,1> }
     triangle { <0,0,0> <0,0,1> <1,0,0> }
     triangle { <1,0,0> <1,1,1> <1,1,0> }
     triangle { <0,0,1> <0,1,1> <1,1,1> }
     triangle { <0,0,0> <0,1,0> <1,0,0> }
     triangle { <1,1,0> <0,1,0> <1,0,0> }
     triangle { <0,0,0> <0,1,0> <0,1,1> }
     triangle { <0,0,0> <0,0,1> <0,1,1> }
     inside_vector  <0.5, 0.5, 0.5>
  }

  pigment { Col_Glass_General }

}


--
-----------------------------------------------------------------------------
Erwin Kalvelagen
GAMS Development Corp., http://www.gams.com
erw### [at] gamscom, http://www.gams.com/~erwin
-----------------------------------------------------------------------------


Post a reply to this message

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