POV-Ray : Newsgroups : povray.newusers : Isosurface and f_spiral - bug or feature? : Re: Isosurface and f_spiral - bug or feature? Server Time
2 May 2024 05:59:34 EDT (-0400)
  Re: Isosurface and f_spiral - bug or feature?  
From: Kenneth
Date: 5 Oct 2017 16:00:00
Message: <web.59d68eae808cf40289df8d30@news.povray.org>
"Bald Eagle" <cre### [at] netscapenet> wrote:
>
> Anyway, I did the bleeding obvious, and just defined a function {} to be
> rendered as an isosurface and noodled out ways to adjust the thickness of the
> spirals, adjust the frequency of the spirals, and render multiple spirals.
>
> I left in the original function and a few of my experimental modifications.
> The straightforward spiral code is the uncommented line, and should run
> fine as-is.
> [code]

I'm having fun playing around with this (the various constants, multipliers and
exponents in the functions; even adding multiple functions together!) It's like
a basic 'spiral workshop', with seven 'preset' spiral shapes to examine. Thanks
for taking the time to work it out. I do notice that the functions don't yet
produce 'tapering' of the spiral at the start and end points (i.e, tapering to a
fine point)-- but that's a minor quibble right now, and actually gives us more
opportunities for experimentation, function-wise. And, so far, I haven't seen a
need for a sphere shape at the center; only a bit of isosurface accuracy
adjustment instead. Perhaps the sphere requirement applies to other more complex
spiral cross-sections (or tapering).

Meanwhile... here's a spiral doodle just for the fun of it, that looks like a
rubber mat, draped over an invisible rod.

------
#version 3.71; // or 3.7

global_settings {assumed_gamma 1}
#include "colors.inc"

light_source { <-3,8,2> color .7*White}
light_source { <3,8,-4> color .7*White}
light_source { <0,.5,-1> color .4*White}

camera {
 location <-2, 10, -10>
 look_at  <0, 2, 0>
 angle 50
}

plane {y, -1 pigment { checker Grey, White }}

#declare RADIUS = 4;
#declare Thickness = 0.2;
#declare Freq = 8;
#declare Spirals = 2;

isosurface {
 function {Thickness - y*y*Freq - pow(sin((sqrt(x*x+z*z)*Freq -
 0.5*atan2(z,x))),2) + 5 - pow(x,3)}

 accuracy 0.01
 threshold 0
 max_gradient 107
 contained_by {sphere {<0,0,0>, RADIUS}}
 open
 texture {pigment {Red} finish {specular 0.4}}
 rotate 90*z
 rotate -30*y
 translate 3.2*y
   }


Post a reply to this message

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