POV-Ray : Newsgroups : povray.newusers : CSG Problems in drawing Arc : Re: CSG Problems in drawing Arc Server Time
29 May 2024 01:12:41 EDT (-0400)
  Re: CSG Problems in drawing Arc  
From: Eugene K
Date: 17 Oct 2012 01:25:07
Message: <web.507e40ab1ba8ef451d9406540@news.povray.org>
"B. Gimeno" <nomail@nomail> wrote:
> "Eugene.K" <eug### [at] gmailcom> wrote:
> >      #local  oRad = rad(oArc/2) ;
>
> .... among other things I'm not sure to understand... What says your manual about
> the reserved word "rad"? Or is a macro written for you to pass degrees to
> radians? In your published code the statements of some predefined variables
> shine in his absence.
>
> You should also read the manual about the macro "Wedge (Angle)" included in
> "shapes.inc" that approaches to what you want.
>
> Furthermore, pov-ray like any other computer program does exactly what you ask
> him to do the way that you ask it ;-)
>
>
> B. Gimeno

Thank you for your response!

//=============================================
// ARC RADIANS TO AND FROM DEGREES
// short-named for tidy trig formulae
// --------------------------------------------
   #declare  deg_rad = 180/pi ;//=(57.2957795-)
// --------
     #macro  deg(oRad)  (oRad * deg_rad)   #end
     #macro  rad(oDeg)  (oDeg / deg_rad)   #end
//=============================================
....is part of 'Core', my personal constants package;
I'd much rather write "sin(rad(oDeg))" than
"sin(radians(oDeg))", especially in tight places,
and no one else yet was using that symbol, so...?

I would like to share such packages, but don't know how yet.

I looked into 'shapes.inc' and found 'Wedge( )', which does use
at least relevant technique...thank you!

Eugene.K


Post a reply to this message

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