POV-Ray : Newsgroups : povray.general : Nurbs ? : Re: Nurbs ? Server Time
8 Aug 2024 04:04:59 EDT (-0400)
  Re: Nurbs ?  
From: Warp
Date: 2 Jun 2001 12:17:09
Message: <3b191185@news.povray.org>
Rune <run### [at] mobilixnetdk> wrote:
: Would it be possible to implement nurbs in POV-Ray?

  I see no reason why NURBS (or should it be said "NURBSes"?) couldn't be
implemented as macros which generate triangles or bicubic patches.
  AFAIK NURBS can be simulated with bicubic patches if you use several
of them (spatch does exactly that). And if everything else fails, it could
just generate a triangle mesh.

  The only drawback would be speed, specially if triangles are generated.
However, I think that's a quite small price to pay for the functionality
(as I have preached several times before, if humanly possible, every new
feature should be implemented as macros instead of a patch if it makes
sense and you don't have to make too many compromises).

  However, I think that the biggest problem is your next question:

: Would it be reasonable?

  As Ken said, NURBS are useful mainly in GUI modellers.
  Perhaps it could be possible to make the NURBS macros as easy to use as
possible, but still it would be a pain to hand-code objects with them.

: The reason I'm interested in these nurbs is that I find bicubic patches too
: limiting for what I want to do.

  Is it something you can't do with spatch (or hamapatch for that matter)?

-- 
#macro N(D,I)#if(I<6)cylinder{M()#local D[I]=div(D[I],104);M().5,2pigment{
rgb M()}}N(D,(D[I]>99?I:I+1))#end#end#macro M()<mod(D[I],13)-6,mod(div(D[I
],13),8)-3,10>#end blob{N(array[6]{11117333955,
7382340,3358,3900569407,970,4254934330},0)}//                     - Warp -


Post a reply to this message

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