Here's what I propose:
1. convert to gray image, enhancing the "difference from white"
gimg = min( img, [], 3 );
2. Threshold to remove white area
BW = im2bw( gimg, .4 );
3. Get area and centroid porperties of image regions
st = regionprops( ~BW, 'Area', 'Centroid', 'PixelIdxList' );
4. select only large enough regions
sel = [st.Area] > numel(BW)*0.025; % at least 2.5% of image size
st = st(sel);
5. compute region distance to center of image
cntr = .5 * [size(BW,2) size(BW,1)]; % X-Y coordinates and NOT Row/Col
d = sqrt( sum( bsxfun(@minus,vertcat( st.Centroid ), cntr ).^2, 2 ) );
6. pick the region closest to center
[mn idx] = min(d);
7. Create a mask
res = false(size(BW));
res( st(idx).PixelIdxList ) = true;
You might also consider using other region properties (e.g., 'Eccentricity'
) to better reject regions that are not circular.