POV-Ray : Newsgroups : povray.general : Sinusoidal surface using isosurface : Re: Sinusoidal surface using isosurface Server Time
31 Jul 2024 22:20:47 EDT (-0400)
  Re: Sinusoidal surface using isosurface  
From: Kenneth
Date: 8 Aug 2006 05:45:00
Message: <web.44d85c7bb9416f6fe22fe6bb0@news.povray.org>
"Shark" <nomail@nomail> wrote:
> Hi, I was wondering if anyone could describe a method of generating the
> sinusoidal surface using isosurfaces. I've done it using the parametric
> object, but it takes too long to render and has too many artifacts.
>
> Thanks!

If I understand your question correctly, here's a very simple method for
imposing sine waves onto a flat isosurface plate or box...

isosurface{
 function{
  y // basic function for a plane surface
  + sin(2*pi*z)*.04
                }
  max_gradient  3 // or whatever
  contained_by{box{<0,-.2,0>,<1,.2,1>}}
 }

This produces sine waves along the z-axis--here, imposing one complete wave
cycle along a unit POV length. The .04 multiplier is the height or
amplitude of the waves. (Since POV's trig functions normally work with
radians, I use 2*pi to convert that to degrees, as there are 2*pi radians
in 360-degrees. Then, I can multiply that to get a more "logical" increase
in sine-wave frequency.) Like this:

+sin(15*2*pi*z)*.04

for 15 complete wave cycles along a unit length.

Ken W.


Post a reply to this message

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