POV-Ray : Newsgroups : povray.general : cracked texture : Re: cracked texture Server Time
9 Aug 2024 15:25:28 EDT (-0400)
  Re: cracked texture  
From: Chris Huff
Date: 24 Jun 2000 19:15:32
Message: <chrishuff-8A05BC.18200024062000@news.povray.org>
In article <395512D5.67AEA550@aol.com>, SamuelT <STB### [at] aolcom> 
wrote:

> If you're using megapov, you could #declare a pigment to be used as a 
> normal,
> like so:
> 
> #Cracks=
>  function{
>   pigment{ spherical
>    pigment_map{
>     [0 rgb 1]
>     [1 crackle color_map{[0 rgb 0][.5 rgb 1]}]
>    }
>   }
>  }
> 
> #object{ Headstone pigment{rgb 1}normal{function Cracks} }
> 
> This should make the cracks start from a center point, and then become 
> just flat
> further out. Just a simple idea that can be expanded on.

I think you mean something like this:
#declare Cracks =
function {
    pigment { spherical
        pigment_map {
            [0 rgb 1]
            [1 crackle color_map {[0 rgb 0][.5 rgb 1]}]
        }
    }
}

object{ Headstone pigment{rgb 1}normal{function Cracks} }

However, you might get better results by making the cracked object out 
of an isosurface with a pigment as part of the function, or by using an 
isosurface or height field in a difference statement with the original 
object. These have the advantage of being real cracks, which look *much* 
more realistic, especially with wide cracks.

Another possibility would be to use the "object" or "blob" patterns with 
some turbulence, these could make it possible to direct the cracks 
wherever you want.

-- 
Christopher James Huff - Personal e-mail: chr### [at] maccom
TAG(Technical Assistance Group) e-mail: chr### [at] tagpovrayorg
Personal Web page: http://homepage.mac.com/chrishuff/
TAG Web page: http://tag.povray.org/


Post a reply to this message

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