![](/i/fill.gif) |
![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Warp wrote:
> Not true. The size of the projection is still determined using the
> distance between location and look_at. Just try it if you don't believe me.
>
Hi Warp,
I did test it before my first post; perhaps we are talking about
different things. Here is my test scene:
// -w150 -h150
background { color rgb <1,1,1> }
sphere { 0, 1 }
#declare PositionZ = 10;
#declare LookAtZ = 0;
// change the above values at will, keeping
// PositionZ > 1
// and
// LookAtZ < PositionZ
camera {
orthographic
location <0,0,PositionZ>
look_at <0,0,LookAtZ>
right 2*x
up 2*y
}
Regards,
Hugo.
--
www.bishop3d.com
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Ok, I have a solution.
What works for me:
camera {
orthographic
right image_width/2
up image_height/2
look_at 0
location z*1000
}
That seems to provide the correct values for me to map the output image to
the scene. Plus, the "location" doesn't alter the zoom-factor at all.
Thanks!
- Steve
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Hugo <hug### [at] yahoo com br> wrote:
> perhaps we are talking about different things.
Yes: I didn't use 'right' nor 'up'.
--
- Warp
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
"Steve Webb" <nomail@nomail> wrote:
> Ok, I have a solution.
>
> What works for me:
>
> camera {
> orthographic
> right image_width/2
> up image_height/2
> look_at 0
> location z*1000
> }
>
> That seems to provide the correct values for me to map the output image to
> the scene. Plus, the "location" doesn't alter the zoom-factor at all.
>
> Thanks!
I think it should be:
right image_width
up image_height
If your scene is your exact resolution.
Yes, location shouldn't change the zoom factor, but it will clip at the
viewing plane, make sure it is far enough away from the scene.
-tgq
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Trevor G Quayle <Tin### [at] hotmail com> wrote:
> I think it should be:
> right image_width
> up image_height
Doesn't that assume that pixels are square?
If he is using a 4:3 monitor with a 1280x1024 resolution, the pixels
are not square and the rendered image will then look distorted.
--
- Warp
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Warp <war### [at] tag povray org> wrote:
> Trevor G Quayle <Tin### [at] hotmail com> wrote:
> > I think it should be:
>
> > right image_width
> > up image_height
>
> Doesn't that assume that pixels are square?
>
> If he is using a 4:3 monitor with a 1280x1024 resolution, the pixels
> are not square and the rendered image will then look distorted.
>
> --
> - Warp
That's true, but I'm just basing on the original code, tracing pixel for
pixel at 1280x1024 resolution.
-tgq
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
FYI:
The actual camera settings didn't mesh-up correctly afterall, but after a
bit of fiddling, I found a camera setting that works for all resolutions.
I also have a screenshot in case anyone is interested:
camera {
orthographic
right image_width/1.7315
up image_height/1.7315
look_at 0
location z*2000
}
(Don't ask me why 1.7315 is the magic divisor, but it works perfectly).
Screenshot is here:
http://badcheese.com/Screenshot.png
Thanks again, everybody!
- Steve
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
"Steve Webb" <nomail@nomail> wrote:
> (Don't ask me why 1.7315 is the magic divisor, but it works perfectly).
1/1.7315 must be the factor between unit size and pixel size.... It looks
like you're scaling the camera to your scene which must vary in size by
pixel count. Try (image_width/1.7315)/2. You should get the middle half of
your desktop.
Another way would be to put the camera in the 0 to 1 range (up 1 right 1)
and scale everything (less the background because if it's an image_map it
should start out in the 0 to 1 range) in your scene by
<1/image_width,1/image_height,1>.
Charles
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
> If he is using a 4:3 monitor with a 1280x1024 resolution, the pixels
> are not square and the rendered image will then look distorted.
I think it's more likely he is using an LCD, in which case the aspect ratio
will be 5:4.
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
scott <ask### [at] me com> wrote:
> I think it's more likely he is using an LCD, in which case the aspect ratio
> will be 5:4.
I don't really understand why LCDs would do that. The current trend is
to go to wider screens, not narrower ones.
(I'm not doubting what you are saying. I'm just saying that if that's
true, I really don't understand why they would do that.)
--
- Warp
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |