POV-Ray : Newsgroups : povray.newusers : Need Help: Isosurface, cosinus and inverted textures : Re: Need Help: Isosurface, cosinus and inverted textures Server Time
28 Jul 2024 22:30:56 EDT (-0400)
  Re: Need Help: Isosurface, cosinus and inverted textures  
From: kaneda
Date: 2 Jul 2007 09:55:02
Message: <web.4689031f97c52c6b4729c3380@news.povray.org>
Wow that worked brilliantly. You're my personal hero of the month!

But everytime i solve one problem I come across yet another one: The first
one was that I couldn't put 2 finishes on the isosurface, which was
possible on the checker texture before. But the difference isn't that
great, so I can live with it.

But..... now the color of the isosurface is always monochrome, even though
the black tiles should be red D: I don't get it.

 #declare pigment1 = // pigment for the white tiles
 pigment{
  White_Marble turbulence 1
 }

 #declare pigment2 = // pigment map for the black tiles
 pigment{
  gradient x
  pigment_map {
   [0.2 rgb <.1,0,0> turbulence 1]
   [0.7 Black]
  }
  turbulence 0.7
 }

 #declare chckr = // a pigment encased in function-brackets
 function{
  pigment {
   pigment_pattern {checker White, Black}
   pigment_map {
    [ 0, pigment1 ] // Using the predefined Pigment 1
    [ 1, pigment2 ] // Using the predefined Pigment 2
   }
  }
 }

 isosurface {
  function {(f(x,y,z) + y)
  }
  threshold 1
  max_gradient 1.5
  contained_by { box {<-4,-2,-4>,<4,2,4>}}
  pigment{
   function{
    chckr(
     x,
     y+f(x,y,z),
     z
    ).gray
   }
  }
  finish {
   specular   1/5
   roughness  0.1
   phong    0.6
   phong_size 100
   reflection 0.33
  }
 }


Post a reply to this message

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