POV-Ray : Newsgroups : povray.programming : Ever-So-Slightly Better Hermite_Cubic Server Time
23 Dec 2024 10:59:55 EST (-0500)
  Ever-So-Slightly Better Hermite_Cubic (Message 1 to 2 of 2)  
From: Tony[B]
Subject: Ever-So-Slightly Better Hermite_Cubic
Date: 12 Oct 2002 00:15:26
Message: <3da7a1de$1@news.povray.org>
I came up with this today (Oct. 11), while adding that extra line the Slime
found was missing in normal.cpp. Look for the next to last function, called
Hermite_Cubic. It's called by Do_Slope_Map. This version saves 1
multiplication and 3 additions over the original one.

static DBL Hermite_Cubic(DBL T1,UV_VECT UV1,UV_VECT UV2)
{
  DBL T0 = T1 - 1;
  DBL rv;

  rv = S2 * T0 + (P1 - P2) * (2.0 * T0 - 1);
  rv = T1 * rv + S1 * T0 * T0;
  rv = T1 * rv + P1;

  return (rv);
}

--
Anthony Bennett


Post a reply to this message

From: Lance Birch
Subject: Re: Ever-So-Slightly Better Hermite_Cubic
Date: 12 Oct 2002 01:59:50
Message: <3da7ba56@news.povray.org>
Re ICQ:  Tada, it's a reply, content now? :)


Post a reply to this message

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