POV-Ray : Newsgroups : povray.newusers : sphere proportions Server Time
23 Nov 2024 07:51:40 EST (-0500)
  sphere proportions (Message 1 to 10 of 24)  
Goto Latest 10 Messages Next 10 Messages >>>
From: Psnarf
Subject: sphere proportions
Date: 31 May 2021 12:30:00
Message: <web.60b50ee238c338a88b87fe773aaaf4dc@news.povray.org>
In a square window,
sphere {
    <0, 1, 2>, 2
    texture {
        pigment { color Yellow }
    }
}
produces an ellipsoid, the vertical radius is larger than the horizontal radius:
`povray -Idemo.pov +V +W400 +H400`

Apparently, the window proportion must be 1:1.33 in order to produce a sphere
with a fixed radius. Should not sphere appear circular no matter what the window
proportions in the render command?


Post a reply to this message


Attachments:
Download 'demo.png' (3 KB)

Preview of image 'demo.png'
demo.png


 

From: Psnarf
Subject: Re: sphere proportions
Date: 31 May 2021 12:35:00
Message: <web.60b50f92dfb9240b8b87fe773aaaf4dc@news.povray.org>
> the window proportion must be 1:1.33
....such as 640x480 or 520x390


Post a reply to this message

From: jr
Subject: Re: sphere proportions
Date: 31 May 2021 12:40:00
Message: <web.60b5109fdfb9240b79819d986cde94f1@news.povray.org>
hi,

"Psnarf" <nomail@nomail> wrote:
> In a square window,
> sphere {
>     <0, 1, 2>, 2
>     texture {
>         pigment { color Yellow }
>     }
> }
> produces an ellipsoid, the vertical radius is larger than the horizontal radius:
> `povray -Idemo.pov +V +W400 +H400`
>
> Apparently, the window proportion must be 1:1.33 in order to produce a sphere
> with a fixed radius. Should not sphere appear circular no matter what the window
> proportions in the render command?

depends on the 'right' vector of your camera.
<https://wiki.povray.org/content/Reference:Camera#Index_Entry_right_camera>


regards, jr.


Post a reply to this message

From: Psnarf
Subject: Re: sphere proportions
Date: 31 May 2021 13:25:00
Message: <web.60b51b13dfb9240b8b87fe773aaaf4dc@news.povray.org>
"jr" <cre### [at] gmailcom> wrote:
> hi,
....
> depends on the 'right' vector of your camera.
> <https://wiki.povray.org/content/Reference:Camera#Index_Entry_right_camera>
>
>
> regards, jr.

Thank you, jr. I am a noob, running the demo.pov from the tutorial. I haven't
come to the camera, yet. As the poet Frost might say, I have miles to go before
I can create anything worthy of the top-100.


Post a reply to this message

From: jr
Subject: Re: sphere proportions
Date: 31 May 2021 14:00:00
Message: <web.60b5236ddfb9240b79819d986cde94f1@news.povray.org>
hi,

"Psnarf" <nomail@nomail> wrote:
> "jr" <cre### [at] gmailcom> wrote:
> ....
> Thank you, jr. I am a noob, running the demo.pov from the tutorial. I haven't
> come to the camera, yet. As the poet Frost might say, I have miles to go before
> I can create anything worthy of the top-100.

you're welcome.  hope you will find "povving" a pleasant hobby.  re camera,
personally I like to use an aspect ratio (eg "right * (16/9)"), because it's
readable.


regards, jr.


Post a reply to this message

From: jr
Subject: Re: sphere proportions
Date: 31 May 2021 14:05:00
Message: <web.60b524bcdfb9240b79819d986cde94f1@news.povray.org>
"jr" <cre### [at] gmailcom> wrote:
> ...> personally I like to use an aspect ratio (eg "right * (16/9)"), because

sheesh..  should read "right x * (16/9)".  sorry.


regards, jr.


Post a reply to this message

From: Bald Eagle
Subject: Re: sphere proportions
Date: 31 May 2021 14:25:00
Message: <web.60b52929dfb9240b1f9dae3025979125@news.povray.org>
"jr" <cre### [at] gmailcom> wrote:
> "jr" <cre### [at] gmailcom> wrote:
> > ...> personally I like to use an aspect ratio (eg "right * (16/9)"), because
>
> sheesh..  should read "right x * (16/9)".  sorry.


Yes,  and a lot of us are lazy and very naughty and use:

right x*image_width/image_height

https://wiki.povray.org/content/Knowledgebase:Language_Questions_and_Tips#Topic_19


It's worth pointing out at this early stage that "x" is a reserved keyword,
shorthand for the cardinal x basis vector, <1, 0, 0>.

So after multiplying, you get: <image_width/image_height, 0, 0>

Maybe this will help explain better, or help to further confuse you...  :D

http://news.povray.org/povray.binaries.images/thread/%3Cweb.5d881ea3763463c54eec112d0%40news.povray.org%3E/?ttop=430067
&toff=50


Post a reply to this message

From: Psnarf
Subject: Re: sphere proportions
Date: 1 Jun 2021 13:35:00
Message: <web.60b66e93dfb9240b8b87fe773aaaf4dc@news.povray.org>
> x*image_width/image_height = <image_width/image_height, 0, 0>
> "x" is a reserved keyword, shorthand for the cardinal x basis vector, <1, 0, 0>.

That seems intuitive. Thanks for the tip!

Obquote:
  "Ad hoc, ad hoc,
  And quid pro quo.
  So little time,
  And so much to know." -J. Hillary Boob, Phud.


Post a reply to this message

From: Psnarf
Subject: Re: sphere proportions
Date: 1 Jun 2021 13:40:00
Message: <web.60b6701edfb9240b8b87fe773aaaf4dc@news.povray.org>
The code for demo.pov:

#include "colors.inc"    // The include files contain
#include "stones.inc"    // pre-defined scene elements

camera {
    location <0, 2, -3>
    look_at  <0, 1,  2>
}

sphere {
    <0, 1, 2>, 2
    texture {
        pigment { color Yellow }
    }
}

light_source { <2, 4, -3> color White}

-=-=-=-=-=-=-=-=-
Why does the radius of the sphere change if the render window is not 1:1.333?
A ratio of 1:1.777 (16/9) produces the attached image.


Post a reply to this message


Attachments:
Download 'demo.png' (4 KB)

Preview of image 'demo.png'
demo.png


 

From: jr
Subject: Re: sphere proportions
Date: 1 Jun 2021 14:00:00
Message: <web.60b674e9dfb9240b79819d986cde94f1@news.povray.org>
hi,

"Psnarf" <nomail@nomail> wrote:
> The code for demo.pov:
>
> #include "colors.inc"    // The include files contain
> #include "stones.inc"    // pre-defined scene elements
>
> camera {
>     location <0, 2, -3>
>     look_at  <0, 1,  2>
> }
>
> sphere {
>     <0, 1, 2>, 2
>     texture {
>         pigment { color Yellow }
>     }
> }
>
> light_source { <2, 4, -3> color White}
>
> -=-=-=-=-=-=-=-=-
> Why does the radius of the sphere change if the render window is not 1:1.333?
> A ratio of 1:1.777 (16/9) produces the attached image.

when I cut'n'paste the above in a file and render it all defaults (here 4/3, ie
960x720), the sphere's round.  if I insert 'right x * (16/9)' in the camera, and
render with '+w960 +h540', the sphere's round.

if you do not want to modify the camera, you'll have to stick with the (default)
4/3 aspect to see the shape you expect.


regards, jr.


Post a reply to this message

Goto Latest 10 Messages Next 10 Messages >>>

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