POV-Ray : Newsgroups : povray.general : Solid mesh problem? : Solid mesh problem? Server Time
5 Aug 2024 18:18:20 EDT (-0400)
  Solid mesh problem?  
From: Mike
Date: 8 Aug 2002 22:00:19
Message: <web.3d5320eb7b40f3f88b0b6f760@news.povray.org>
It seems that CSG differences and intersections involving solid meshes
always treat the mesh as the object that is 'cut', i.e. like you placed it
first in the CSG object. Whether you use mesh or mesh2 doesn't seem to make
any difference. Of course you can still use inverse on the entire CSG to
get the correct shape, but it'd be nicer to keep everything behaving
consistently. ;)
Can someone verify this?

Here's an example using a plane and an icosahedron:

light_source{<5,10,-10>color rgb<1,1,1>}
difference{
  box{
    <-2,-2,-2><2,-.1,2>
    pigment{color rgb<0,1,0>}
  }
  mesh2{
    vertex_vectors{
      12
      <-1,0,-0.618> <-1,0,0.618> <-0.618,-1,0> <-0.618,1,0>
      <0,-0.618,-1> <0,-0.618,1> <0,0.618,-1> <0,0.618,1>
      <0.618,-1,0> <0.618,1,0> <1,0,-0.618> <1,0,0.618>
    }
    face_indices{
      20
      <0,1,2> <0,1,3> <0,4,6> <1,5,7> <0,2,4>
      <0,3,6> <1,2,5> <1,3,7> <2,4,8> <2,5,8>
      <3,6,9> <3,7,9> <4,8,10> <6,9,10> <5,8,11>
      <7,9,11> <4,6,10> <5,7,11> <8,10,11> <9,10,11>
    }
    inside_vector <0,0,1>
    pigment{color rgb<1,0,0>}
  }
  rotate<-10,0,0>
  translate<0,0,5>
}


Post a reply to this message

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