POV-Ray : Newsgroups : povray.binaries.animations : New f_dnoise(), modified f_dturbulence(). yuqk R17 : New f_dnoise(), modified f_dturbulence(). yuqk R17 Server Time
21 Dec 2024 12:04:43 EST (-0500)
  New f_dnoise(), modified f_dturbulence(). yuqk R17  
From: William F Pokorny
Date: 4 Dec 2024 01:12:40
Message: <674ff2d8@news.povray.org>
Creating noise related documentation for R17 of yuqk highlighted that 
I'd not implemented a planned f_dnoise() inbuilt wrapper function for 
the internal DNoise() function.

Three parameters of f_dnoise() amount to an independent, x,y,z 
translation of the 3D noise space. I back tracked and added these 
parameters to the existing f_dturbulence() function too. Thinking of it 
another way, it amounts to a 4D noise capability - which is itself an 
old idea suggested by others for POV-Ray.

Given how many isosurface functions end up defined about the origin or 
some other fixed 3D space, any 'noise' ends up relatively fixed / locked 
in/to that space too. It might be additional inbuilt 'noise' related 
functions in yuqk get extended in this way.

The work is still in progress, but two animations of working code 
attached. One for f_dnoise() and the other for f_dturbulenece(). The 
core isosurface functions for the animations below is:

     #include "functions.inc"
     #declare Fn00 = function (x,y,z,_v,_r) {
         f_sphere(x+f_dec3x_f21(_v,5,0),
                  y+f_dec3x_f21(_v,5,1),
                  z+f_dec3x_f21(_v,5,2),
                  _r+
                  (f_length(f_dec3x_f21(_v,5,0),
                          f_dec3x_f21(_v,5,1),
                          f_dec3x_f21(_v,5,2))*1.0)
         )
     }
     #declare Fn01 = function (x,y,z) {
         #if (1)
         Fn00(x,y,z,
             f_dturbulence(x,y,z,3,
                 0.1,0.1,0.1,
                 5,0.40,2.7,0.2,
                 frame_number*0.0005,
                 frame_number*0.0015,
                 frame_number*0.0030),
             0.7
         )
         #else
         Fn00(x,y,z,
             f_dnoise(x,y,z,3,
                 0.4,0.4,0.4,
                 frame_number*0.005,
                 frame_number*0.015,
                 frame_number*0.030),
             0.4
         )
         #end
     }

Bill P.


Post a reply to this message


Attachments:
Download 'f_dnoise.mp4.dat' (99 KB) Download 'f_dturbulence.mp4.dat' (483 KB)

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