whiteoctober / bauble

Image tracking with getUserMedia
MIT License
3 stars 0 forks source link

use SURF #2

Open benfoxall opened 10 years ago

benfoxall commented 10 years ago

from @rjmunro:

The SURF algorithm uses a transform it calls an integral image, where every pixel is replaced with the sum of all pixels above and to the left of it. You can then calculate the sum ( & therefore average) value of any area by subtracting the bottom left and top right pixels from the top left pixel and bottom right pixels.

https://en.wikipedia.org/wiki/SURF https://en.wikipedia.org/wiki/Integral_image

This could make it easy to check the number of pixels within the threshold for an area, and know if you have a good match on the ball.

rjmunro commented 10 years ago

Using the whole of SURF would probably be over the top and slow, but integral images might provide a nice way to help identify areas that have large numbers of pixels within the colour thresholds, I.e. areas where balls are.