POV-Ray : Newsgroups : povray.general : Fractional axis labeling Server Time
15 Oct 2025 11:21:09 EDT (-0400)
  Fractional axis labeling (Message 1 to 2 of 2)  
From: Bald Eagle
Subject: Fractional axis labeling
Date: 14 Oct 2025 20:50:00
Message: <web.68eeee9e3c36af741f9dae3025979125@news.povray.org>
So, as you all know, I do a lot of graphing, and at one point wanted to have a
nice way to create fractional labels for things like angle values in radians.

I also have a vintage tool addic...  hobby.
And I live in the the US and so use the Imperial system of measurement.

And I wanted to organize all of my drill bits by 64ths of an inch.

And I was bored at work, so I used the gcd function in excel to hammer out the
basics.

Then I ported to povray using the recursive gcd function I wrote.
And then fiddled, DEBUGGED, tweaked, etc.

Finally I have some functional code that will subdivide a line segment,
calculate the simplified fractional value, use "value symbols" like pi or tau,
append units, and rotate the axis labels.

It is not extensively tested or optimized in any way.

Enjoy


Post a reply to this message


Attachments:
Download 'fractionalsizes.png' (263 KB)

Preview of image 'fractionalsizes.png'
fractionalsizes.png


 

From: Bald Eagle
Subject: Re: Fractional axis labeling
Date: 14 Oct 2025 21:40:00
Message: <web.68eefa5cae81306a1f9dae3025979125@news.povray.org>
"Bald Eagle" <cre### [at] netscapenet> wrote:

> Finally I have some functional code that will subdivide a line segment,
> calculate the simplified fractional value, use "value symbols" like pi or tau,
> append units, and rotate the axis labels.


Post a reply to this message


Attachments:
Download 'fractionalsizes.pov.txt' (7 KB)

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