Continuous Shooting Auto Focus, and continuous shooting live view? - page 2 - Feature Requests - CHDK Forum

Continuous Shooting Auto Focus, and continuous shooting live view?

  • 21 Replies
  • 19544 Views
*

Offline reyalp

  • ******
  • 14113
Re: Continuous Shooting Auto Focus, and continuous shooting live view?
« Reply #10 on: 18 / August / 2008, 16:59:10 »
Advertisements
just a notice, we should not work with viewfinder data, we should acces the liveview rawbuffer (same as the normal image buffer? ), so here we have horizontally the full resolution due sensor readout method...  and sync with every frame.. so we need fast code :(...
isn't possible that an external circuit/controller is responsable for AF?
I'd assume that the full res data simply isn't available, due to the bandwidth.

If you examine the ROM, it's clear that much of the focusing work is done on the main CPU. There are several tasks obviously associated with focusing
FocusLens
FocusEvent
AfIntServTask
AfTask

It's possible that you can get full res sub-images, but the MF window doesn't appear to be full res (on my a540 at least). Analyzing the above mentioned tasks might be productive.

In general, cost considerations would argue for doing as much as possible on the CPU, rather than with dedicated sensors, unless doing so would require a more powerful CPU, or is precluded by something like the DSLR mirror blocking the main sensor.
Don't forget what the H stands for.

*

Offline dzsemx

  • ****
  • 302
  • [SX40HS][A650][A630]
Re: Continuous Shooting Auto Focus, and continuous shooting live view?
« Reply #11 on: 19 / August / 2008, 05:55:02 »
horizontally full res...
3 sony ccd sensors (icx612 is used in a650) with 3 different readout modes:
http://www.sony.net/Products/SC-HP/cx_news/vol49/pdf/icx636_646.pdf
just for example...

vertically only the third(or even less) of the resolution is availalble and focusing algorithm only works horizontally on canon cams
probably AF task skips lines to enhance performance...
try to focus on horizontal lines(on an uniform surface like a paper with printed lines on it)...
if you make it good, AF will fail :)

*

Offline LjL

  • ****
  • 266
  • A720IS
Re: Continuous Shooting Auto Focus, and continuous shooting live view?
« Reply #12 on: 23 / August / 2008, 08:14:45 »
Quote from: brainwash
'd say edge detection could be an alternative to FFT components focusing - edge detection is already built in CHDK so I'd say for a given scene the more edges per constant threshold equals sharper image, but I think that's not safe enough.

I think it's good enough if done properly. Remember what we're doing (well, trying to do) is C-AF: we want to keep the subject in focus, and do it fast.

Do we want to do it very accurately, too? I think not. We're working in MF mode, which means that if you have Safety MF activated (and you really should when using a homebrew algorithm like this), the camera will do the final (and still fast) focus adjustment to achieve accuracy when you half-press.

Of course, that doesn't mean the edge-detection based method I'm currently using is best... heck, I'm just taking a horizontal derivative, surely doing the vertical one too, at the very least, would help.

Quote from: brainwash
I guess that first, the fastest (not most accurate) algorithm should be tried and benchmarked against canon. The current problem is focus hunting (perhaps if no focus is obtained the camera should fall back to a slower but more precise algorithm) and repeated lens positions - the algorithm should not try a focus position if it has been tried.

Well, the problems I'm not sure how to tackle here are: how do I know whether "no focus is obtained"? Again, it's either some threshold, or, I don't know.
And about not trying settings that have been already tried: right, but how do I know the subject hasn't changed (and thus previously-tried settings should be tried again)?


Anyway, the document you linked seems like a very interesting read, although I don't have time to read it thoroughly right now. But all I had found were much more informal hints from forums (I don't remember the URLs, but basically the one interesting suggestion I'd found was to use the standard deviation of the derivative / edge-detected image).


Quote
just a notice, we should not work with viewfinder data, we should acces the liveview rawbuffer (same as the normal image buffer? ), so here we have horizontally the full resolution due sensor readout method...  and sync with every frame.. so we need fast code Sad...
isn't possible that an external circuit/controller is responsable for AF?

I doubt it. In other threads, we discussed how the camera simply can't read the full sensor data when in live view mode, due to readout latency. Sure, maybe one part of the sensor data (namely, the center) is read in full... yet, how would AiAF work like that? And why don't we have a full-resolution MF window? Probably because it's just not there.

*

Offline dzsemx

  • ****
  • 302
  • [SX40HS][A650][A630]
Re: Continuous Shooting Auto Focus, and continuous shooting live view?
« Reply #13 on: 23 / August / 2008, 13:04:08 »
Quote
I doubt it. In other threads, we discussed how the camera simply can't read the full sensor data when in live view mode, due to readout latency. Sure, maybe one part of the sensor data (namely, the center) is read in full... yet, how would AiAF work like that? And why don't we have a full-resolution MF window? Probably because it's just not there.
not even horizontally full resolution? AF wouldn't be effective using lower resolution...
during live view/video skips only lines as i know... like every 4/20 line is read out only, so the camera get's an image in for ex: 3298*494 pixel or something like this
see here http://www.sony.net/Products/SC-HP/cx_news/vol49/pdf/icx636_646.pdf
« Last Edit: 23 / August / 2008, 13:06:24 by dzsemx »


*

Offline reyalp

  • ******
  • 14113
Re: Continuous Shooting Auto Focus, and continuous shooting live view?
« Reply #14 on: 24 / August / 2008, 13:35:29 »
I missed the horizontal part :(

Someone needs to dig through the canon AF code and see what it does.
Don't forget what the H stands for.

*

Offline dzsemx

  • ****
  • 302
  • [SX40HS][A650][A630]
Re: Continuous Shooting Auto Focus, and continuous shooting live view?
« Reply #15 on: 24 / August / 2008, 17:52:37 »
i'm interested in af funtion too, it would be nice to have selectable AF points:)

*

Offline will

  • *
  • 26
  • IXUS 80IS fw 1.01a
Re: Continuous Shooting Auto Focus, and continuous shooting live view?
« Reply #16 on: 24 / August / 2008, 19:15:12 »
i'm interested in af funtion too, it would be nice to have selectable AF points:)

I agree, selectable AF points would be quite useful.

*

Offline LjL

  • ****
  • 266
  • A720IS
Re: Continuous Shooting Auto Focus, and continuous shooting live view?
« Reply #17 on: 25 / August / 2008, 06:01:39 »
Uh, doesn't FlexiZone focusing give you exactly that?

I suggest you don't put too much hope into this feature, anyway. C-AF is definitely possible (I still don't know why shooting_set_focus() crashes but heck, there has to be a reason), but accurate one-shot focusing during half-press is another story.


Not entirely related, but one feature I would like (and is probably already possible to implement with a script) is automatic depth-of-field assessment.
As in, you want two subjects to be in focus; you point to the first, and hit some key; you point to the second, and shoot. The camera sets the aperture that allows both subjects to be in focus, and focuses in the middle.


*

Offline brainwash

  • **
  • 95
  • Nikon D40x & A460
Re: Continuous Shooting Auto Focus, and continuous shooting live view?
« Reply #18 on: 25 / August / 2008, 08:43:25 »
FlexiZone does that but at least for my camera it is cumbersome to move the selection box pixel-by-pixel.

*

Offline dzsemx

  • ****
  • 302
  • [SX40HS][A650][A630]
Re: Continuous Shooting Auto Focus, and continuous shooting live view?
« Reply #19 on: 25 / August / 2008, 11:31:44 »
center AF is too small many times and misses focus, flexizone needs a lot of buttonpushes, and aiaf often focuses too close... i'd pfrefer aiaf type fucusing on a little bit smaller area of the screen

 

Related Topics


SimplePortal 2.3.6 © 2008-2014, SimplePortal