POV-Ray : Newsgroups : povray.general : macro - without () : Re: macro - without () Server Time
5 Aug 2024 10:26:47 EDT (-0400)
  Re: macro - without ()  
From: Rafal 'Raf256' Maj
Date: 2 Oct 2002 05:58:00
Message: <Xns929B797F92A0Braf256com@204.213.191.226>
"Simon Adameit" <gom### [at] gmxde> wrote in news:3d9abfa1@news.povray.org

> If you have such problems you should perhaps think about changing the way
> you write your scenes and not about changing POV-Ray. One way would for
> example be to declare your big objects in include files.

This is a good idea, and I do it already.

But, You have such big objct, (already in .inc file) like :

union { // my space ship - part of BIG scene
  difference {
    merge { // 30 lines... hull // }
    union {
      union { // 10 lines - hole for missiles }
      union { 
         // 30 lines - hole for gun 
      }
      union {
        // 30 lines - random spheres - damage from bullets
      }  
    }
  }
  object { #include "my_gun.inc" }
}

and You want fastly check how ship would like without random spheres 
damage.


This future isn't something realy important, it's just to have more 
comfortable syntax :) And it's look quite easy to code. Currently i'm happy 
with this ignore macro, but maybe keyword would be better ?
I.e. it is needed with infinite objects.


-- 
#macro g(U,V)(.4*abs(sin(9*sqrt(pow(x-U,2)+pow(y-V,2))))*pow(1-min(1,(sqrt(
pow(x-U,2)+pow(y-V,2))*.3)),2)+.9)#end#macro p(c)#if(c>1)#local l=mod(c,100
);g(2*div(l,10)-8,2*mod(l,10)-8)*p(div(c,100))#else 1#end#end light_source{
y 2}sphere{z*20 9pigment{function{p(26252423)*p(36455644)*p(66656463)}}}//M


Post a reply to this message

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