POV-Ray : Newsgroups : povray.general : 3d noise in superpatch patterns? Server Time
11 Aug 2024 05:18:35 EDT (-0400)
  3d noise in superpatch patterns? (Message 11 to 11 of 11)  
<<< Previous 10 Messages Goto Initial 10 Messages
From: Ron Parker
Subject: Re: 3d noise in superpatch patterns?
Date: 1 Oct 1999 16:31:07
Message: <37f51a0b@news.povray.org>
On Fri, 01 Oct 1999 13:14:15 -0700, Jerry wrote:
>It wasn't actually bozo I wanted, but the ability to use patterns in
>general. Does this feature work to actually create isosurface objects as
>well? In other words, does this allow us to use patterns to deform
>isosurface objects instead of, but identical to, what 'normal' patterns
>fake?

Ah, well in that case I can't help you much.  I'll see what I can do about
getting it in 3.5, but it's not there yet either.  I've just discovered
a whole pile of weird parser behavior in the function code in the superpatch
that probably also exists in 3.5 so it looks like I'll be up to my elbows in
it anyway and I might as well try to re-add the pigment-function stuff while
I'm in there.  No guarantees, though.

I've found these two things wrong with superpatch code and was wondering
if someone might want to confirm that they're not new in my version:

 - Functions don't like having vector components in them.  So this doesn't
   parse correctly, complaining about getting a vector where it wanted a
   float:
   
   #declare myvec=<1,2,3>;
   function { myvec.x*x+myvec.y*y+myvec.z*z }

 - Macros with functions in them don't do well at all.  When you parse this:

   #declare c1=<-2,-1,-3>;

   #macro testfunction(xx,yy,zz)
     function {xx*x+yy*y+zz*z}
   #end

   isosurface {
     function {testfunction( 1,2,3 ) }
   }

   It complains about testfunction, because it doesn't understand this usage
   of a macro.  Worse yet, if you then try to reparse you get an error on the
   #declare line because a global variable didn't get reset before the error.


Post a reply to this message

<<< Previous 10 Messages Goto Initial 10 Messages

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