POV-Ray : Newsgroups : povray.pov4.discussion.general : A yuqk fork seedfi example. : A yuqk fork seedfi example. Server Time
20 May 2024 02:21:44 EDT (-0400)
  A yuqk fork seedfi example.  
From: William F Pokorny
Date: 30 Oct 2023 15:02:35
Message: <653ffdcb@news.povray.org>
With the yuqk fork release posted today I started to include some simple 
example scenes for particular features. Attached an image from the 
seedfi_00.pov example.

It's an image that just showed up as I played and I thought it cool. The 
relevant bit of code is below.

...
#declare CarmineRed = srgb <1,0,0.21961>;
#declare Black = srgb <0,0,0>;
#declare ChalkGreen = srgb <0.11765,0.68627,0.07843>;
#declare ColorMap = color_map {
     [ -1 CarmineRed ]
     [  0 Black ]
     [  1 ChalkGreen ]
}

// The focus is just below. It shows the use of the seedfi
// pattern and that it needs to use function_interval due the
// -1..1 values it generates. There is too a chaining of two
// _wave general value pattern modifiers which can create effects
// not otherwise easily achieved.
#declare Fn = function {
     pattern {
         seedfi function_interval sine_wave
         warp {
             turbulence <0,0,1.667>
             octaves 5
             omega 0.67
             lambda 5.3
             it_scale 1/7
         }
     }
}
#declare Pigment00 = pigment {
     function { Fn(x,y,z) }
     function_interval
     frequency 33 triangle_wave
     color_map { ColorMap }
     translate <0,0,-0.5> scale 1/3
}
...

Bill P.


Post a reply to this message


Attachments:
Download 'seedfi_00.jpg' (270 KB)

Preview of image 'seedfi_00.jpg'
seedfi_00.jpg


 

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