POV-Ray : Newsgroups : povray.general : Mud Cracks : Re: Mud Cracks Server Time
1 Aug 2024 14:32:04 EDT (-0400)
  Re: Mud Cracks  
From: Anthony D  Baye
Date: 18 Aug 2005 17:03:11
Message: <4304f78f$1@news.povray.org>
Mike Williams wrote:
> Wasn't it Anthony D. Baye who wrote:
> 
>>Can anybody suggest a method procedural method, (Not using an image 
>>file) to create a pattern of mud cracks such as one might find in the 
>>desert?
>>
>>I'd like to use an Isosurface for this, and I need to Use it in a 
>>difference.
>>
>>For example, see: http://pespmc1.vub.ac.be/Photos/MudCracks.jpg
> 
> 
> Here's something that might get you started in the right direction
> 
> 
> camera { location  <0, 2, -4> look_at <0, 0.1, 0> angle 17}
> light_source {<-100,100,100> colour rgb 1}
> 
> #declare P1=function{
>   pigment{
>     crackle 
>     colour_map {[0 rgb 0][0.08 rgb 1]}
>     turbulence 0.2
>   }
> }
> 
> #declare P2=function{
>   pigment{
>     crackle 
>     colour_map {[0 rgb 0][0.025 rgb 1]}
>   }
> }
> 
> #declare Scale1=0.2;
> #declare Scale2=0.07;
> #declare Height1=0.03;
> #declare Height2=0.01;
> isosurface {
>   function { y - P1(x/Scale1,0,z/Scale1).x*Height1
>       - P2(x/Scale2,0,z/Scale2).x*Height2
>   }
>   max_gradient 12
>   contained_by{box{<-1,-0.01,-1><1,(Height1+Height2)*1.01,1>}}
>   max_trace 4
>   pigment {rgb .9}
> }
>       
> It's not fast, and small changes to the Scale and Height parameters can
> require significant changes to the max_gradient.
> 
> The "max_trace 4" isn't actually required in this scene, but you'll need
> it when you use it in your difference.
> 
> 
Hey Mike,

	Thanx, I'll try that.  The only problem I foresee is adjustment to my 
scale.  I'm building my model in a scale of 1 unit = 1 inch.

Regards,

A.D.B.


Post a reply to this message

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