Draw a shpere, but look more like an egg, what's matter?

command
glutSolidSphere(0.8,32,22);
but look more like an egg, odd enough.
whT’S MATTER?

remark,screen has been calibrated.

Wrong aspect of the viewport!

aspect has been cal, too.

glLoadIdentity ();
gluPerspective(60.0, (GLfloat) w/(GLfloat) h, 1.0, 60.0);
where w/l=300/300

when draw a cycle, it looks perfect round!

OK, then the distortion is a side effect of the wide field-of-view (FOV).
Narrow down the FOV and move camera back (i.e. set the first parameter of gluPerspective() to 40 or 45).

[QUOTE=Aleksandar;1266011]OK, then the distortion is a side effect of the wide field-of-view (FOV).
Narrow down the FOV and move camera back (i.e. set the first parameter of gluPerspective() to 40 or 45).[/QUOTE]
That’s reasonable, but 60 degree is a normal fov of our human being. howevr I shall have a try.

Actually, it is not! FOV depends on the viewer’s distance from the monitor.

In order to make analysis simpler, let’s assume the human eye is a standard camera sensor. Since the focal length of the human eye is 48.24mm, an equivalent vertical FOV should be about 41 deg.

Nowadays, applications and games usually make fixed horizontal FOV, probably because the use of wide screen monitors. Maybe you saw that someone suggested the usage of 60 deg, but probably for the horizontal FOV.

Focal length has nothing to do with it.

The “correct” field of view angle is dictated by the size of the monitor and the distance of the eye from the monitor. The angle should be that subtended by the edges of the monitor. If the distance is d and the size (height for vertical field-of-view angle, width for horizontal) is s, then the field-of-view angle should be 2.arctan(s/2d).

But this will be far too narrow for most uses, resulting in a “blinkered” view. Imagine creating a rectangular paper cone with the monitor as its base and your eyes looking through its apex. For any reasonable viewing distance, the angle is so narrow that you’d have great difficulty walking around with your view so restricted.

So most applications choose a compromise between a field of view which is large enough to be useful while not being so large as to produce extreme distortion. Performance may also be a factor (a wider view angle makes more of the world visible, potentially increasing rendering load).

It does if you need to overlap artificially generated image and the picture from the real camera, link in augmented reality.
In that case, the following parameters of the sensor are important to calculate FOV: aspect, size and focal length.

We agree on the way how FOV should be calculated. But since we cannot predict the size of the monitor and the viewer’s distance, I used a standard sensor analogy.

[QUOTE=Aleksandar;1266014]Actually, it is not! FOV depends on the viewer’s distance from the monitor.
[/QUOTE]
That will depend on how you define fov, now we talk about angle, thus it has nothig to do with distance how far we are from the monitor.

In order to make analysis simpler, let’s assume the human eye is a standard camera sensor. Since the focal length of the human eye is 48.24mm, an equivalent vertical FOV should be about 41 deg.

Nowadays, applications and games usually make fixed horizontal FOV, probably because the use of wide screen monitors. Maybe you saw that someone suggested the usage of 60 deg, but probably for the horizontal FOV.

I see, but I remember that human being’s eye forcus is 35-42mm, thus, we have standard 35mm film.
I shall check it.
and our horizon fov, I remember is 110degree. of cause vertical aspect is lower than this number, thus we have 16:9 concept. from the point of view of a painter, however, 60 degree is a good nomal view angle. no distortion from this angle.

[QUOTE=GClements;1266016]Focal length has nothing to do with it.
d).[/QUOTE]
focal distance has something to do with it. you can deduce it from object, imagine and focus relationship.

The “correct” field of view angle is dictated by the size of the monitor and the distance of the eye from the monitor. The angle should be that subtended by the edges of the monitor. If the distance is d and the size (height for vertical field-of-view angle, width for horizontal) is s, then the field-of-view angle should be 2.arctan(s/2d).

But this will be far too narrow for most uses, resulting in a “blinkered” view. Imagine creating a rectangular paper cone with the monitor as its base and your eyes looking through its apex. For any reasonable viewing distance, the angle is so narrow that you’d have great difficulty walking around with your view so restricted.

So most applications choose a compromise between a field of view which is large enough to be useful while not being so large as to produce extreme distortion. Performance may also be a factor (a wider view angle makes more of the world visible, potentially increasing rendering loa

the fomula you deduced is correct.
so it is, wide-angle or fish-eye lens can watch more wider world, but with distortion. which can form a certain art exagration.

[QUOTE=Aleksandar;1266017]It does if you need to overlap artificially generated image and the picture from the real camera, link in augmented reality.
In that case, the following parameters of the sensor are important to calculate FOV: aspect, size and focal length.

We agree on the way how FOV should be calculated. But since we cannot predict the size of the monitor and the viewer’s distance, I used a standard sensor analogy.[/QUOTE]

both of your two are correct, just discuss from differnt aspect.
back to our topic, we can set them by glPerspective and glLookat, I change the angle to 40, it seems there is no much improvement.

here is pic,
[ATTACH=CONFIG]1022[/ATTACH]
[ATTACH=CONFIG]1023[/ATTACH]
this pic takes about 200ms to draw.

Correct:
I browse the cyber net, explanation is confusion. I sumarize that the human being nomal focal length should be 17.2mm. The standard of 35mm or 50mm lens will have similar fov with human being.

fov=110degree(h) x 80deg(v).

After a bout of comparation, I find when it sites at center, it looks like perfect circle.
when draw a circle at that location, it’s also perfect.
what’s matter?

[ATTACH=CONFIG]1024[/ATTACH]
Look, as if they are projected to a curved surface, not on the plane.
What caused this distortion?

That is simply the effect of projecting any object. Your distortion is exaggerated because it’s rather large (or that it’s apparent size is large relative to its distance to the camera).

Hold a ball really close to your eye, and it too will not appear circular.

Projecting a sphere to a point results in a circular cone, whose axis is the line through the projection origin and the centre of the sphere. If the axis is perpendicular to the projection plane, the intersection of that cone with the projection plane will be a circle. Otherwise, provided that the projection plane doesn’t intersect the sphere, it will be an ellipse (if the projection plane does intersect the sphere, it will be a parabola or a hyperbola).

See e.g. the Wikipedia page for Conic section for some background.

In short, the perspective projection of a sphere is only a circle if the sphere is in the “centre” of the view (that’s the projection centre, i.e. the line through the projection origin which is perpendicular to the projection plane; which isn’t necessarily the centre of the viewport).

The eccentricity of the ellipse increases as the centre of the sphere moves farther from the centre of the view. The eccentricity is effectively limited by the field-of-view angle, as cases resulting in high eccentricity will be wholly or mostly outside of the view, so increasing the field-of-view angle increases the maximum eccentricity which can be obtained for a sphere which is entirely within the view frustum.

[QUOTE=Alfonse Reinheart;1266036]That is simply the effect of projecting any object. Your distortion is exaggerated because it’s rather large (or that it’s apparent size is large relative to its distance to the camera).

Hold a ball really close to your eye, and it too will not appear circular.[/QUOTE]
No, you are confusing geo projection and real wide-angle lens. we can imitate it, but here not…