Page 1 of 1

Image size in centimetres

Posted: Mon Sep 19, 2005 9:37 am
by Guest
Hi,

On loading the original and resized image in a database, I also want to save some relevant info about the original image in the database, such as the image size in centimeters, Xdpi, Ydpi etc. The purpose is to supply the users, compiling publications, some relevant info before downloading a large image.

In my program, I use the following statement to extract image information:
e := gflLoadBitmap(Pchar(ImageFilePathName), gfl_bmp, lp, finfo);

But the finfo structure supply only the following:
width (in pixels), height (in pixels), Xdpi and Ydpi

I noticed packages such as IrfanView and PainShop Pro displays a image’s size in cm.

How do I derive the height and width, in cm, from the XnView's image properties?


Regards,

Nols Smit

Re: Image size in centimetres

Posted: Mon Sep 19, 2005 10:20 am
by xnview
Anonymous wrote:Hi,

On loading the original and resized image in a database, I also want to save some relevant info about the original image in the database, such as the image size in centimeters, Xdpi, Ydpi etc. The purpose is to supply the users, compiling publications, some relevant info before downloading a large image.

In my program, I use the following statement to extract image information:
e := gflLoadBitmap(Pchar(ImageFilePathName), gfl_bmp, lp, finfo);

But the finfo structure supply only the following:
width (in pixels), height (in pixels), Xdpi and Ydpi

I noticed packages such as IrfanView and PainShop Pro displays a image’s size in cm.

How do I derive the height and width, in cm, from the XnView's image properties?
1 inch = 2.54 cm

Re: Image size in centimetres

Posted: Mon Sep 19, 2005 12:04 pm
by Nols Smit
xnview wrote:
Anonymous wrote:Hi,

On loading the original and resized image in a database, I also want to save some relevant info about the original image in the database, such as the image size in centimeters, Xdpi, Ydpi etc. The purpose is to supply the users, compiling publications, some relevant info before downloading a large image.

In my program, I use the following statement to extract image information:
e := gflLoadBitmap(Pchar(ImageFilePathName), gfl_bmp, lp, finfo);

But the finfo structure supply only the following:
width (in pixels), height (in pixels), Xdpi and Ydpi

I noticed packages such as IrfanView and PainShop Pro displays a image’s size in cm.

How do I derive the height and width, in cm, from the XnView's image properties?
1 inch = 2.54 cm
Which structure element give the image size in cm?

Nols Smit

Re: Image size in centimetres

Posted: Mon Sep 19, 2005 1:20 pm
by xnview
Nols Smit wrote:Which structure element give the image size in cm?
You have Width/Height and XDPI/YDPI