0

I am trying measure real object height from an image. I'm using the below formula

$$ \text{real height [mm]} = \frac{\text{object height [px]}\times \text{pixel size }\left[\mathrm{mm\over px}\right]\times \text{distance [mm]}}{\text{focal length [mm]}} $$

My camera is a Canon EOS 550D. My values are below:

  • sensor size: 22.3 x 14.9 mm
  • focal length: 30 mm
  • distance to object: 1000 mm
  • pixel height: 1201

I applied values in this equation but I cannot measure object.

scottbb
  • 32,685
  • 12
  • 104
  • 188
Arun
  • 1
  • To calculate the pixel size you also need the image pixel height. – Guffa Jun 07 '14 at 09:43
  • thanks for your reply ,my object pixel height =802 i converted to mm =212.2 mm then( 16mm(sensor size aprox)212.2(mm)1000(mm,distance)/30mm(focal length) can you please advice me about my mistake – Arun Jun 07 '14 at 09:58
  • Check this question http://photo.stackexchange.com/questions/23414/can-we-measure-size-of-an-object-using-exif-data-from-a-photo – Hugo Jun 07 '14 at 10:02
  • Thanks for reply, one doubt i checked sensor size of Canon_EOS_550D find out 22.3 x 14.9 mm,how can i use this value in equation,eg 22.3*14.9 or? – Arun Jun 07 '14 at 10:12
  • below equation also i tried but i did not get actual measurement (2distance(sensor size / focal length)) / number of pixels (21000(mm)(22.3*14.9(mm))/30mm))/802 can you please help me – Arun Jun 07 '14 at 10:49
  • We have a lot of similar questions already. Please search before asking a new one. – mattdm Jun 07 '14 at 12:35
  • 1
    802 pixels can't convert to 212.2 mm, as the sensor is only 14.9 mm high. You need the image height in pixels so that you can calculate the size of a pixel. If the image height is for example 3000 pixels, 802*14.9/3000 = 3.98 mm. – Guffa Jun 07 '14 at 15:32

1 Answers1

0

The correct formula is this:

$$ \text{obj. height [units]} = \text{distance [units]} \times \frac{\text{obj. height [px]}}{\text{img height [px]}} \times \frac{\text{sensor height [mm]}}{\text{focal length [mm]}} $$

In your case, you are missing the image height in pixels:

$$ \text{obj. height [mm]} = 1000\,[\mathrm{mm}]\times \frac{1201\,[\mathrm{px}]}{\text{IMAGE [px]}} \times \frac{14.9\,[\mathrm{mm}]}{30\,[\mathrm{mm}]} $$

scottbb
  • 32,685
  • 12
  • 104
  • 188
Rado
  • 157
  • 8