Code covered by the BSD License  

Highlights from
Circle Detection Using Hough Transforms

image thumbnail
from Circle Detection Using Hough Transforms by Kobi Nistel
Finds circles of any radii in a image.

cfresize(im, longDimSize)
function [im scale] = cfresize(im, longDimSize)
%CFRESIZE resize the image if its long dimension is bigger then longDimSize 
%   [im scale] = cfresize(im,longDimSize); scales the image so its long 
%   dimension is logDimSize long. (only if its bigger)   

s = size(im);
scale = min(longDimSize/max(s),1);
im = imresize(im, scale);

Contact us