POV-Ray : Newsgroups : povray.newusers : Render Resolution Stretches Image Server Time
25 Nov 2024 11:57:49 EST (-0500)
  Render Resolution Stretches Image (Message 1 to 7 of 7)  
From: the ajj
Subject: Render Resolution Stretches Image
Date: 26 Nov 2005 04:15:00
Message: <web.4388270e5d9883ce54740e130@news.povray.org>
When I render my image at a resolution of 640x480 or 1024x768 - the image
looks fine.  However, when i render at 1280x1024 (the resolution of my pc
screen) the image appears to be stretched in the Y direction.  I have
figured out that the xy ratio is different i.e. 1.33 for 640x480 and 1.25
for 1280x1024 but I wouldn't have expected the image to be stretched just
more space around the edges???  Any ideas how i can correct this?


Post a reply to this message

From: Roman Reiner
Subject: Re: Render Resolution Stretches Image
Date: 26 Nov 2005 04:45:00
Message: <web.43882d9d7a467a16a71237320@news.povray.org>
"the_ajj" <nomail@nomail> wrote:
> When I render my image at a resolution of 640x480 or 1024x768 - the image
> looks fine.  However, when i render at 1280x1024 (the resolution of my pc
> screen) the image appears to be stretched in the Y direction.  I have
> figured out that the xy ratio is different i.e. 1.33 for 640x480 and 1.25
> for 1280x1024 but I wouldn't have expected the image to be stretched just
> more space around the edges???  Any ideas how i can correct this?

In deed it is the aspectratio that streches the image. the docs say:

<docs>
Together the up and right vectors define the aspect ratio (height to width
ratio) of the resulting image. The default values up<0,1,0> and
right<1.33,0,0> result in an aspect ratio of 4 to 3. This is the aspect
ratio of a typical computer monitor. If you wanted a tall skinny image or a
short wide panoramic image or a perfectly square image you should adjust
the up and right vectors to the appropriate proportions.
</docs>

the simpliest solution is always to use

right x*(image_width/image_height)

in the camera block

Roman


Post a reply to this message

From: the ajj
Subject: Re: Render Resolution Stretches Image
Date: 26 Nov 2005 05:00:00
Message: <web.438831037a467a16791418790@news.povray.org>
"Roman Reiner" <lim### [at] gmxde> wrote:

> the simpliest solution is always to use
>
> right x*(image_width/image_height)
>
> in the camera block
>
> Roman

That's great - thanks.  My current camera block is:

#declare cam2 = camera {#declare cl=<0,ystart+35,-58>;
                        #declare la=<0,ystart,0>;
                        #declare fp=<0,ystart,0>;
                        location cl
                        angle 30
                        look_at la
                        #if (use_dof)
                          focal_point fp
                          aperture 0.01
                          blur_samples blur_amt
                          variance 0
                          confidence 0.99
                        #end}

Will 'right' work ok with this?


Post a reply to this message

From: Warp
Subject: Re: Render Resolution Stretches Image
Date: 26 Nov 2005 05:26:50
Message: <43883868@news.povray.org>
Roman Reiner <lim### [at] gmxde> wrote:
> the simpliest solution is always to use

> right x*(image_width/image_height)

  I would recommend against *always* using that. There are several reasons:

  If you use that, the image will be cropped or new parts of the scene
will become visible if the user renders the image with a different aspect
ratio than the author.
  Both of these things can be bad, depending on the scene. If the image
gets cropped, compositionally important parts of the image may be left
out of the image, and the user might not even notice. The original
composition might be severely damaged by this.
  Also the other way around: If parts of the scene which originally were
out of view become visible, it may also destroy compositionality. It may
be that the author didn't bother modeling the rest of the scene which is
outside of view, and if it suddenly comes into view it may look awkard and
bad. And once again, the user might not even notice this (but just think
that the author was incompetent).

  Secondly, if you use 'angle', there's a rather peculiar and often
unwanted behaviour: Simply changing the aspect ratio with 'right' will
always crop or add new scener *vertically*. IOW the image will be cropped
or enlarged in the upper and lower sides of the image. Always.
  More often than not, this is unwanted. Most scenes are rather panoramic
in nature, meaning that they work well if they are enlarged *horizontally*
but not so well if they are enlarged vertically.
  So if you render an image with a larger viewing area, new scenery will
be seen only in the upper and lower part of the image, not on the sides.
  More importantly, if you want to render a "widescreen" version of the
image, what will happen is that the image will just get cropped in the
upper and lower sides, it will not be expanded on the left and right.
This is usually not what one wants.

  If you use a *fixed* aspect ratio with your scene, however, the
compositionality of the scene will never be modified. The only thing
which will happen if the user tries to render with the wrong aspect
ratio is that the image will get deformed. There's a much higher
chance that the user will see that there's something wrong with his
rendering settings this way than when the camera aspect ratio is
calculated automatically.

-- 
                                                          - Warp


Post a reply to this message

From: the ajj
Subject: Re: Render Resolution Stretches Image
Date: 26 Nov 2005 05:40:00
Message: <web.43883b2c7a467a16791418790@news.povray.org>
Warp <war### [at] tagpovrayorg> wrote:
> Roman Reiner <lim### [at] gmxde> wrote:
> > the simpliest solution is always to use
>
> > right x*(image_width/image_height)
>
>   I would recommend against *always* using that. There are several reasons:
>

So if i do not use the 'right' camera function, which warp is saying never
to use, how can i get my image unstretched in 1280x1024???


Post a reply to this message

From: Warp
Subject: Re: Render Resolution Stretches Image
Date: 26 Nov 2005 05:59:00
Message: <43883ff3@news.povray.org>
the_ajj <nomail@nomail> wrote:
> Warp <war### [at] tagpovrayorg> wrote:
> > Roman Reiner <lim### [at] gmxde> wrote:
> > > the simpliest solution is always to use
> >
> > > right x*(image_width/image_height)
> >
> >   I would recommend against *always* using that. There are several reasons:
> >

> So if i do not use the 'right' camera function, which warp is saying never
> to use, how can i get my image unstretched in 1280x1024???

  No, you misunderstood me.

  I didn't recommend against using 'right'. I recommended against using
'right x*(image_width/image_height)'.

  If you use the latter, the aspect ratio of the camera will automatically
be set according to your rendering resolution (assuming square pixels).
image_width and image_height are povray keywords which value are deducible
from their names. The reasons why I recommend against this automatic
aspect ratio settings are the ones I described.

  If you want a correct aspect ratio (for square pixels) in a 1280x1024
image, use:

right x*1280/1024

as the first line of your camera settings.

-- 
                                                          - Warp


Post a reply to this message

From: the ajj
Subject: Re: Render Resolution Stretches Image
Date: 26 Nov 2005 06:15:00
Message: <web.4388435b7a467a16791418790@news.povray.org>
Warp <war### [at] tagpovrayorg> wrote:
>   If you want a correct aspect ratio (for square pixels) in a 1280x1024
> image, use:
>
> right x*1280/1024
>
> as the first line of your camera settings.
>
> --
>                                                           - Warp

Brilliant - thanks - I'll try that :-)

Adrian


Post a reply to this message

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