Obtaining the size of objects from an image
I would use a split-and-merge algorithm for segmenting and then simply count the pixel per segment. Details are provided here

Two assumptions are neccessary: 

1) you objects do not overlap.

2) the picture does not have any background or further irrelevant objects