#ifndef     _YUVN_H
#define     _YUVN_H

#ifndef     _IFF_H
#include    _IFF_H
#endif

#ifndef     EXEC_TYPES_H
#include    <exec/types.h>
#endif



/* ID's used in FORM YUVN:      */
#define ID_YUVN MakeID('Y','U','V','N')     /* the FORM-ID          */
#define ID_YCHD MakeID('Y','C','H','D')     /* the header-chunk-ID  */
#define ID_DATY MakeID('D','A','T','Y')     /* the Y-data-chunk-ID  */
#define ID_DATU MakeID('D','A','T','U')     /* the U-data-chunk-ID  */
#define ID_DATV MakeID('D','A','T','V')     /* the V-data-chunk-ID  */

/* values for ychd_AspectX and ychd_AspectY:    */

/* values for ychd_Compress:    */
#define COMPRESS_NONE   0                   /* no compression   */

/* values for ychd_Flags:       */
#define YCHDB_LACE  0                       /* if set the data-chunks contain       */
#define YCHDF_LACE  0                       /* a full-frame (interlaced) picture    */

/* values for ychd_Mode:        */
#define YCHD_MODE_BW        0       /* OBSOLETE, use YCHD_MODE_400 instead          */
#define YCHD_MODE_400       0       /* a black-and-white picture (no DATU and DATV) */
#define YCHD_MODE_411       1       /* a YUV-411 picture                            */
#define YCHD_MODE_422       2       /* a YUV-422 picture                            */
#define YCHD_MODE_444       3       /* a YUV-444 picture                            */

#define YCHD_MODE_200       8       /* a lores black-and-white picture              */
#define YCHD_MODE_211       9       /* a lores color picture (422, but lores)       */
#define YCHD_MODE_222      10       /* a lores color picture (444, but lores)       */

#define YCHD_MODEB_LORES    3       /* test this bit to check for lores/hires       */
#define YCHD_MODEF_LORES    8

/* values for ychd_Norm:        */
#define YCHD_NORM_UNKNOWN    0      /* unknown, try to avoid this                   */
#define YCHD_NORM_PAL        1      /* PAL 4.433 MHz                                */
#define YCHD_NORM_NTSC       2      /* NTSC 3.579 MHz                               */

/* the FORM-YUVN Header: YCHD   */

struct YCHD
{
    UWORD     ychd_Width;           /* picture width in Y-pixels                */
    UWORD     ychd_Height;          /* picture height (rows)                    */

    UWORD     ychd_PageWidth;       /* source page width & height,              */
    UWORD     ychd_PageHeight;      /*   currently same as Width and Height     */

    UWORD     ychd_LeftEdge;        /* position within the source page,         */
    UWORD     ychd_TopEdge;         /*   currently 0,0                          */

    UBYTE     ychd_AspectX;         /* pixel aspect (width : height)            */
    UBYTE     ychd_AspectY;

    UBYTE     ychd_Compress;        /* (see above)  */
    UBYTE     ychd_Flags;           /* (see above)  */

    UBYTE     ychd_Mode;            /* (see above)  */
    UBYTE     ychd_Norm;            /* (see above)  */

    WORD      ychd_reserved2;       /* must be 0
    LONG      ychd_reserved3;       /* must be 0
};


#endif
