Skip to main content
1 of 2
juanli
  • 131
  • 1
  • 6

BITMAPFILEHEADER bf in resize.c

typedef struct 
{ 
WORD bfType; 
DWORD bfSize; 
WORD bfReserved1; 
WORD bfReserved2; 
DWORD bfOffBits; 
} __attribute__((__packed__)) 
BITMAPFILEHEADER; 

And then in the resize.c:

BITMAPFILEHEADER bf
fread(&bf, sizeof(BITMAPFILEHEADER), 1, inptr);

I want to know some reference to run

BITMAPFILEHEADER bf

get a shorthand for BITMAPFILEHEADER?

I only know

typedef <oldname> <newname>  

How comes, just works?

Thanks in advance for any help of clarifying this point for me.

juanli
  • 131
  • 1
  • 6