#ifndef AVIFILE_FORMATS_H
#define AVIFILE_FORMATS_H
#ifdef WIN32
#define __attribute__()
#endif

#ifndef WIN32

#ifndef _WAVEFORMATEX_
#define _WAVEFORMATEX_

typedef struct __attribute__((__packed__)) _WAVEFORMATEX
{
    short   wFormatTag;
    short   nChannels;
    int     nSamplesPerSec;
    int     nAvgBytesPerSec;
    short   nBlockAlign;
    short   wBitsPerSample;
    short   cbSize;
} WAVEFORMATEX, *PWAVEFORMATEX, *NPWAVEFORMATEX, *LPWAVEFORMATEX;

#endif


#ifndef _BITMAPINFOHEADER_
#define _BITMAPINFOHEADER_
typedef struct __attribute__((__packed__))
{
    int 	biSize;
    int 	biWidth;
    int 	biHeight;
    short	biPlanes;
    short	biBitCount;
    int 	biCompression;
    int 	biSizeImage;
    int 	biXPelsPerMeter;
    int 	biYPelsPerMeter;
    int 	biClrUsed;
    int 	biClrImportant;
} BITMAPINFOHEADER, *PBITMAPINFOHEADER, *LPBITMAPINFOHEADER;

typedef struct
{
	BITMAPINFOHEADER bmiHeader;
	int	bmiColors[1];
} BITMAPINFO, *LPBITMAPINFO;
#endif /* _BITMAPINFOHEADER */
#else
#include <windows.h>
#include <wingdi.h>
#include <mmsystem.h>
#endif /* WIN32 */

#endif // AVIFILE_FORMATS_H
