
Getting the size of a bitmap
You can use GetDeviceCaps() to get:
HORZSIZE Width, in millimeters, of the physical screen.
VERTSIZE Height, in millimeters, of the physical screen.
HORZRES Width, in pixels, of the screen.
VERTRES Height, in raster lines, of the screen.
This info, along with the x and y resolution of the bitmap, should get you
what you need.
Hope this helps,
Mike.
Quote:
> Hello,
> I need to find a way to locate the size of a bitmap in inches or
> centimeters. I have tried checking BITMAPINFOHEADER biXPel{*filter*}eter, but
it
> seems to vary, depending on the screen resolution. Is there a way to
> determine, based on whatever the current screen resolution is, how big
the
> image will be?
> The purpose of this is to display the bitmap over an area of a
> predefined size, say ten inches. That way the user can see how big the
> bitmap is, in comparison to the ten inch area.
> Any ideas or suggestions would be very helpful. Thanks in advance.
> http://www.*-*-*.com/