GetJPEGFileInfo

#include "BIJPEG.H"

int FAR PASCAL GetJPEGFileInfo( LPTSTR       lpFileName,
JCompressInfo FAR*       lpInfo);

Description

Reads the JPEG compression information from a file.

Parameters

LPTSTR

lpFileName

Pointer to the file name string.

JCompressInfo FAR

* lpInfo

Far pointer to JCompressInfo structure.

 

typedef struct tagJCompressInfo

{

WORD

wWidth;

Width of image.

WORD

wHeight;

Height of image.

DWORD

dwXRes;

Image X Resolution in Pixel per meter.

DWORD

dwYRes;

Image Y Resolution  in Pixel per meter.

WORD

wQuality;

Not filled - Quality factor not stored in JPEG file.

WORD

wColors;

Output colors 1 or 3.

1 - Input lines 8 pit per pixel grayscale.

3 - Input lines 24 bit per pixel true color.

BOOL

bGrayOutput;

Not used.

WORD

wXSubSampling;

Crominance components horizontal subsampling 1-2.

WORD

wYSubSampling;

Crominance component vertical subsampling 1-2.

WORD

wRestartInterval;

JPEG coder restart interval 0-65535.

WORD

wHeaderType;

JPEG Application Marker type.

JHDR_JFIF - JPEG Interchange file format using YCbCr color model.

JHDR_G3FAX - CCITT T.4E JPEG File format using Lab color model.

INT_PTR

lUserData;

Not used.

FILLPROC

lpLineFn;

Not used.

BOOL

bHPLabColor

Lab marker.

BOOL

bDNL

DNL marker.

} JCompressInfo;

Additional Information

This example shows how to use the dll when loading statically including the header file. Otherwise if the dll is loaded dynamically, for further information read the “About the difference of static and dynamic library loading” section of the manual.

Return values

Returns 0 on success, error code if failed.

Requirements

Header :     Declared in BiJpeg.h; include BiJpeg.h.

Library :    Use BiJpeg.lib.

DLLs :       BiJpeg.dll.