POV-Ray : Newsgroups : povray.binaries.images : Aftermath revisited : Re: Aftermath revisited: proof of concept Server Time
30 Jul 2024 06:28:32 EDT (-0400)
  Re: Aftermath revisited: proof of concept  
From: Thomas de Groot
Date: 27 Aug 2013 04:21:06
Message: <521c6172$1@news.povray.org>
On 26-8-2013 21:59, Samuel Benge wrote:
> Can't you make a new pigment_pattern that combines the proximity pattern and a
> new stain pattern?
>
Best to show with the code. This is the texture using the proximity pattern:

//code 1
#declare Factor      = 1;	
#declare add_noise   = true;
#declare ScaleFactor = 1;//<0.1, 0.1, 1>;

#declare TMProx =
texture {
   pigment_pattern {
     average
     pigment_map {
       [ 3.0 df3_pattern ]
       #if (add_noise = true)
         [ 0.6 slope { <0, 0, 0.99> 0.5, 1.0 altitude <0, 0, 0.99> 0, 
248.672 } color_map { [0 rgb 1] [1 rgb 0] } scale 248.672 ]
	[ 0.4 bozo color_map { [0 rgb 0] [1 rgb 1] } scale ScaleFactor*4/Factor ]
	[ 0.3 bozo color_map { [0 rgb 0] [1 rgb 1] } scale ScaleFactor*1/Factor ]
	[ 0.2 bozo color_map { [0 rgb 0] [1 rgb 1] } scale 
ScaleFactor*0.33/Factor ]
	[ 0.1 bozo color_map { [0 rgb 0] [1 rgb 1] } scale ScaleFactor*0.1/Factor ]
       #end
     }
   }
   texture_map {Dull_brass_map}
}
//end code 1

I want to add the following stain texture:

//code 2
#declare TMGrad =
texture {
   pigment {
     gradient y
     pigment_map {
       [0.35 srgb 0.1]
       [0.45 srgb 0.1 transmit 1]
     }
     scale <1, 120, 1>
   }
   finish {diffuse 0.8 specular 0.3 roughness 0.001}
}
//end code 2

I have not found a satisfying way.

Thomas


Post a reply to this message

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