How does EOS AF work? You think you know?

I believe the AF on the DRebel and similar non-pro bodies indicate
"in focus" when the subject is within the range of depth of field.
At 24mm, f/2.8 and 8 ft subject distance, the DoF would be from
about 6.2 ft to 11.3 ft. That seems to correspond to what your
getting in your test.

With higher level bodies, Canon uses "high-precision" AF that focus
to within 1/3 of the depth of field. The high-precision mode
requires lenses with maximum apertures of f/2.8 or larger.
Actually, that is done from the Depth of FOCUS, not the Depth of Field. The Depth of Focus is the range at the sensor plane in which a point is resolved no larger than the designated Circle of Confusion. The Depth of Focus increases as aperture decreases, but it does NOT change with focused distance, nor (according to Canon) with focal length change.

--
RDKirk
'TANSTAAFL: The only unbreakable rule in photography.'
 
Hello everyone,

yeah, how does AF work in EOS cameras?
This is not very technical, but a good general introduction:
http://electronics.howstuffworks.com/autofocus.htm/printable
No, they are giving a description of how autofocus works in P&S cameras, not in DSLRs. A DSLR (a Canon DSLR, at any rate) CAN'T calclate from the image itself (as described) because the shutter is closed. Rather, it uses a phased array system, working as Peter describes above.

--
RDKirk
'TANSTAAFL: The only unbreakable rule in photography.'
 
My guess with manual confirmation is that when you half-press the shutter release, the camera does its autofocus calculations anyway--it just doesn't command the lens.

When YOU move the lens, the lens reports its movements back to the camera, and when YOU have moved it to the correct position predicted by the camera, the camera gives you the green light.

Now, how far have you and/or the subject moved since the first moment you half-pressed the shutter and the camera made its calculations?

--
RDKirk
'TANSTAAFL: The only unbreakable rule in photography.'
 
My guess with manual confirmation is that when you half-press the
shutter release, the camera does its autofocus calculations
anyway--it just doesn't command the lens.
Yes, that's what I would guess too.
When YOU move the lens, the lens reports its movements back to the
camera, and when YOU have moved it to the correct position
predicted by the camera, the camera gives you the green light.

Now, how far have you and/or the subject moved since the first
moment you half-pressed the shutter and the camera made its
calculations?
Neither I nor the subject moved.

--
Regards, Wojtek
 
It strikes me that your samples show a slanted field with vertical lines, which is about the worst thing to feed a camera's autofocussing system.

Somewhere in the back of my mind something tells me that such a shot has no chance unless you focus on a HORIZONTAL line maybe next to what you want to shoot and then reframe for the real shot whilst keeping that same focus.

Give it a try because it seems to me that you don't give your camera any chance at all.
Here's an image of the 10D's focus points with the indicators
(black squares on the image) and the actual sensor size and
configuration (Highlighted in red). Image is courtesy of Chuck
Westfall, with the red color courtesy of me.
http://home.comcast.net/~trwilk3/Images/Focus_Point_Size.jpg
Thanks a lot, Tom, I'll take a closer look at this fact.
I suspect that the D-Rebel/300D is similar, though I don't think
they use squares to show the focus points.
I think that I have read somewhere that 10D and 300D share AF
system, but I'm not sure.
--
Regards, Wojtek
 
3.1 Give the lens the last command and stop without reading another
time
Yes, but then focus should not be confirmed!!! How can the camera
confirm focus without checking???
Because it's faster this way.

The camera knows that if the lens does what it's told to do, the focus will be "good enough".

So it's not a problem of the camera anymore: it's a problem of the lens. The camera has finished its job and can free resources to do other things: the lens should drive home alone.

And indeed, no most lenses it works: the lens walks the last step and focus is achieved.

On some lenses, expecially from Sigma that does not have an official license from Canon for the EF mount/protocol, it doesn't work... :)

Fernando
--
Portfolios: http://www.usefilm.com/photographer/18417.html
http://www.bytephoto.com/photopost/showgallery.php?ppuser=1468
 
On some lenses, expecially from Sigma that does not have an
official license from Canon for the EF mount/protocol, it doesn't
work... :)
Canon has said repeatedly that they have never licensed the EF protocol to any other company. Every 3rd party reverse engineers the lenses.

Sigma did an imperfect job of reverse engineering initially, specifically failing to notice that even though early Canon cameras provided a large amount of power to the lens, the Canon EF lenses themselves were very power-efficient.

When Canon later lowered the power applied by the camera to the lens (in order to save battery power), it left some power-gulping Sigma lenses...gulping for power. It was easy enough for Sigma to replace high-power chips with low power chips, and perhaps they've now learned their lesson.

--
RDKirk
'TANSTAAFL: The only unbreakable rule in photography.'
 
Viewfinder dust won't affect the AF. However, if there's dust in your viewfinder, it's more than likely that there's some on your AF sensors as well. A few solid puffs of air from a blower bulb should sort that out.

Petteri
--
Me on photography: [ http://www.prime-junta.tk/ ]
Me on politics: [ http://p-on-p.blogspot.com/ ]
 
3.1 Give the lens the last command and stop without reading another
time
Yes, but then focus should not be confirmed!!! How can the camera
confirm focus without checking???
Because it's faster this way.
The camera knows that if the lens does what it's told to do, the
focus will be "good enough".
No... We're in MF mode, there's no need to do anything fast. But anyway, this would be basically wrong approach, to confirm anything without checking. And in MF mode the more so.

--
Regards, Wojtek
 
It strikes me that your samples show a slanted field with vertical
lines, which is about the worst thing to feed a camera's
autofocussing system.
OK, I could understand that, but then why does it confirm correct focus if it cannot verify it? Remember, we are in MF mode, there is really no need for the camera to confirm focus if it cannot verify that the image is in focus.
Somewhere in the back of my mind something tells me that such a
shot has no chance unless you focus on a HORIZONTAL line maybe next
to what you want to shoot and then reframe for the real shot whilst
keeping that same focus.
Give it a try because it seems to me that you don't give your
camera any chance at all.
I will.

--
Regards, Wojtek
 
yeah, how does AF work in EOS cameras? I also thought I knew. It's
supposed to be very simple: as soon as the camera sees sharp image,
it stops adjusting focus. And in MF mode with focus confirmation,
it confirms focus as soon as it sees sharp image. As simple as that.

BUT IT IS NOT THE CASE!!!!
I thought everyone knew SLRs used phase detection instead of the contrast (aka sharpness) detection you describe. It's right in the specifications for sure.

What does that mean? It means there is a set of optics in front of 2 linear CMOS focus sensor arrays down below the mirror in Canon SLRs. Light from the lens that goes through the first partially (transmissive) mirror is forced down to these optics by a secondary mirror.

The optics are effectively the same as split image prism. The split that we view when we have a focus screen with this feature is the divider between the two CMOS arrays (they don't have to be CMOS, can be CCDs). Each array gets half of the image. Just like your eye does, it tries to line up the two contrast curves (aka adjust their relative phase) on each side of the dividing point. You can actually watch these curves change in near real time with the service CD. Here is a screen shot of basically what we're talking about from the service CD. The red line would be from one half of the sensor and the white line from the other half which look at each half of the split image:



However, it doesn't line them up identically. This is because the optical path to these optics is never precisely the same length as the optical path to the main camera imaging sensor. So, the camera has an offset calibration value, and uses this to adjust the waveforms so they are ever so slightly staggered by this amount.

If you think about it, this phase information can open up new worlds for the autofocus. A contrast system only can tell if the new AF adjustment helped or hurt the focus. It can only answer the question "is it sharper now." It doesn't even know which way the lens is out of focus before it moves it. However, a phase detection system knows if the left array is lined up higher or lower than the right array ( I'm picking an arbitrary axis here). This tells the camera which way to turn the lens before it even moves. Of course, there is a limit to how far the focus can be off before the contrast curves go right off the sensors. You can see this effect easily in a split prism focus screen... as you have to get the focus remotely close before you can use the prism. When you're out of that range some call it a "hunt" mode, and when you're in that range it is sometimes called "aquisition" mode. Nikon bragged about how the range of the second mode was expanded on the D2H.

Besides the direction, it also knows exactly how far the image is out of focus when in aquisition mode by knowing how many pixels out of phase the two waveforms are. This is of course needed in AI servo mode when you do predictive focus since you can never try to focus after the mirror flips up (which is when you need your moving target to be in focus). So, you can see that it is not a very closed loop operation when in AI servo mode. For speed of operation, perhaps loop stability, and probably a few other reasons, it actually is not entirely closed loop when in one shot either.

The above referenced calibration value is the chief cause of front/rear focus in SLRs. It is trivial to change, and is MUCH more precise than anyone who has ever called someone a "pixel peeper" would suspect. I fixed my D60 by adjusting this with the service CD. My Rebel was dead on. My 1DII was off but the 1D service CD would not detect the 1DII so I had to send it in to be done.

Another cause of front/rear focus which affects each lens differently is the fact that although it is obvious how the camera knows how much the image is out of focus, it is not obvious how much it knows how to move it to adjust this. There are a whole series of lens variables that are sent back to the camera for this purpose. These variables are at least mentioned in one of the lens workbooks. They are the same sorts of variables you see in any servo controlled system to adjust things like acceleration, and calibration of the feedback pulses. Those feedback pulses (so the camera knows how much the lens motor has moved) are usually given by some sort of photodiode arrangement looking through teeth on a gear. The same sort of setup that automotive engines use to monitor engine speeds and position relative to top dead center except in the case of engines these are often hall effect sensors instead of photodiodes. This part of the system is well documented in patents (from Kodak I think) that you can find links to on these forums. You can also pull the lens mount off some cheapo lens you have to see this as well. The calibration of this feedback element was the cause of some Sigma 120-300 misfocusing as I understand.

I'm sure this isn't formatted quite in the right order and I've missed a few things, but I'm in a hurry.

Jason
 
When Canon later lowered the power applied by the camera to the
lens (in order to save battery power), it left some power-gulping
Sigma lenses...gulping for power. It was easy enough for Sigma to
replace high-power chips with low power chips, and perhaps they've
now learned their lesson.
It doesn't seem to be the case: the 18-125 and 18-50EX are very recent lenses; still they have often severe focusing problems with Canon bodies.

They are light lenses and don't require great torque, thus should not require great power; still, they have much more difficulties to achieve a good focus vs. larger (and older) Sigma lenses (most notably the Bigma. Mine achieve perfect focus all the times I manage to put the AF sensor on the subject).

Seems a bad grasp on EF protocol to me... but then, it's difficult to dig the truth. :(

Fernando
--
Portfolios: http://www.usefilm.com/photographer/18417.html
http://www.bytephoto.com/photopost/showgallery.php?ppuser=1468
 
Because it's faster this way.
The camera knows that if the lens does what it's told to do, the
focus will be "good enough".
No... We're in MF mode, there's no need to do anything fast. But
I'm not talking about the MF confirmation. I don't know how that works...

Anyway, to me it's quite evident that the camera does not actually check focus using the AF sensors on the final resting point, or it would not fail on some lenses while having reliable results with others!

The AF sensors are actually quite straightforward devices: basically a line (or two crossed lines) of cells that detect the contrast across their length. When maximum contrast is achieved (expecially easy to understand if you imagine the sensor line crossing an edge of the projected image), the sensor gives maximum output; when all the cells of the sensor give similar readings (low contrast), the sensor gives a low output.

Fernando
--
Portfolios: http://www.usefilm.com/photographer/18417.html
http://www.bytephoto.com/photopost/showgallery.php?ppuser=1468
 
of your subject in order to find necessary contrast?

This will confuse the AF into focusing on the backround, you have to find contrast within the plane of the area you want in focus, ie, somewhere in the middle, avoid the edges.
First off, I just plain don't trust the focus confirmation. I don't
know what it does. Manual focusing on one of these screens is an
exercise in futility; I don't even bother anymore -- I shoots in AF
and takes my chances.
So my suggestion to you would be to learn to use AF as it's meant
to be used, and forget about MF.
But with 300D and Sigma at 24 mm and f/2.8, I get 75% or more of
out-of-focus results, although I think I know how to use AF - only
center AF sensor activated, use contrasty motives when focusing,
reframing after locking focus etc etc. But it just gives random
results, with really big percentage of what you could see in
out-of-focus example, which is unacceptable even without magnifying
it to 100%.
The example in MF mode just illustrates what I get in AF mode when
applying AF as well as I can.

Best regards,
Wojtek
--
If only thire wos money to mayke owt of typo's
 
have to see this as well. The calibration of this feedback element
was the cause of some Sigma 120-300 misfocusing as I understand.
Jason, some lenses seem to always fail in the same way, for example, my 18-125 always frontfocuses by a more-or-less similar amount.

The 18-125 does not have adjusting potentiometers to calibrate its AF components.

Do you think there is some way (even in theory only) to manually adjust an AF behaviour in such cases (on the lens, since the camera is OK with all the other lenses)?

Thanks for the excellent infos!

(and... of course... no way to find a Canon Service CD, right? It could come handy one day or another! :) )

Fernando
--
Portfolios: http://www.usefilm.com/photographer/18417.html
http://www.bytephoto.com/photopost/showgallery.php?ppuser=1468
 
It doesn't seem to be the case: the 18-125 and 18-50EX are very
recent lenses; still they have often severe focusing problems with
Canon bodies.
They are light lenses and don't require great torque, thus should
not require great power; still, they have much more difficulties to
achieve a good focus vs. larger (and older) Sigma lenses (most
notably the Bigma. Mine achieve perfect focus all the times I
manage to put the AF sensor on the subject).
Seems a bad grasp on EF protocol to me... but then, it's difficult
to dig the truth. :(
Actually it was the aperture motor that was choking on older Sigma lenses. That was older lenses (when the Canon Elan II came out).

--
RDKirk
'TANSTAAFL: The only unbreakable rule in photography.'
 
Canon has said repeatedly that they have never licensed the EF
protocol to any other company. Every 3rd party reverse engineers
the lenses.
Chuck Westfall of Canon says no. Where have you seen it reported authoritatively otherwise?

--
RDKirk
'TANSTAAFL: The only unbreakable rule in photography.'
 

Keyboard shortcuts

Back
Top