POV-Ray : Newsgroups : povray.pov4.discussion.general : Scale Postfixes : Re: Scale Postfixes Server Time
3 May 2024 04:55:33 EDT (-0400)
  Re: Scale Postfixes  
From: David H  Burns
Date: 5 Aug 2009 10:30:36
Message: <4a79978c$1@news.povray.org>
clipka wrote:
> Chambers schrieb:
>> David H. Burns wrote:
>>> "Rad" and "deg" for angles and rotation *would* be useful.
>>
>> They're already implemented.
>>
>> // Declares the variable rad to be 45 degrees converted into radians.
>> #declare rad = radians(45);
>>
>> // Declares the variable deg to be 0.3 radians converted into degrees.
>> #declare deg = degrees(0.3);
>>
> They're perfectly counter-intuitive for use in "rotate" though:
> 
>    // trying to express that I intend to rotate by 45 degrees,
>    // with the effect of rotating by 45 radians instead
>    rotate x * degrees(45)
> 
>    // trying to express that I intend to rotate by 0.3 radians,
>    // with the effect of rotating by something particularly useless
>    rotate y * radians(0.3)
True too. "Built in" unit definitions would be useful, maybe with a 
default that could
be set as in calculators?


Post a reply to this message

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