MATLAB Answers

0

bitmap size and file size

Asked by Renjith V Ravi on 3 Mar 2017
Latest activity Commented on by Walter Roberson
on 4 Mar 2017
When I run the code shown in the link http://in.mathworks.com/matlabcentral/fileexchange/13584-compression-ratio, i got the output
Among these what is the difference between ' FileSize ' and ' BitmapSize ' .How this FileSize is calculated here. The formula for compression ratio is also here.

  0 Comments

Sign in to comment.

1 Answer

Answer by Walter Roberson
on 3 Mar 2017
 Accepted Answer

"How this FileSize is calculated here."
Record the output of dir() of the file. Access the "bytes" field of the result.
"' BitmapSize '"
Bitmapsize is Height time Width.
"The formula for compression ratio is also here."

  3 Comments

Is there any unit for the ' FileSize ' in above example
Bytes.
Note that for compression calculations you need to know the number of channels per pixel and the number of bits per channel per pixel.

Sign in to comment.