POV-Ray : Newsgroups : povray.binaries.images : iso_csg.inc + chars.inc : Re: iso_csg.inc + chars.inc Server Time
16 Aug 2024 06:11:13 EDT (-0400)
  Re: iso_csg.inc + chars.inc  
From: Christoph Hormann
Date: 15 Mar 2002 09:05:23
Message: <3C91FFA3.242F6DEF@gmx.de>

> 
> [...]
> 
> > BTW, it would also be neat to be able to use arbitrary metrics like in the
> > crackle pattern.  Right now these are 'metric 2' and 'metric infinite'.
> 
> doh, this sentence is above my knowledge :-(
> 

It's fairly simple in fact.  You use the f_r function to calculate the
distance which is our common metric:

distance = ( (x1-x2)^2 + (y1-y2)^2 + (z1-z2)^2 )^(1/2)

the '2' is the reason why this is called 'metric 2' in the crackle
pattern.

When increasing this value the function is approaching:

distance = max(abs(x1-x2), abs(y1-y2), abs(z1-z2))

Which results in the way my original macros work.

Christoph

-- 
POV-Ray tutorials, IsoWood include,                 
TransSkin and more: http://www.tu-bs.de/~y0013390/  
Last updated 13 Mar. 2002 _____./\/^>_*_<^\/\.______


Post a reply to this message

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