Set Resolution

Discussions on GFL SDK, the graphic library for reading and writing graphic files

Moderators: XnTriq, xnview

Post Reply
tailormade
Posts: 15
Joined: Fri Jun 24, 2005 6:08 pm

Set Resolution

Post by tailormade »

I am using:

bitmap->Xdpi = Resolution;
bitmap->Ydpi = Resolution;

GFL_ERROR err = gflSaveBitmap( outf, bitmap, &saveparams);

to set the X and Y Resolution and then save the file. It works fine for JPEG, but for GIF I always get horizontal resolution of 384 dpi and vertical resolution of 96 dpi.

Any idea why? I have tried both V2.4 and 2.54.

Scott
User avatar
xnview
Author of XnView
Posts: 34093
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: Set Resolution

Post by xnview »

tailormade wrote:I am using:

bitmap->Xdpi = Resolution;
bitmap->Ydpi = Resolution;

GFL_ERROR err = gflSaveBitmap( outf, bitmap, &saveparams);

to set the X and Y Resolution and then save the file. It works fine for JPEG, but for GIF I always get horizontal resolution of 384 dpi and vertical resolution of 96 dpi.

Any idea why? I have tried both V2.4 and 2.54.

Scott
GIF doesn't store DPI info
Pierre.
Post Reply