ReactOS Fundraising Campaign 2012
 
€ 4,410 / € 30,000

Information | Donate

Home | Info | Community | Development | myReactOS | Contact Us

  1. Home
  2. Community
  3. Development
  4. myReactOS
  5. Fundraiser 2012

  1. Main Page
  2. Alphabetical List
  3. Data Structures
  4. Directories
  5. File List
  6. Data Fields
  7. Globals
  8. Related Pages

ReactOS Development > Doxygen

vfw.h
Go to the documentation of this file.
00001 /*
00002  * Copyright (C) the Wine project
00003  *
00004  * This library is free software; you can redistribute it and/or
00005  * modify it under the terms of the GNU Lesser General Public
00006  * License as published by the Free Software Foundation; either
00007  * version 2.1 of the License, or (at your option) any later version.
00008  *
00009  * This library is distributed in the hope that it will be useful,
00010  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00011  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00012  * Lesser General Public License for more details.
00013  *
00014  * You should have received a copy of the GNU Lesser General Public
00015  * License along with this library; if not, write to the Free Software
00016  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
00017  */
00018 
00019 #ifndef __WINE_VFW_H
00020 #define __WINE_VFW_H
00021 
00022 #include <mmsystem.h>
00023 #include <mmreg.h>
00024 #include <msacm.h>
00025 
00026 #define VFWAPI  WINAPI
00027 #define VFWAPIV WINAPIV
00028 
00029 #ifdef __cplusplus
00030 extern "C" {
00031 #endif  /* __cplusplus */
00032 
00033 typedef HANDLE HDRAWDIB;
00034 
00035 /*****************************************************************************
00036  * Predeclare the interfaces
00037  */
00038 typedef struct IAVIStream *PAVISTREAM;
00039 typedef struct IAVIFile *PAVIFILE;
00040 typedef struct IGetFrame *PGETFRAME;
00041 typedef struct IAVIEditStream *PAVIEDITSTREAM;
00042 
00043 /* Installable Compressor Manager */
00044 
00045 #define ICVERSION 0x0104
00046 
00047 DECLARE_HANDLE(HIC);
00048 
00049 /* error return codes */
00050 #define ICERR_OK        0
00051 #define ICERR_DONTDRAW      1
00052 #define ICERR_NEWPALETTE    2
00053 #define ICERR_GOTOKEYFRAME  3
00054 #define ICERR_STOPDRAWING   4
00055 
00056 #define ICERR_UNSUPPORTED   -1
00057 #define ICERR_BADFORMAT     -2
00058 #define ICERR_MEMORY        -3
00059 #define ICERR_INTERNAL      -4
00060 #define ICERR_BADFLAGS      -5
00061 #define ICERR_BADPARAM      -6
00062 #define ICERR_BADSIZE       -7
00063 #define ICERR_BADHANDLE     -8
00064 #define ICERR_CANTUPDATE    -9
00065 #define ICERR_ABORT     -10
00066 #define ICERR_ERROR     -100
00067 #define ICERR_BADBITDEPTH   -200
00068 #define ICERR_BADIMAGESIZE  -201
00069 
00070 #define ICERR_CUSTOM        -400
00071 
00072 /* ICM Messages */
00073 #define ICM_USER        (DRV_USER+0x0000)
00074 
00075 /* ICM driver message range */
00076 #define ICM_RESERVED_LOW    (DRV_USER+0x1000)
00077 #define ICM_RESERVED_HIGH   (DRV_USER+0x2000)
00078 #define ICM_RESERVED        ICM_RESERVED_LOW
00079 
00080 #define ICM_GETSTATE        (ICM_RESERVED+0)
00081 #define ICM_SETSTATE        (ICM_RESERVED+1)
00082 #define ICM_GETINFO     (ICM_RESERVED+2)
00083 
00084 #define ICM_CONFIGURE       (ICM_RESERVED+10)
00085 #define ICM_ABOUT       (ICM_RESERVED+11)
00086 /* */
00087 
00088 #define ICM_GETDEFAULTQUALITY   (ICM_RESERVED+30)
00089 #define ICM_GETQUALITY      (ICM_RESERVED+31)
00090 #define ICM_SETQUALITY      (ICM_RESERVED+32)
00091 
00092 #define ICM_SET         (ICM_RESERVED+40)
00093 #define ICM_GET         (ICM_RESERVED+41)
00094 
00095 /* 2 constant FOURCC codes */
00096 #define ICM_FRAMERATE       mmioFOURCC('F','r','m','R')
00097 #define ICM_KEYFRAMERATE    mmioFOURCC('K','e','y','R')
00098 
00099 #define ICM_COMPRESS_GET_FORMAT     (ICM_USER+4)
00100 #define ICM_COMPRESS_GET_SIZE       (ICM_USER+5)
00101 #define ICM_COMPRESS_QUERY      (ICM_USER+6)
00102 #define ICM_COMPRESS_BEGIN      (ICM_USER+7)
00103 #define ICM_COMPRESS            (ICM_USER+8)
00104 #define ICM_COMPRESS_END        (ICM_USER+9)
00105 
00106 #define ICM_DECOMPRESS_GET_FORMAT   (ICM_USER+10)
00107 #define ICM_DECOMPRESS_QUERY        (ICM_USER+11)
00108 #define ICM_DECOMPRESS_BEGIN        (ICM_USER+12)
00109 #define ICM_DECOMPRESS          (ICM_USER+13)
00110 #define ICM_DECOMPRESS_END      (ICM_USER+14)
00111 #define ICM_DECOMPRESS_SET_PALETTE  (ICM_USER+29)
00112 #define ICM_DECOMPRESS_GET_PALETTE  (ICM_USER+30)
00113 
00114 #define ICM_DRAW_QUERY          (ICM_USER+31)
00115 #define ICM_DRAW_BEGIN          (ICM_USER+15)
00116 #define ICM_DRAW_GET_PALETTE        (ICM_USER+16)
00117 #define ICM_DRAW_START          (ICM_USER+18)
00118 #define ICM_DRAW_STOP           (ICM_USER+19)
00119 #define ICM_DRAW_END            (ICM_USER+21)
00120 #define ICM_DRAW_GETTIME        (ICM_USER+32)
00121 #define ICM_DRAW            (ICM_USER+33)
00122 #define ICM_DRAW_WINDOW         (ICM_USER+34)
00123 #define ICM_DRAW_SETTIME        (ICM_USER+35)
00124 #define ICM_DRAW_REALIZE        (ICM_USER+36)
00125 #define ICM_DRAW_FLUSH          (ICM_USER+37)
00126 #define ICM_DRAW_RENDERBUFFER       (ICM_USER+38)
00127 
00128 #define ICM_DRAW_START_PLAY     (ICM_USER+39)
00129 #define ICM_DRAW_STOP_PLAY      (ICM_USER+40)
00130 
00131 #define ICM_DRAW_SUGGESTFORMAT      (ICM_USER+50)
00132 #define ICM_DRAW_CHANGEPALETTE      (ICM_USER+51)
00133 
00134 #define ICM_GETBUFFERSWANTED        (ICM_USER+41)
00135 
00136 #define ICM_GETDEFAULTKEYFRAMERATE  (ICM_USER+42)
00137 
00138 #define ICM_DECOMPRESSEX_BEGIN      (ICM_USER+60)
00139 #define ICM_DECOMPRESSEX_QUERY      (ICM_USER+61)
00140 #define ICM_DECOMPRESSEX        (ICM_USER+62)
00141 #define ICM_DECOMPRESSEX_END        (ICM_USER+63)
00142 
00143 #define ICM_COMPRESS_FRAMES_INFO    (ICM_USER+70)
00144 #define ICM_SET_STATUS_PROC     (ICM_USER+72)
00145 
00146 #ifndef comptypeDIB
00147 #define comptypeDIB  mmioFOURCC('D','I','B',' ')
00148 #endif
00149 
00150 /* structs */
00151 
00152 /* NOTE: Only the 16 bit structs are packed. Structs that are packed anyway
00153  * have not been changed. If a structure is later extended, you may need to create
00154  * two versions of it.
00155  */
00156 
00157 typedef struct {
00158     DWORD   dwSize;     /* 00: size */
00159     DWORD   fccType;    /* 04: type 'vidc' usually */
00160     DWORD   fccHandler; /* 08: */
00161     DWORD   dwVersion;  /* 0c: version of compman opening you */
00162     DWORD   dwFlags;    /* 10: LOWORD is type specific */
00163     LRESULT dwError;    /* 14: */
00164     LPVOID  pV1Reserved;    /* 18: */
00165     LPVOID  pV2Reserved;    /* 1c: */
00166     DWORD   dnDevNode;  /* 20: */
00167                 /* 24: */
00168 } ICOPEN,*LPICOPEN;
00169 
00170 #define ICCOMPRESS_KEYFRAME     0x00000001L
00171 
00172 typedef struct {
00173     DWORD       dwFlags;
00174     LPBITMAPINFOHEADER  lpbiOutput;
00175     LPVOID      lpOutput;
00176     LPBITMAPINFOHEADER  lpbiInput;
00177     LPVOID      lpInput;
00178     LPDWORD     lpckid;
00179     LPDWORD     lpdwFlags;
00180     LONG        lFrameNum;
00181     DWORD       dwFrameSize;
00182     DWORD       dwQuality;
00183     LPBITMAPINFOHEADER  lpbiPrev;
00184     LPVOID      lpPrev;
00185 } ICCOMPRESS;
00186 
00187 DWORD VFWAPIV ICCompress(
00188     HIC hic,DWORD dwFlags,LPBITMAPINFOHEADER lpbiOutput,LPVOID lpData,
00189     LPBITMAPINFOHEADER lpbiInput,LPVOID lpBits,LPDWORD lpckid,
00190     LPDWORD lpdwFlags,LONG lFrameNum,DWORD dwFrameSize,DWORD dwQuality,
00191     LPBITMAPINFOHEADER lpbiPrev,LPVOID lpPrev
00192 );
00193 
00194 #define ICCompressGetFormat(hic, lpbiInput, lpbiOutput)         \
00195     ICSendMessage(                          \
00196         hic,ICM_COMPRESS_GET_FORMAT,(DWORD_PTR)(LPVOID)(lpbiInput), \
00197         (DWORD_PTR)(LPVOID)(lpbiOutput)                 \
00198     )
00199 
00200 #define ICCompressGetFormatSize(hic,lpbi) ICCompressGetFormat(hic,lpbi,NULL)
00201 
00202 #define ICCompressBegin(hic, lpbiInput, lpbiOutput)             \
00203     ICSendMessage(                          \
00204         hic, ICM_COMPRESS_BEGIN, (DWORD_PTR)(LPVOID)(lpbiInput),        \
00205     (DWORD_PTR)(LPVOID)(lpbiOutput)                 \
00206     )
00207 
00208 #define ICCompressGetSize(hic, lpbiInput, lpbiOutput)           \
00209     ICSendMessage(                          \
00210         hic, ICM_COMPRESS_GET_SIZE, (DWORD_PTR)(LPVOID)(lpbiInput),     \
00211     (DWORD_PTR)(LPVOID)(lpbiOutput)                 \
00212     )
00213 
00214 #define ICCompressQuery(hic, lpbiInput, lpbiOutput)     \
00215     ICSendMessage(                      \
00216         hic, ICM_COMPRESS_QUERY, (DWORD_PTR)(LPVOID)(lpbiInput),    \
00217     (DWORD_PTR)(LPVOID)(lpbiOutput)             \
00218     )
00219 
00220 #define ICCompressEnd(hic) ICSendMessage(hic, ICM_COMPRESS_END, 0, 0)
00221 
00222 /* ICCOMPRESSFRAMES.dwFlags */
00223 #define ICCOMPRESSFRAMES_PADDING        0x00000001
00224 typedef struct {
00225     DWORD               dwFlags;
00226     LPBITMAPINFOHEADER  lpbiOutput;
00227     LPARAM              lOutput;
00228     LPBITMAPINFOHEADER  lpbiInput;
00229     LPARAM              lInput;
00230     LONG                lStartFrame;
00231     LONG                lFrameCount;
00232     LONG                lQuality;
00233     LONG                lDataRate;
00234     LONG                lKeyRate;
00235     DWORD               dwRate;
00236     DWORD               dwScale;
00237     DWORD               dwOverheadPerFrame;
00238     DWORD               dwReserved2;
00239     LONG (CALLBACK *GetData)(LPARAM lInput,LONG lFrame,LPVOID lpBits,LONG len);
00240     LONG (CALLBACK *PutData)(LPARAM lOutput,LONG lFrame,LPVOID lpBits,LONG len);
00241 } ICCOMPRESSFRAMES;
00242 
00243 typedef struct {
00244     DWORD       dwFlags;
00245     LPARAM      lParam;
00246    /* messages for Status callback */
00247 #define ICSTATUS_START      0
00248 #define ICSTATUS_STATUS     1
00249 #define ICSTATUS_END        2
00250 #define ICSTATUS_ERROR      3
00251 #define ICSTATUS_YIELD      4
00252     /* FIXME: some X11 libs define Status as int... */
00253     /* LONG (CALLBACK *zStatus)(LPARAM lParam, UINT message, LONG l); */
00254     LONG (CALLBACK *zStatus)(LPARAM lParam, UINT message, LONG l);
00255 } ICSETSTATUSPROC;
00256 
00257 /* Values for wMode of ICOpen() */
00258 #define ICMODE_COMPRESS     1
00259 #define ICMODE_DECOMPRESS   2
00260 #define ICMODE_FASTDECOMPRESS   3
00261 #define ICMODE_QUERY        4
00262 #define ICMODE_FASTCOMPRESS 5
00263 #define ICMODE_DRAW     8
00264 
00265 /* quality flags */
00266 #define ICQUALITY_LOW       0
00267 #define ICQUALITY_HIGH      10000
00268 #define ICQUALITY_DEFAULT   -1
00269 
00270 typedef struct {
00271     DWORD   dwSize;     /* 00: */
00272     DWORD   fccType;    /* 04:compressor type     'vidc' 'audc' */
00273     DWORD   fccHandler; /* 08:compressor sub-type 'rle ' 'jpeg' 'pcm '*/
00274     DWORD   dwFlags;    /* 0c:flags LOWORD is type specific */
00275     DWORD   dwVersion;  /* 10:version of the driver */
00276     DWORD   dwVersionICM;   /* 14:version of the ICM used */
00277     /*
00278      * under Win32, the driver always returns UNICODE strings.
00279      */
00280     WCHAR   szName[16];     /* 18:short name */
00281     WCHAR   szDescription[128]; /* 38:long name */
00282     WCHAR   szDriver[128];      /* 138:driver that contains compressor*/
00283                     /* 238: */
00284 } ICINFO;
00285 
00286 /* ICINFO.dwFlags */
00287 #define VIDCF_QUALITY       0x0001  /* supports quality */
00288 #define VIDCF_CRUNCH        0x0002  /* supports crunching to a frame size */
00289 #define VIDCF_TEMPORAL      0x0004  /* supports inter-frame compress */
00290 #define VIDCF_COMPRESSFRAMES    0x0008  /* wants the compress all frames message */
00291 #define VIDCF_DRAW      0x0010  /* supports drawing */
00292 #define VIDCF_FASTTEMPORALC 0x0020  /* does not need prev frame on compress */
00293 #define VIDCF_FASTTEMPORALD 0x0080  /* does not need prev frame on decompress */
00294 #define VIDCF_QUALITYTIME   0x0040  /* supports temporal quality */
00295 
00296 #define VIDCF_FASTTEMPORAL  (VIDCF_FASTTEMPORALC|VIDCF_FASTTEMPORALD)
00297 
00298 
00299 /* function shortcuts */
00300 /* ICM_ABOUT */
00301 #define ICMF_ABOUT_QUERY         0x00000001
00302 
00303 #define ICQueryAbout(hic) \
00304     (ICSendMessage(hic,ICM_ABOUT,(DWORD_PTR)-1,ICMF_ABOUT_QUERY)==ICERR_OK)
00305 
00306 #define ICAbout(hic, hwnd) ICSendMessage(hic,ICM_ABOUT,(DWORD_PTR)(UINT_PTR)(hwnd),0)
00307 
00308 /* ICM_CONFIGURE */
00309 #define ICMF_CONFIGURE_QUERY    0x00000001
00310 #define ICQueryConfigure(hic) \
00311     (ICSendMessage(hic,ICM_CONFIGURE,(DWORD_PTR)-1,ICMF_CONFIGURE_QUERY)==ICERR_OK)
00312 
00313 #define ICConfigure(hic,hwnd) \
00314     ICSendMessage(hic,ICM_CONFIGURE,(DWORD_PTR)(UINT_PTR)(hwnd),0)
00315 
00316 /* Decompression stuff */
00317 #define ICDECOMPRESS_HURRYUP        0x80000000  /* don't draw just buffer (hurry up!) */
00318 #define ICDECOMPRESS_UPDATE     0x40000000  /* don't draw just update screen */
00319 #define ICDECOMPRESS_PREROLL        0x20000000  /* this frame is before real start */
00320 #define ICDECOMPRESS_NULLFRAME      0x10000000  /* repeat last frame */
00321 #define ICDECOMPRESS_NOTKEYFRAME    0x08000000  /* this frame is not a key frame */
00322 
00323 typedef struct {
00324     DWORD       dwFlags;    /* flags (from AVI index...) */
00325     LPBITMAPINFOHEADER  lpbiInput;  /* BITMAPINFO of compressed data */
00326     LPVOID      lpInput;    /* compressed data */
00327     LPBITMAPINFOHEADER  lpbiOutput; /* DIB to decompress to */
00328     LPVOID      lpOutput;
00329     DWORD       ckid;       /* ckid from AVI file */
00330 } ICDECOMPRESS;
00331 
00332 typedef struct {
00333     DWORD       dwFlags;
00334     LPBITMAPINFOHEADER  lpbiSrc;
00335     LPVOID      lpSrc;
00336     LPBITMAPINFOHEADER  lpbiDst;
00337     LPVOID      lpDst;
00338 
00339     /* changed for ICM_DECOMPRESSEX */
00340     INT         xDst;       /* destination rectangle */
00341     INT         yDst;
00342     INT         dxDst;
00343     INT         dyDst;
00344 
00345     INT         xSrc;       /* source rectangle */
00346     INT         ySrc;
00347     INT         dxSrc;
00348     INT         dySrc;
00349 } ICDECOMPRESSEX;
00350 
00351 DWORD VFWAPIV ICDecompress(HIC hic,DWORD dwFlags,LPBITMAPINFOHEADER lpbiFormat,LPVOID lpData,LPBITMAPINFOHEADER lpbi,LPVOID lpBits);
00352 
00353 #define ICDecompressBegin(hic, lpbiInput, lpbiOutput)   \
00354     ICSendMessage(                      \
00355         hic, ICM_DECOMPRESS_BEGIN, (DWORD_PTR)(LPVOID)(lpbiInput),  \
00356     (DWORD_PTR)(LPVOID)(lpbiOutput)             \
00357     )
00358 
00359 #define ICDecompressQuery(hic, lpbiInput, lpbiOutput)   \
00360     ICSendMessage(                      \
00361         hic,ICM_DECOMPRESS_QUERY, (DWORD_PTR)(LPVOID)(lpbiInput),   \
00362     (DWORD_PTR) (LPVOID)(lpbiOutput)                \
00363     )
00364 
00365 #define ICDecompressGetFormat(hic, lpbiInput, lpbiOutput)       \
00366     ((LONG)ICSendMessage(                       \
00367         hic,ICM_DECOMPRESS_GET_FORMAT, (DWORD_PTR)(LPVOID)(lpbiInput),  \
00368     (DWORD_PTR)(LPVOID)(lpbiOutput)                 \
00369     ))
00370 
00371 #define ICDecompressGetFormatSize(hic, lpbi)                \
00372     ICDecompressGetFormat(hic, lpbi, NULL)
00373 
00374 #define ICDecompressGetPalette(hic, lpbiInput, lpbiOutput)      \
00375     ICSendMessage(                          \
00376         hic, ICM_DECOMPRESS_GET_PALETTE, (DWORD_PTR)(LPVOID)(lpbiInput),    \
00377     (DWORD_PTR)(LPVOID)(lpbiOutput)                 \
00378     )
00379 
00380 #define ICDecompressSetPalette(hic,lpbiPalette) \
00381         ICSendMessage(              \
00382         hic,ICM_DECOMPRESS_SET_PALETTE,     \
00383         (DWORD_PTR)(LPVOID)(lpbiPalette),0      \
00384     )
00385 
00386 #define ICDecompressEnd(hic) ICSendMessage(hic, ICM_DECOMPRESS_END, 0, 0)
00387 
00388 LRESULT VFWAPI  ICSendMessage(HIC hic, UINT msg, DWORD_PTR dw1, DWORD_PTR dw2);
00389 
00390 static inline LRESULT VFWAPI ICDecompressEx(HIC hic, DWORD dwFlags,
00391                         LPBITMAPINFOHEADER lpbiSrc, LPVOID lpSrc,
00392                         int xSrc, int ySrc, int dxSrc, int dySrc,
00393                         LPBITMAPINFOHEADER lpbiDst, LPVOID lpDst,
00394                         int xDst, int yDst, int dxDst, int dyDst)
00395 {
00396     ICDECOMPRESSEX ic;
00397 
00398     ic.dwFlags = dwFlags;
00399     ic.lpbiSrc = lpbiSrc;
00400     ic.lpSrc = lpSrc;
00401     ic.xSrc = xSrc;
00402     ic.ySrc = ySrc;
00403     ic.dxSrc = dxSrc;
00404     ic.dySrc = dySrc;
00405     ic.lpbiDst = lpbiDst;
00406     ic.lpDst = lpDst;
00407     ic.xDst = xDst;
00408     ic.yDst = yDst;
00409     ic.dxDst = dxDst;
00410     ic.dyDst = dyDst;
00411     return ICSendMessage(hic, ICM_DECOMPRESSEX, (DWORD_PTR)&ic, sizeof(ic));
00412 }
00413 
00414 static inline LRESULT VFWAPI ICDecompressExBegin(HIC hic, DWORD dwFlags,
00415                          LPBITMAPINFOHEADER lpbiSrc,
00416                          LPVOID lpSrc,
00417                          int xSrc, int ySrc, int dxSrc, int dySrc,
00418                          LPBITMAPINFOHEADER lpbiDst,
00419                          LPVOID lpDst,
00420                          int xDst,
00421                          int yDst,
00422                          int dxDst,
00423                          int dyDst)
00424 {
00425     ICDECOMPRESSEX ic;
00426 
00427     ic.dwFlags = dwFlags;
00428     ic.lpbiSrc = lpbiSrc;
00429     ic.lpSrc = lpSrc;
00430     ic.xSrc = xSrc;
00431     ic.ySrc = ySrc;
00432     ic.dxSrc = dxSrc;
00433     ic.dySrc = dySrc;
00434     ic.lpbiDst = lpbiDst;
00435     ic.lpDst = lpDst;
00436     ic.xDst = xDst;
00437     ic.yDst = yDst;
00438     ic.dxDst = dxDst;
00439     ic.dyDst = dyDst;
00440     return ICSendMessage(hic, ICM_DECOMPRESSEX_BEGIN, (DWORD_PTR)&ic, sizeof(ic));
00441 }
00442 static inline LRESULT VFWAPI ICDecompressExQuery(HIC hic, DWORD dwFlags,
00443                          LPBITMAPINFOHEADER lpbiSrc,
00444                          LPVOID lpSrc,
00445                          int xSrc, int ySrc, int dxSrc, int dySrc,
00446                          LPBITMAPINFOHEADER lpbiDst,
00447                          LPVOID lpDst,
00448                          int xDst,
00449                          int yDst,
00450                          int dxDst,
00451                          int dyDst)
00452 {
00453     ICDECOMPRESSEX ic;
00454 
00455     ic.dwFlags = dwFlags;
00456     ic.lpbiSrc = lpbiSrc;
00457     ic.lpSrc = lpSrc;
00458     ic.xSrc = xSrc;
00459     ic.ySrc = ySrc;
00460     ic.dxSrc = dxSrc;
00461     ic.dySrc = dySrc;
00462     ic.lpbiDst = lpbiDst;
00463     ic.lpDst = lpDst;
00464     ic.xDst = xDst;
00465     ic.yDst = yDst;
00466     ic.dxDst = dxDst;
00467     ic.dyDst = dyDst;
00468     return ICSendMessage(hic, ICM_DECOMPRESSEX_QUERY, (DWORD_PTR)&ic, sizeof(ic));
00469 }
00470 
00471 #define ICDecompressExEnd(hic) \
00472     ICSendMessage(hic, ICM_DECOMPRESSEX_END, 0, 0)
00473 
00474 #define ICDRAW_QUERY        0x00000001L   /* test for support */
00475 #define ICDRAW_FULLSCREEN   0x00000002L   /* draw to full screen */
00476 #define ICDRAW_HDC          0x00000004L   /* draw to a HDC/HWND */
00477 #define ICDRAW_ANIMATE      0x00000008L   /* expect palette animation */
00478 #define ICDRAW_CONTINUE     0x00000010L   /* draw is a continuation of previous draw */
00479 #define ICDRAW_MEMORYDC     0x00000020L   /* DC is offscreen, by the way */
00480 #define ICDRAW_UPDATING     0x00000040L   /* We're updating, as opposed to playing */
00481 #define ICDRAW_RENDER       0x00000080L   /* used to render data not draw it */
00482 #define ICDRAW_BUFFER       0x00000100L   /* buffer data offscreen, we will need to update it */
00483 
00484 #define ICDecompressOpen(fccType, fccHandler, lpbiIn, lpbiOut) \
00485     ICLocate(fccType, fccHandler, lpbiIn, lpbiOut, ICMODE_DECOMPRESS)
00486 
00487 #define ICDrawOpen(fccType, fccHandler, lpbiIn) \
00488     ICLocate(fccType, fccHandler, lpbiIn, NULL, ICMODE_DRAW)
00489 
00490 HANDLE VFWAPI ICImageCompress(HIC hic, UINT uiFlags, LPBITMAPINFO lpbiIn,
00491                   LPVOID lpBits, LPBITMAPINFO lpbiOut, LONG lQuality,
00492                   LONG* plSize);
00493 
00494 HANDLE VFWAPI ICImageDecompress(HIC hic, UINT uiFlags, LPBITMAPINFO lpbiIn,
00495                 LPVOID lpBits, LPBITMAPINFO lpbiOut);
00496 
00497 BOOL    VFWAPI  ICInfo(DWORD fccType, DWORD fccHandler, ICINFO * lpicinfo);
00498 BOOL    VFWAPI  ICInstall(DWORD fccType, DWORD fccHandler, LPARAM lParam, LPSTR szDesc, UINT wFlags);
00499 BOOL    VFWAPI  ICRemove(DWORD fccType, DWORD fccHandler, UINT wFlags);
00500 LRESULT VFWAPI  ICGetInfo(HIC hic,ICINFO *picinfo, DWORD cb);
00501 HIC VFWAPI  ICOpen(DWORD fccType, DWORD fccHandler, UINT wMode);
00502 HIC VFWAPI  ICOpenFunction(DWORD fccType, DWORD fccHandler, UINT wMode, DRIVERPROC lpfnHandler);
00503 
00504 LRESULT VFWAPI  ICClose(HIC hic);
00505 HIC VFWAPI  ICLocate(DWORD fccType, DWORD fccHandler, LPBITMAPINFOHEADER lpbiIn, LPBITMAPINFOHEADER lpbiOut, WORD wFlags);
00506 HIC VFWAPI  ICGetDisplayFormat(HIC hic, LPBITMAPINFOHEADER lpbiIn, LPBITMAPINFOHEADER lpbiOut, int BitDepth, int dx, int dy);
00507 
00508 /* Values for wFlags of ICInstall() */
00509 #define ICINSTALL_UNICODE       0x8000
00510 #define ICINSTALL_FUNCTION      0x0001
00511 #define ICINSTALL_DRIVER        0x0002
00512 #define ICINSTALL_HDRV          0x0004
00513 #define ICINSTALL_DRIVERW       0x8002
00514 
00515 #define ICGetState(hic, pv, cb) \
00516     ICSendMessage(hic, ICM_GETSTATE, (DWORD_PTR)(LPVOID)(pv), (DWORD_PTR)(cb))
00517 #define ICSetState(hic, pv, cb) \
00518     ICSendMessage(hic, ICM_SETSTATE, (DWORD_PTR)(LPVOID)(pv), (DWORD_PTR)(cb))
00519 #define ICGetStateSize(hic) \
00520     ICGetState(hic, NULL, 0)
00521 
00522 static inline DWORD ICGetDefaultQuality(HIC hic)
00523 {
00524    DWORD dwICValue;
00525    ICSendMessage(hic, ICM_GETDEFAULTQUALITY, (DWORD_PTR)(LPVOID)&dwICValue, sizeof(DWORD));
00526    return dwICValue;
00527 }
00528 
00529 static inline DWORD ICGetDefaultKeyFrameRate(HIC hic)
00530 {
00531    DWORD dwICValue;
00532    ICSendMessage(hic, ICM_GETDEFAULTKEYFRAMERATE, (DWORD_PTR)(LPVOID)&dwICValue, sizeof(DWORD));
00533    return dwICValue;
00534 }
00535 
00536 #define ICDrawWindow(hic, prc) \
00537     ICSendMessage(hic, ICM_DRAW_WINDOW, (DWORD_PTR)(LPVOID)(prc), sizeof(RECT))
00538 
00539 /* As passed to ICM_DRAW_SUGGESTFORMAT */
00540 typedef struct {
00541     DWORD dwFlags;
00542     LPBITMAPINFOHEADER lpbiIn;
00543     LPBITMAPINFOHEADER lpbiSuggest;
00544     INT dxSrc;
00545     INT dySrc;
00546     INT dxDst;
00547     INT dyDst;
00548     HIC hicDecompressor;
00549 } ICDRAWSUGGEST;
00550 
00551 typedef struct {
00552     DWORD               dwFlags;
00553     int                 iStart;
00554     int                 iLen;
00555     LPPALETTEENTRY      lppe;
00556 } ICPALETTE;
00557 
00558 DWORD   VFWAPIV ICDrawBegin(
00559         HIC         hic,
00560         DWORD           dwFlags,/* flags */
00561         HPALETTE        hpal,   /* palette to draw with */
00562         HWND            hwnd,   /* window to draw to */
00563         HDC         hdc,    /* HDC to draw to */
00564         INT         xDst,   /* destination rectangle */
00565         INT         yDst,
00566         INT         dxDst,
00567         INT         dyDst,
00568         LPBITMAPINFOHEADER  lpbi,   /* format of frame to draw */
00569         INT         xSrc,   /* source rectangle */
00570         INT         ySrc,
00571         INT         dxSrc,
00572         INT         dySrc,
00573         DWORD           dwRate, /* frames/second = (dwRate/dwScale) */
00574         DWORD           dwScale
00575 );
00576 
00577 /* as passed to ICM_DRAW_BEGIN */
00578 typedef struct {
00579     DWORD       dwFlags;
00580     HPALETTE    hpal;
00581     HWND        hwnd;
00582     HDC     hdc;
00583     INT     xDst;
00584     INT     yDst;
00585     INT     dxDst;
00586     INT     dyDst;
00587     LPBITMAPINFOHEADER  lpbi;
00588     INT     xSrc;
00589     INT     ySrc;
00590     INT     dxSrc;
00591     INT     dySrc;
00592     DWORD       dwRate;
00593     DWORD       dwScale;
00594 } ICDRAWBEGIN;
00595 
00596 #define ICDRAW_HURRYUP      0x80000000L   /* don't draw just buffer (hurry up!) */
00597 #define ICDRAW_UPDATE       0x40000000L   /* don't draw just update screen */
00598 #define ICDRAW_PREROLL      0x20000000L   /* this frame is before real start */
00599 #define ICDRAW_NULLFRAME    0x10000000L   /* repeat last frame */
00600 #define ICDRAW_NOTKEYFRAME  0x08000000L   /* this frame is not a key frame */
00601 
00602 typedef struct {
00603     DWORD   dwFlags;
00604     LPVOID  lpFormat;
00605     LPVOID  lpData;
00606     DWORD   cbData;
00607     LONG    lTime;
00608 } ICDRAW;
00609 
00610 DWORD VFWAPIV ICDraw(HIC hic,DWORD dwFlags,LPVOID lpFormat,LPVOID lpData,DWORD cbData,LONG lTime);
00611 
00612 static inline LRESULT VFWAPI ICDrawSuggestFormat(HIC hic, LPBITMAPINFOHEADER lpbiIn,
00613                          LPBITMAPINFOHEADER lpbiOut,
00614                          int dxSrc, int dySrc,
00615                          int dxDst, int dyDst,
00616                          HIC hicDecomp)
00617 {
00618     ICDRAWSUGGEST ic;
00619 
00620     ic.lpbiIn = lpbiIn;
00621     ic.lpbiSuggest = lpbiOut;
00622     ic.dxSrc = dxSrc;
00623     ic.dySrc = dySrc;
00624     ic.dxDst = dxDst;
00625     ic.dyDst = dyDst;
00626     ic.hicDecompressor = hicDecomp;
00627     return ICSendMessage(hic, ICM_DRAW_SUGGESTFORMAT, (DWORD_PTR)&ic, sizeof(ic));
00628 }
00629 
00630 #define ICDrawQuery(hic, lpbiInput) \
00631     ICSendMessage(hic, ICM_DRAW_QUERY, (DWORD_PTR)(LPVOID)(lpbiInput), 0L)
00632 
00633 #define ICDrawChangePalette(hic, lpbiInput) \
00634     ICSendMessage(hic, ICM_DRAW_CHANGEPALETTE, (DWORD_PTR)(LPVOID)(lpbiInput), 0L)
00635 
00636 #define ICGetBuffersWanted(hic, lpdwBuffers) \
00637     ICSendMessage(hic, ICM_GETBUFFERSWANTED, (DWORD_PTR)(LPVOID)(lpdwBuffers), 0)
00638 
00639 #define ICDrawEnd(hic) \
00640     ICSendMessage(hic, ICM_DRAW_END, 0, 0)
00641 
00642 #define ICDrawStart(hic) \
00643     ICSendMessage(hic, ICM_DRAW_START, 0, 0)
00644 
00645 #define ICDrawStartPlay(hic, lFrom, lTo) \
00646     ICSendMessage(hic, ICM_DRAW_START_PLAY, (DWORD_PTR)(lFrom), (DWORD_PTR)(lTo))
00647 
00648 #define ICDrawStop(hic) \
00649     ICSendMessage(hic, ICM_DRAW_STOP, 0, 0)
00650 
00651 #define ICDrawStopPlay(hic) \
00652     ICSendMessage(hic, ICM_DRAW_STOP_PLAY, 0, 0)
00653 
00654 #define ICDrawGetTime(hic, lplTime) \
00655     ICSendMessage(hic, ICM_DRAW_GETTIME, (DWORD_PTR)(LPVOID)(lplTime), 0)
00656 
00657 #define ICDrawSetTime(hic, lTime) \
00658     ICSendMessage(hic, ICM_DRAW_SETTIME, (DWORD_PTR)lTime, 0)
00659 
00660 #define ICDrawRealize(hic, hdc, fBackground) \
00661     ICSendMessage(hic, ICM_DRAW_REALIZE, (DWORD_PTR)(UINT_PTR)(HDC)(hdc), (DWORD_PTR)(BOOL)(fBackground))
00662 
00663 #define ICDrawFlush(hic) \
00664     ICSendMessage(hic, ICM_DRAW_FLUSH, 0, 0)
00665 
00666 #define ICDrawRenderBuffer(hic) \
00667     ICSendMessage(hic, ICM_DRAW_RENDERBUFFER, 0, 0)
00668 
00669 static inline LRESULT VFWAPI ICSetStatusProc(HIC hic, DWORD dwFlags, LRESULT lParam,
00670                          LONG (CALLBACK *fpfnStatus)(LPARAM, UINT, LONG))
00671 {
00672     ICSETSTATUSPROC ic;
00673 
00674     ic.dwFlags = dwFlags;
00675     ic.lParam = lParam;
00676     /* FIXME: see comment in ICSETSTATUSPROC definition */
00677     ic.zStatus = fpfnStatus;
00678 
00679     return ICSendMessage(hic, ICM_SET_STATUS_PROC, (DWORD_PTR)&ic, sizeof(ic));
00680 }
00681 
00682 typedef struct {
00683     LONG        cbSize;
00684     DWORD       dwFlags;
00685     HIC         hic;
00686     DWORD               fccType;
00687     DWORD               fccHandler;
00688     LPBITMAPINFO    lpbiIn;
00689     LPBITMAPINFO    lpbiOut;
00690     LPVOID      lpBitsOut;
00691     LPVOID      lpBitsPrev;
00692     LONG        lFrame;
00693     LONG        lKey;
00694     LONG        lDataRate;
00695     LONG        lQ;
00696     LONG        lKeyCount;
00697     LPVOID      lpState;
00698     LONG        cbState;
00699 } COMPVARS, *PCOMPVARS;
00700 
00701 #define ICMF_COMPVARS_VALID 0x00000001
00702 
00703 BOOL VFWAPI ICCompressorChoose(HWND hwnd, UINT uiFlags, LPVOID pvIn, LPVOID lpData,
00704                    PCOMPVARS pc, LPSTR lpszTitle);
00705 
00706 #define ICMF_CHOOSE_KEYFRAME        0x0001
00707 #define ICMF_CHOOSE_DATARATE        0x0002
00708 #define ICMF_CHOOSE_PREVIEW     0x0004
00709 #define ICMF_CHOOSE_ALLCOMPRESSORS  0x0008
00710 
00711 BOOL VFWAPI ICSeqCompressFrameStart(PCOMPVARS pc, LPBITMAPINFO lpbiIn);
00712 void VFWAPI ICSeqCompressFrameEnd(PCOMPVARS pc);
00713 
00714 LPVOID VFWAPI ICSeqCompressFrame(PCOMPVARS pc, UINT uiFlags, LPVOID lpBits,
00715                  BOOL *pfKey, LONG *plSize);
00716 void VFWAPI ICCompressorFree(PCOMPVARS pc);
00717 
00718 /********************* AVIFILE function declarations *************************/
00719 
00720 #ifndef mmioFOURCC
00721 #define mmioFOURCC( ch0, ch1, ch2, ch3 )                \
00722     ( (DWORD)(BYTE)(ch0) | ( (DWORD)(BYTE)(ch1) << 8 ) |        \
00723     ( (DWORD)(BYTE)(ch2) << 16 ) | ( (DWORD)(BYTE)(ch3) << 24 ) )
00724 #endif
00725 
00726 #ifndef aviTWOCC
00727 #define aviTWOCC(ch0, ch1) ((WORD)(BYTE)(ch0) | ((WORD)(BYTE)(ch1) << 8))
00728 #endif
00729 
00730 typedef WORD TWOCC;
00731 
00732 #define ICTYPE_VIDEO        mmioFOURCC('v', 'i', 'd', 'c')
00733 #define ICTYPE_AUDIO        mmioFOURCC('a', 'u', 'd', 'c')
00734 
00735 #define formtypeAVI             mmioFOURCC('A', 'V', 'I', ' ')
00736 #define listtypeAVIHEADER       mmioFOURCC('h', 'd', 'r', 'l')
00737 #define ckidAVIMAINHDR          mmioFOURCC('a', 'v', 'i', 'h')
00738 #define listtypeSTREAMHEADER    mmioFOURCC('s', 't', 'r', 'l')
00739 #define ckidSTREAMHEADER        mmioFOURCC('s', 't', 'r', 'h')
00740 #define ckidSTREAMFORMAT        mmioFOURCC('s', 't', 'r', 'f')
00741 #define ckidSTREAMHANDLERDATA   mmioFOURCC('s', 't', 'r', 'd')
00742 #define ckidSTREAMNAME      mmioFOURCC('s', 't', 'r', 'n')
00743 
00744 #define listtypeAVIMOVIE        mmioFOURCC('m', 'o', 'v', 'i')
00745 #define listtypeAVIRECORD       mmioFOURCC('r', 'e', 'c', ' ')
00746 
00747 #define ckidAVINEWINDEX         mmioFOURCC('i', 'd', 'x', '1')
00748 
00749 #define streamtypeANY           0UL
00750 #define streamtypeVIDEO         mmioFOURCC('v', 'i', 'd', 's')
00751 #define streamtypeAUDIO         mmioFOURCC('a', 'u', 'd', 's')
00752 #define streamtypeMIDI          mmioFOURCC('m', 'i', 'd', 's')
00753 #define streamtypeTEXT          mmioFOURCC('t', 'x', 't', 's')
00754 
00755 /* Basic chunk types */
00756 #define cktypeDIBbits           aviTWOCC('d', 'b')
00757 #define cktypeDIBcompressed     aviTWOCC('d', 'c')
00758 #define cktypePALchange         aviTWOCC('p', 'c')
00759 #define cktypeWAVEbytes         aviTWOCC('w', 'b')
00760 
00761 /* Chunk id to use for extra chunks for padding. */
00762 #define ckidAVIPADDING          mmioFOURCC('J', 'U', 'N', 'K')
00763 
00764 #define FromHex(n)      (((n) >= 'A') ? ((n) + 10 - 'A') : ((n) - '0'))
00765 #define StreamFromFOURCC(fcc)   ((WORD)((FromHex(LOBYTE(LOWORD(fcc))) << 4) + \
00766                     (FromHex(HIBYTE(LOWORD(fcc))))))
00767 #define TWOCCFromFOURCC(fcc)    HIWORD(fcc)
00768 #define ToHex(n)        ((BYTE)(((n) > 9) ? ((n) - 10 + 'A') : ((n) + '0')))
00769 #define MAKEAVICKID(tcc, stream) \
00770                                 MAKELONG((ToHex((stream) & 0x0f) << 8) | \
00771                              (ToHex(((stream) & 0xf0) >> 4)), tcc)
00772 
00773 /* AVIFileHdr.dwFlags */
00774 #define AVIF_HASINDEX       0x00000010  /* Index at end of file? */
00775 #define AVIF_MUSTUSEINDEX   0x00000020
00776 #define AVIF_ISINTERLEAVED  0x00000100
00777 #define AVIF_TRUSTCKTYPE    0x00000800  /* Use CKType to find key frames*/
00778 #define AVIF_WASCAPTUREFILE 0x00010000
00779 #define AVIF_COPYRIGHTED    0x00020000
00780 
00781 #define AVI_HEADERSIZE  2048
00782 
00783 typedef BOOL (CALLBACK *AVISAVECALLBACK)(INT);
00784 
00785 typedef struct _MainAVIHeader
00786 {
00787     DWORD   dwMicroSecPerFrame;
00788     DWORD   dwMaxBytesPerSec;
00789     DWORD   dwPaddingGranularity;
00790     DWORD   dwFlags;
00791     DWORD   dwTotalFrames;
00792     DWORD   dwInitialFrames;
00793     DWORD   dwStreams;
00794     DWORD   dwSuggestedBufferSize;
00795     DWORD   dwWidth;
00796     DWORD   dwHeight;
00797     DWORD   dwReserved[4];
00798 } MainAVIHeader;
00799 
00800 /* AVIStreamHeader.dwFlags */
00801 #define AVISF_DISABLED                  0x00000001
00802 #define AVISF_VIDEO_PALCHANGES          0x00010000
00803 
00804 typedef struct {
00805     FOURCC  fccType;
00806     FOURCC  fccHandler;
00807     DWORD   dwFlags;        /* AVISF_* */
00808     WORD    wPriority;
00809     WORD    wLanguage;
00810     DWORD   dwInitialFrames;
00811     DWORD   dwScale;
00812     DWORD   dwRate; /* dwRate / dwScale == samples/second */
00813     DWORD   dwStart;
00814     DWORD   dwLength; /* In units above... */
00815     DWORD   dwSuggestedBufferSize;
00816     DWORD   dwQuality;
00817     DWORD   dwSampleSize;
00818     struct { SHORT left, top, right, bottom; } rcFrame; /* word.word - word.word in file */
00819 } AVIStreamHeader;
00820 
00821 /* AVIINDEXENTRY.dwFlags */
00822 #define AVIIF_LIST  0x00000001  /* chunk is a 'LIST' */
00823 #define AVIIF_TWOCC 0x00000002
00824 #define AVIIF_KEYFRAME  0x00000010  /* this frame is a key frame. */
00825 #define AVIIF_FIRSTPART 0x00000020
00826 #define AVIIF_LASTPART  0x00000040
00827 #define AVIIF_MIDPART   (AVIIF_LASTPART|AVIIF_FIRSTPART)
00828 #define AVIIF_NOTIME    0x00000100  /* this frame doesn't take any time */
00829 #define AVIIF_COMPUSE   0x0FFF0000
00830 
00831 typedef struct _AVIINDEXENTRY {
00832     DWORD   ckid;
00833     DWORD   dwFlags;
00834     DWORD   dwChunkOffset;
00835     DWORD   dwChunkLength;
00836 } AVIINDEXENTRY;
00837 
00838 typedef struct _AVIPALCHANGE {
00839     BYTE        bFirstEntry;
00840     BYTE        bNumEntries;
00841     WORD        wFlags;     /* pad */
00842     PALETTEENTRY    peNew[1];
00843 } AVIPALCHANGE;
00844 
00845 #define AVIIF_KEYFRAME  0x00000010  /* this frame is a key frame. */
00846 
00847 #define AVIGETFRAMEF_BESTDISPLAYFMT 1
00848 
00849 typedef struct _AVISTREAMINFOA {
00850     DWORD   fccType;
00851     DWORD   fccHandler;
00852     DWORD   dwFlags;        /* AVIIF_* */
00853     DWORD   dwCaps;
00854     WORD    wPriority;
00855     WORD    wLanguage;
00856     DWORD   dwScale;
00857     DWORD   dwRate;     /* dwRate / dwScale == samples/second */
00858     DWORD   dwStart;
00859     DWORD   dwLength;   /* In units above... */
00860     DWORD   dwInitialFrames;
00861     DWORD   dwSuggestedBufferSize;
00862     DWORD   dwQuality;
00863     DWORD   dwSampleSize;
00864     RECT    rcFrame;
00865     DWORD   dwEditCount;
00866     DWORD   dwFormatChangeCount;
00867     CHAR    szName[64];
00868 } AVISTREAMINFOA, * LPAVISTREAMINFOA, *PAVISTREAMINFOA;
00869 
00870 typedef struct _AVISTREAMINFOW {
00871     DWORD   fccType;
00872     DWORD   fccHandler;
00873     DWORD   dwFlags;
00874     DWORD   dwCaps;
00875     WORD    wPriority;
00876     WORD    wLanguage;
00877     DWORD   dwScale;
00878     DWORD   dwRate;     /* dwRate / dwScale == samples/second */
00879     DWORD   dwStart;
00880     DWORD   dwLength;   /* In units above... */
00881     DWORD   dwInitialFrames;
00882     DWORD   dwSuggestedBufferSize;
00883     DWORD   dwQuality;
00884     DWORD   dwSampleSize;
00885     RECT    rcFrame;
00886     DWORD   dwEditCount;
00887     DWORD   dwFormatChangeCount;
00888     WCHAR   szName[64];
00889 } AVISTREAMINFOW, * LPAVISTREAMINFOW, *PAVISTREAMINFOW;
00890 DECL_WINELIB_TYPE_AW(AVISTREAMINFO)
00891 DECL_WINELIB_TYPE_AW(LPAVISTREAMINFO)
00892 DECL_WINELIB_TYPE_AW(PAVISTREAMINFO)
00893 
00894 #define AVISTREAMINFO_DISABLED      0x00000001
00895 #define AVISTREAMINFO_FORMATCHANGES 0x00010000
00896 
00897 /* AVIFILEINFO.dwFlags */
00898 #define AVIFILEINFO_HASINDEX        0x00000010
00899 #define AVIFILEINFO_MUSTUSEINDEX    0x00000020
00900 #define AVIFILEINFO_ISINTERLEAVED   0x00000100
00901 #define AVIFILEINFO_TRUSTCKTYPE         0x00000800
00902 #define AVIFILEINFO_WASCAPTUREFILE  0x00010000
00903 #define AVIFILEINFO_COPYRIGHTED     0x00020000
00904 
00905 /* AVIFILEINFO.dwCaps */
00906 #define AVIFILECAPS_CANREAD     0x00000001
00907 #define AVIFILECAPS_CANWRITE        0x00000002
00908 #define AVIFILECAPS_ALLKEYFRAMES    0x00000010
00909 #define AVIFILECAPS_NOCOMPRESSION   0x00000020
00910 
00911 typedef struct _AVIFILEINFOW {
00912     DWORD               dwMaxBytesPerSec;
00913     DWORD               dwFlags;
00914     DWORD               dwCaps;
00915     DWORD               dwStreams;
00916     DWORD               dwSuggestedBufferSize;
00917     DWORD               dwWidth;
00918     DWORD               dwHeight;
00919     DWORD               dwScale;
00920     DWORD               dwRate;
00921     DWORD               dwLength;
00922     DWORD               dwEditCount;
00923     WCHAR               szFileType[64];
00924 } AVIFILEINFOW, * LPAVIFILEINFOW, *PAVIFILEINFOW;
00925 typedef struct _AVIFILEINFOA {
00926     DWORD               dwMaxBytesPerSec;
00927     DWORD               dwFlags;
00928     DWORD               dwCaps;
00929     DWORD               dwStreams;
00930     DWORD               dwSuggestedBufferSize;
00931     DWORD               dwWidth;
00932     DWORD               dwHeight;
00933     DWORD               dwScale;
00934     DWORD               dwRate;
00935     DWORD               dwLength;
00936     DWORD               dwEditCount;
00937     CHAR        szFileType[64];
00938 } AVIFILEINFOA, * LPAVIFILEINFOA, *PAVIFILEINFOA;
00939 DECL_WINELIB_TYPE_AW(AVIFILEINFO)
00940 DECL_WINELIB_TYPE_AW(PAVIFILEINFO)
00941 DECL_WINELIB_TYPE_AW(LPAVIFILEINFO)
00942 
00943 /* AVICOMPRESSOPTIONS.dwFlags. determines presence of fields in below struct */
00944 #define AVICOMPRESSF_INTERLEAVE 0x00000001
00945 #define AVICOMPRESSF_DATARATE   0x00000002
00946 #define AVICOMPRESSF_KEYFRAMES  0x00000004
00947 #define AVICOMPRESSF_VALID  0x00000008
00948 
00949 typedef struct {
00950     DWORD   fccType;        /* stream type, for consistency */
00951     DWORD   fccHandler;     /* compressor */
00952     DWORD   dwKeyFrameEvery;    /* keyframe rate */
00953     DWORD   dwQuality;      /* compress quality 0-10,000 */
00954     DWORD   dwBytesPerSecond;   /* bytes per second */
00955     DWORD   dwFlags;        /* flags... see below */
00956     LPVOID  lpFormat;       /* save format */
00957     DWORD   cbFormat;
00958     LPVOID  lpParms;        /* compressor options */
00959     DWORD   cbParms;
00960     DWORD   dwInterleaveEvery;  /* for non-video streams only */
00961 } AVICOMPRESSOPTIONS, *LPAVICOMPRESSOPTIONS,*PAVICOMPRESSOPTIONS;
00962 
00963 #define FIND_DIR        0x0000000FL     /* direction mask */
00964 #define FIND_NEXT       0x00000001L     /* search forward */
00965 #define FIND_PREV       0x00000004L     /* search backward */
00966 #define FIND_FROM_START 0x00000008L     /* start at the logical beginning */
00967 
00968 #define FIND_TYPE       0x000000F0L     /* type mask */
00969 #define FIND_KEY        0x00000010L     /* find a key frame */
00970 #define FIND_ANY        0x00000020L     /* find any (non-empty) sample */
00971 #define FIND_FORMAT     0x00000040L     /* find a formatchange */
00972 
00973 #define FIND_RET        0x0000F000L     /* return mask */
00974 #define FIND_POS        0x00000000L     /* return logical position */
00975 #define FIND_LENGTH     0x00001000L     /* return logical size */
00976 #define FIND_OFFSET     0x00002000L     /* return physical position */
00977 #define FIND_SIZE       0x00003000L     /* return physical size */
00978 #define FIND_INDEX      0x00004000L     /* return physical index position */
00979 
00980 #include <ole2.h>
00981 
00982 #define DEFINE_AVIGUID(name, l, w1, w2) \
00983     DEFINE_GUID(name, l, w1, w2, 0xC0,0,0,0,0,0,0,0x46)
00984 
00985 DEFINE_AVIGUID(IID_IAVIFile,            0x00020020, 0, 0);
00986 DEFINE_AVIGUID(IID_IAVIStream,          0x00020021, 0, 0);
00987 DEFINE_AVIGUID(IID_IAVIStreaming,       0x00020022, 0, 0);
00988 DEFINE_AVIGUID(IID_IGetFrame,           0x00020023, 0, 0);
00989 DEFINE_AVIGUID(IID_IAVIEditStream,      0x00020024, 0, 0);
00990 
00991 DEFINE_AVIGUID(CLSID_AVISimpleUnMarshal,0x00020009, 0, 0);
00992 DEFINE_AVIGUID(CLSID_AVIFile,           0x00020000, 0, 0);
00993 
00994 /*****************************************************************************
00995  * IAVIStream interface
00996  */
00997 #define INTERFACE IAVIStream
00998 DECLARE_INTERFACE_(IAVIStream,IUnknown)
00999 {
01000     /*** IUnknown methods ***/
01001     STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
01002     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
01003     STDMETHOD_(ULONG,Release)(THIS) PURE;
01004     /*** IAVIStream methods ***/
01005     STDMETHOD(Create)(THIS_ LPARAM lParam1, LPARAM lParam2) PURE;
01006     STDMETHOD(Info)(THIS_ AVISTREAMINFOW *psi, LONG lSize) PURE;
01007     STDMETHOD_(LONG,FindSample)(THIS_ LONG lPos, LONG lFlags) PURE;
01008     STDMETHOD(ReadFormat)(THIS_ LONG lPos, LPVOID lpFormat, LONG *lpcbFormat) PURE;
01009     STDMETHOD(SetFormat)(THIS_ LONG lPos, LPVOID lpFormat, LONG cbFormat) PURE;
01010     STDMETHOD(Read)(THIS_ LONG lStart, LONG lSamples, LPVOID lpBuffer, LONG cbBuffer, LONG *plBytes, LONG *plSamples) PURE;
01011     STDMETHOD(Write)(THIS_ LONG lStart, LONG lSamples, LPVOID lpBuffer, LONG cbBuffer, DWORD dwFlags, LONG *plSampWritten, LONG *plBytesWritten) PURE;
01012     STDMETHOD(Delete)(THIS_ LONG lStart, LONG lSamples) PURE;
01013     STDMETHOD(ReadData)(THIS_ DWORD fcc, LPVOID lpBuffer, LONG *lpcbBuffer) PURE;
01014     STDMETHOD(WriteData)(THIS_ DWORD fcc, LPVOID lpBuffer, LONG cbBuffer) PURE;
01015     STDMETHOD(SetInfo)(THIS_ AVISTREAMINFOW *plInfo, LONG cbInfo) PURE;
01016 };
01017 #undef INTERFACE
01018 
01019 #if !defined(__cplusplus) || defined(CINTERFACE)
01020 /*** IUnknown methods ***/
01021 #define IAVIStream_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
01022 #define IAVIStream_AddRef(p)             (p)->lpVtbl->AddRef(p)
01023 #define IAVIStream_Release(p)            (p)->lpVtbl->Release(p)
01024 /*** IAVIStream methods ***/
01025 #define IAVIStream_Create(p,a,b)          (p)->lpVtbl->Create(p,a,b)
01026 #define IAVIStream_Info(p,a,b)            (p)->lpVtbl->Info(p,a,b)
01027 #define IAVIStream_FindSample(p,a,b)      (p)->lpVtbl->FindSample(p,a,b)
01028 #define IAVIStream_ReadFormat(p,a,b,c)    (p)->lpVtbl->ReadFormat(p,a,b,c)
01029 #define IAVIStream_SetFormat(p,a,b,c)     (p)->lpVtbl->SetFormat(p,a,b,c)
01030 #define IAVIStream_Read(p,a,b,c,d,e,f)    (p)->lpVtbl->Read(p,a,b,c,d,e,f)
01031 #define IAVIStream_Write(p,a,b,c,d,e,f,g) (p)->lpVtbl->Write(p,a,b,c,d,e,f,g)
01032 #define IAVIStream_Delete(p,a,b)          (p)->lpVtbl->Delete(p,a,b)
01033 #define IAVIStream_ReadData(p,a,b,c)      (p)->lpVtbl->ReadData(p,a,b,c)
01034 #define IAVIStream_WriteData(p,a,b,c)     (p)->lpVtbl->WriteData(p,a,b,c)
01035 #define IAVIStream_SetInfo(p,a,b)         (p)->lpVtbl->SetInfo(p,a,b)
01036 #endif
01037 
01038 #define AVISTREAMREAD_CONVENIENT      (-1L)
01039 
01040 ULONG WINAPI AVIStreamAddRef(PAVISTREAM iface);
01041 ULONG WINAPI AVIStreamRelease(PAVISTREAM iface);
01042 HRESULT WINAPI AVIStreamCreate(PAVISTREAM*,LONG,LONG,CLSID*);
01043 HRESULT WINAPI AVIStreamInfoA(PAVISTREAM iface,AVISTREAMINFOA *asi,LONG size);
01044 HRESULT WINAPI AVIStreamInfoW(PAVISTREAM iface,AVISTREAMINFOW *asi,LONG size);
01045 #define AVIStreamInfo WINELIB_NAME_AW(AVIStreamInfo)
01046 LONG WINAPI AVIStreamFindSample(PAVISTREAM pstream, LONG pos, LONG flags);
01047 HRESULT WINAPI AVIStreamReadFormat(PAVISTREAM iface,LONG pos,LPVOID format,LONG *formatsize);
01048 HRESULT WINAPI AVIStreamSetFormat(PAVISTREAM iface,LONG pos,LPVOID format,LONG formatsize);
01049 HRESULT WINAPI AVIStreamRead(PAVISTREAM iface,LONG start,LONG samples,LPVOID buffer,LONG buffersize,LONG *bytesread,LONG *samplesread);
01050 HRESULT WINAPI AVIStreamWrite(PAVISTREAM iface,LONG start,LONG samples,LPVOID buffer,LONG buffersize,DWORD flags,LONG *sampwritten,LONG *byteswritten);
01051 HRESULT WINAPI AVIStreamReadData(PAVISTREAM iface,DWORD fcc,LPVOID lp,LONG *lpread);
01052 HRESULT WINAPI AVIStreamWriteData(PAVISTREAM iface,DWORD fcc,LPVOID lp,LONG size);
01053 
01054 PGETFRAME WINAPI AVIStreamGetFrameOpen(PAVISTREAM pavi,LPBITMAPINFOHEADER lpbiWanted);
01055 LPVOID  WINAPI AVIStreamGetFrame(PGETFRAME pg,LONG pos);
01056 HRESULT WINAPI AVIStreamGetFrameClose(PGETFRAME pg);
01057 
01058 HRESULT WINAPI AVIMakeCompressedStream(PAVISTREAM*ppsCompressed,PAVISTREAM ppsSource,AVICOMPRESSOPTIONS *lpOptions,CLSID*pclsidHandler);
01059 HRESULT WINAPI AVIMakeFileFromStreams(PAVIFILE *ppfile, int nStreams, PAVISTREAM *ppStreams);
01060 HRESULT WINAPI AVIMakeStreamFromClipboard(UINT cfFormat, HANDLE hGlobal, PAVISTREAM * ppstream);
01061 
01062 HRESULT WINAPI AVIStreamOpenFromFileA(PAVISTREAM *ppavi, LPCSTR szFile,
01063                       DWORD fccType, LONG lParam,
01064                       UINT mode, CLSID *pclsidHandler);
01065 HRESULT WINAPI AVIStreamOpenFromFileW(PAVISTREAM *ppavi, LPCWSTR szFile,
01066                       DWORD fccType, LONG lParam,
01067                       UINT mode, CLSID *pclsidHandler);
01068 #define AVIStreamOpenFromFile WINELIB_NAME_AW(AVIStreamOpenFromFile)
01069 
01070 LONG WINAPI AVIStreamBeginStreaming(PAVISTREAM pavi, LONG lStart, LONG lEnd, LONG lRate);
01071 LONG WINAPI AVIStreamEndStreaming(PAVISTREAM pavi);
01072 
01073 HRESULT WINAPI AVIBuildFilterA(LPSTR szFilter, LONG cbFilter, BOOL fSaving);
01074 HRESULT WINAPI AVIBuildFilterW(LPWSTR szFilter, LONG cbFilter, BOOL fSaving);
01075 #define AVIBuildFilter WINELIB_NAME_AW(AVIBuildFilter)
01076 
01077 BOOL WINAPI AVISaveOptions(HWND hWnd,UINT uFlags,INT nStream,
01078                PAVISTREAM *ppavi,LPAVICOMPRESSOPTIONS *ppOptions);
01079 HRESULT WINAPI AVISaveOptionsFree(INT nStreams,LPAVICOMPRESSOPTIONS*ppOptions);
01080 
01081 HRESULT CDECL AVISaveA(LPCSTR szFile, CLSID *pclsidHandler,
01082              AVISAVECALLBACK lpfnCallback, int nStreams,
01083              PAVISTREAM pavi, LPAVICOMPRESSOPTIONS lpOptions, ...);
01084 HRESULT CDECL AVISaveW(LPCWSTR szFile, CLSID *pclsidHandler,
01085              AVISAVECALLBACK lpfnCallback, int nStreams,
01086              PAVISTREAM pavi, LPAVICOMPRESSOPTIONS lpOptions, ...);
01087 #define AVISave WINELIB_NAME_AW(AVISave)
01088 
01089 HRESULT WINAPI AVISaveVA(LPCSTR szFile, CLSID *pclsidHandler,
01090              AVISAVECALLBACK lpfnCallback, int nStream,
01091              PAVISTREAM *ppavi, LPAVICOMPRESSOPTIONS *plpOptions);
01092 HRESULT WINAPI AVISaveVW(LPCWSTR szFile, CLSID *pclsidHandler,
01093              AVISAVECALLBACK lpfnCallback, int nStream,
01094              PAVISTREAM *ppavi, LPAVICOMPRESSOPTIONS *plpOptions);
01095 #define AVISaveV WINELIB_NAME_AW(AVISaveV)
01096 
01097 LONG WINAPI AVIStreamStart(PAVISTREAM iface);
01098 LONG WINAPI AVIStreamLength(PAVISTREAM iface);
01099 LONG WINAPI AVIStreamSampleToTime(PAVISTREAM pstream, LONG lSample);
01100 LONG WINAPI AVIStreamTimeToSample(PAVISTREAM pstream, LONG lTime);
01101 
01102 #define AVIFileClose(pavi) \
01103     AVIFileRelease(pavi)
01104 #define AVIStreamClose(pavi) \
01105     AVIStreamRelease(pavi);
01106 #define AVIStreamEnd(pavi) \
01107     (AVIStreamStart(pavi) + AVIStreamLength(pavi))
01108 #define AVIStreamEndTime(pavi) \
01109     AVIStreamSampleToTime(pavi, AVIStreamEnd(pavi))
01110 #define AVIStreamFormatSize(pavi, lPos, plSize) \
01111     AVIStreamReadFormat(pavi, lPos, NULL, plSize)
01112 #define AVIStreamLengthTime(pavi) \
01113     AVIStreamSampleToTime(pavi, AVIStreamLength(pavi))
01114 #define AVIStreamSampleSize(pavi,pos,psize) \
01115     AVIStreamRead(pavi,pos,1,NULL,0,psize,NULL)
01116 #define AVIStreamSampleToSample(pavi1, pavi2, samp2) \
01117     AVIStreamTimeToSample(pavi1, AVIStreamSampleToTime(pavi2, samp2))
01118 #define AVIStreamStartTime(pavi) \
01119     AVIStreamSampleToTime(pavi, AVIStreamStart(pavi))
01120 
01121 #define AVIStreamNextSample(pavi, pos) \
01122     AVIStreamFindSample(pavi, pos + 1, FIND_NEXT | FIND_ANY)
01123 #define AVIStreamPrevSample(pavi, pos) \
01124     AVIStreamFindSample(pavi, pos - 1, FIND_PREV | FIND_ANY)
01125 #define AVIStreamNearestSample(pavi, pos) \
01126     AVIStreamFindSample(pavi, pos, FIND_PREV | FIND_ANY)
01127 #define AVStreamNextKeyFrame(pavi,pos) \
01128     AVIStreamFindSample(pavi, pos + 1, FIND_NEXT | FIND_KEY)
01129 #define AVStreamPrevKeyFrame(pavi,pos) \
01130     AVIStreamFindSample(pavi, pos - 1, FIND_NEXT | FIND_KEY)
01131 #define AVIStreamNearestKeyFrame(pavi,pos) \
01132     AVIStreamFindSample(pavi, pos, FIND_PREV | FIND_KEY)
01133 #define AVIStreamIsKeyFrame(pavi, pos) \
01134     (AVIStreamNearestKeyFrame(pavi, pos) == pos)
01135 
01136 /*****************************************************************************
01137  * IAVIStreaming interface
01138  */
01139 #define INTERFACE IAVIStreaming
01140 DECLARE_INTERFACE_(IAVIStreaming,IUnknown)
01141 {
01142     /*** IUnknown methods ***/
01143     STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
01144     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
01145     STDMETHOD_(ULONG,Release)(THIS) PURE;
01146     /*** IAVIStreaming methods ***/
01147     STDMETHOD(Begin)(IAVIStreaming*iface,LONG lStart,LONG lEnd,LONG lRate) PURE;
01148     STDMETHOD(End)(IAVIStreaming*iface) PURE;
01149 };
01150 #undef INTERFACE
01151 
01152 #if !defined(__cplusplus) || defined(CINTERFACE)
01153 /*** IUnknown methods ***/
01154 #define IAVIStreaming_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
01155 #define IAVIStreaming_AddRef(p)             (p)->lpVtbl->AddRef(p)
01156 #define IAVIStreaming_Release(p)            (p)->lpVtbl->Release(p)
01157 /*** IAVIStreaming methods ***/
01158 #define IAVIStreaming_Begin(p,a,b,c)        (p)->lpVtbl->Begin(p,a,b,c)
01159 #define IAVIStreaming_End(p)                (p)->lpVtbl->End(p)
01160 #endif
01161 
01162 /*****************************************************************************
01163  * IAVIEditStream interface
01164  */
01165 #define INTERFACE IAVIEditStream
01166 DECLARE_INTERFACE_(IAVIEditStream,IUnknown)
01167 {
01168     /*** IUnknown methods ***/
01169     STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
01170     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
01171     STDMETHOD_(ULONG,Release)(THIS) PURE;
01172     /*** IAVIEditStream methods ***/
01173     STDMETHOD(Cut)(IAVIEditStream*iface,LONG*plStart,LONG*plLength,PAVISTREAM*ppResult) PURE;
01174     STDMETHOD(Copy)(IAVIEditStream*iface,LONG*plStart,LONG*plLength,PAVISTREAM*ppResult) PURE;
01175     STDMETHOD(Paste)(IAVIEditStream*iface,LONG*plStart,LONG*plLength,PAVISTREAM pSource,LONG lStart,LONG lEnd) PURE;
01176     STDMETHOD(Clone)(IAVIEditStream*iface,PAVISTREAM*ppResult) PURE;
01177     STDMETHOD(SetInfo)(IAVIEditStream*iface,LPAVISTREAMINFOW asi, LONG size) PURE;
01178 };
01179 #undef INTERFACE
01180 
01181 #if !defined(__cplusplus) || defined(CINTERFACE)
01182 /*** IUnknown methods ***/
01183 #define IAVIEditStream_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
01184 #define IAVIEditStream_AddRef(p)             (p)->lpVtbl->AddRef(p)
01185 #define IAVIEditStream_Release(p)            (p)->lpVtbl->Release(p)
01186 /*** IAVIEditStream methods ***/
01187 #define IAVIEditStream_Cut(p,a,b,c)      (p)->lpVtbl->Cut(p,a,b,c)
01188 #define IAVIEditStream_Copy(p,a,b,c)         (p)->lpVtbl->Copy(p,a,b,c)
01189 #define IAVIEditStream_Paste(p,a,b,c,d,e)    (p)->lpVtbl->Paste(p,a,b,c,d,e)
01190 #define IAVIEditStream_Clone(p,a)        (p)->lpVtbl->Clone(p,a)
01191 #define IAVIEditStream_SetInfo(p,a,b)        (p)->lpVtbl->SetInfo(p,a,b)
01192 #endif
01193 
01194 HRESULT WINAPI CreateEditableStream(PAVISTREAM *ppEditable,PAVISTREAM pSource);
01195 HRESULT WINAPI EditStreamClone(PAVISTREAM pStream, PAVISTREAM *ppResult);
01196 HRESULT WINAPI EditStreamCopy(PAVISTREAM pStream, LONG *plStart,
01197                   LONG *plLength, PAVISTREAM *ppResult);
01198 HRESULT WINAPI EditStreamCut(PAVISTREAM pStream, LONG *plStart,
01199                  LONG *plLength, PAVISTREAM *ppResult);
01200 HRESULT WINAPI EditStreamPaste(PAVISTREAM pDest, LONG *plStart, LONG *plLength,
01201                    PAVISTREAM pSource, LONG lStart, LONG lEnd);
01202 
01203 HRESULT WINAPI EditStreamSetInfoA(PAVISTREAM pstream, LPAVISTREAMINFOA asi,
01204                   LONG size);
01205 HRESULT WINAPI EditStreamSetInfoW(PAVISTREAM pstream, LPAVISTREAMINFOW asi,
01206                   LONG size);
01207 #define EditStreamSetInfo WINELIB_NAME_AW(EditStreamSetInfo)
01208 
01209 HRESULT WINAPI EditStreamSetNameA(PAVISTREAM pstream, LPCSTR szName);
01210 HRESULT WINAPI EditStreamSetNameW(PAVISTREAM pstream, LPCWSTR szName);
01211 #define EditStreamSetName WINELIB_NAME_AW(EditStreamSetName)
01212 
01213 /*****************************************************************************
01214  * IAVIFile interface
01215  */
01216 /* In Win32 this interface uses UNICODE only */
01217 #define INTERFACE IAVIFile
01218 DECLARE_INTERFACE_(IAVIFile,IUnknown)
01219 {
01220     /*** IUnknown methods ***/
01221     STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
01222     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
01223     STDMETHOD_(ULONG,Release)(THIS) PURE;
01224     /*** IAVIFile methods ***/
01225     STDMETHOD(Info)(THIS_ AVIFILEINFOW *pfi, LONG lSize) PURE;
01226     STDMETHOD(GetStream)(THIS_ PAVISTREAM *ppStream, DWORD fccType, LONG lParam) PURE;
01227     STDMETHOD(CreateStream)(THIS_ PAVISTREAM *ppStream, AVISTREAMINFOW *psi) PURE;
01228     STDMETHOD(WriteData)(THIS_ DWORD fcc, LPVOID lpBuffer, LONG cbBuffer) PURE;
01229     STDMETHOD(ReadData)(THIS_ DWORD fcc, LPVOID lpBuffer, LONG *lpcbBuffer) PURE;
01230     STDMETHOD(EndRecord)(THIS) PURE;
01231     STDMETHOD(DeleteStream)(THIS_ DWORD fccType, LONG lParam) PURE;
01232 };
01233 #undef INTERFACE
01234 
01235 #if !defined(__cplusplus) || defined(CINTERFACE)
01236 /*** IUnknown methods ***/
01237 #define IAVIFile_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
01238 #define IAVIFile_AddRef(p)             (p)->lpVtbl->AddRef(p)
01239 #define IAVIFile_Release(p)            (p)->lpVtbl->Release(p)
01240 /*** IAVIFile methods ***/
01241 #define IAVIFile_Info(p,a,b)         (p)->lpVtbl->Info(p,a,b)
01242 #define IAVIFile_GetStream(p,a,b,c)  (p)->lpVtbl->GetStream(p,a,b,c)
01243 #define IAVIFile_CreateStream(p,a,b) (p)->lpVtbl->CreateStream(p,a,b)
01244 #define IAVIFile_WriteData(p,a,b,c)  (p)->lpVtbl->WriteData(p,a,b,c)
01245 #define IAVIFile_ReadData(p,a,b,c)   (p)->lpVtbl->ReadData(p,a,b,c)
01246 #define IAVIFile_EndRecord(p)        (p)->lpVtbl->EndRecord(p)
01247 #define IAVIFile_DeleteStream(p,a,b) (p)->lpVtbl->DeleteStream(p,a,b)
01248 #endif
01249 
01250 void WINAPI AVIFileInit(void);
01251 void WINAPI AVIFileExit(void);
01252 
01253 HRESULT WINAPI AVIFileOpenA(PAVIFILE* ppfile,LPCSTR szFile,UINT uMode,LPCLSID lpHandler);
01254 HRESULT WINAPI AVIFileOpenW(PAVIFILE* ppfile,LPCWSTR szFile,UINT uMode,LPCLSID lpHandler);
01255 #define AVIFileOpen WINELIB_NAME_AW(AVIFileOpen)
01256 
01257 ULONG   WINAPI AVIFileAddRef(PAVIFILE pfile);
01258 ULONG   WINAPI AVIFileRelease(PAVIFILE pfile);
01259 HRESULT WINAPI AVIFileInfoA(PAVIFILE pfile,PAVIFILEINFOA pfi,LONG lSize);
01260 HRESULT WINAPI AVIFileInfoW(PAVIFILE pfile,PAVIFILEINFOW pfi,LONG lSize);
01261 #define AVIFileInfo WINELIB_NAME_AW(AVIFileInfo)
01262 HRESULT WINAPI AVIFileGetStream(PAVIFILE pfile,PAVISTREAM* avis,DWORD fccType,LONG lParam);
01263 HRESULT WINAPI AVIFileCreateStreamA(PAVIFILE pfile,PAVISTREAM* ppavi,AVISTREAMINFOA* psi);
01264 HRESULT WINAPI AVIFileCreateStreamW(PAVIFILE pfile,PAVISTREAM* ppavi,AVISTREAMINFOW* psi);
01265 #define AVIFileCreateStream WINELIB_NAME_AW(AVIFileCreateStream)
01266 HRESULT WINAPI AVIFileWriteData(PAVIFILE pfile,DWORD fcc,LPVOID lp,LONG size);
01267 HRESULT WINAPI AVIFileReadData(PAVIFILE pfile,DWORD fcc,LPVOID lp,LPLONG size);
01268 HRESULT WINAPI AVIFileEndRecord(PAVIFILE pfile);
01269 
01270 /*****************************************************************************
01271  * IGetFrame interface
01272  */
01273 #define INTERFACE IGetFrame
01274 DECLARE_INTERFACE_(IGetFrame,IUnknown)
01275 {
01276     /*** IUnknown methods ***/
01277     STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
01278     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
01279     STDMETHOD_(ULONG,Release)(THIS) PURE;
01280     /*** IGetFrame methods ***/
01281     STDMETHOD_(LPVOID,GetFrame)(THIS_ LONG lPos) PURE;
01282     STDMETHOD(Begin)(THIS_ LONG lStart, LONG lEnd, LONG lRate) PURE;
01283     STDMETHOD(End)(THIS) PURE;
01284     STDMETHOD(SetFormat)(THIS_ LPBITMAPINFOHEADER lpbi, LPVOID lpBits, INT x, INT y, INT dx, INT dy) PURE;
01285 };
01286 #undef INTERFACE
01287 
01288 #if !defined(__cplusplus) || defined(CINTERFACE)
01289 /*** IUnknown methods ***/
01290 #define IGetFrame_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
01291 #define IGetFrame_AddRef(p)             (p)->lpVtbl->AddRef(p)
01292 #define IGetFrame_Release(p)            (p)->lpVtbl->Release(p)
01293 /*** IGetFrame methods ***/
01294 #define IGetFrame_GetFrame(p,a)            (p)->lpVtbl->GetFrame(p,a)
01295 #define IGetFrame_Begin(p,a,b,c)           (p)->lpVtbl->Begin(p,a,b,c)
01296 #define IGetFrame_End(p)                   (p)->lpVtbl->End(p)
01297 #define IGetFrame_SetFormat(p,a,b,c,d,e,f) (p)->lpVtbl->SetFormat(p,a,b,c,d,e,f)
01298 #endif
01299 
01300 HRESULT WINAPI AVIClearClipboard(void);
01301 HRESULT WINAPI AVIGetFromClipboard(PAVIFILE *ppfile);
01302 HRESULT WINAPI AVIPutFileOnClipboard(PAVIFILE pfile);
01303 
01304 #ifdef OFN_READONLY
01305 BOOL WINAPI GetOpenFileNamePreviewA(LPOPENFILENAMEA lpofn);
01306 BOOL WINAPI GetOpenFileNamePreviewW(LPOPENFILENAMEW lpofn);
01307 #define GetOpenFileNamePreview WINELIB_NAME_AW(GetOpenFileNamePreview)
01308 BOOL WINAPI GetSaveFileNamePreviewA(LPOPENFILENAMEA lpofn);
01309 BOOL WINAPI GetSaveFileNamePreviewW(LPOPENFILENAMEW lpofn);
01310 #define GetSaveFileNamePreview WINELIB_NAME_AW(GetSaveFileNamePreview)
01311 #endif
01312 
01313 #define AVIERR_OK       0
01314 #define MAKE_AVIERR(error)  MAKE_SCODE(SEVERITY_ERROR,FACILITY_ITF,0x4000+error)
01315 
01316 #define AVIERR_UNSUPPORTED  MAKE_AVIERR(101)
01317 #define AVIERR_BADFORMAT    MAKE_AVIERR(102)
01318 #define AVIERR_MEMORY       MAKE_AVIERR(103)
01319 #define AVIERR_INTERNAL     MAKE_AVIERR(104)
01320 #define AVIERR_BADFLAGS     MAKE_AVIERR(105)
01321 #define AVIERR_BADPARAM     MAKE_AVIERR(106)
01322 #define AVIERR_BADSIZE      MAKE_AVIERR(107)
01323 #define AVIERR_BADHANDLE    MAKE_AVIERR(108)
01324 #define AVIERR_FILEREAD     MAKE_AVIERR(109)
01325 #define AVIERR_FILEWRITE    MAKE_AVIERR(110)
01326 #define AVIERR_FILEOPEN     MAKE_AVIERR(111)
01327 #define AVIERR_COMPRESSOR   MAKE_AVIERR(112)
01328 #define AVIERR_NOCOMPRESSOR MAKE_AVIERR(113)
01329 #define AVIERR_READONLY     MAKE_AVIERR(114)
01330 #define AVIERR_NODATA       MAKE_AVIERR(115)
01331 #define AVIERR_BUFFERTOOSMALL   MAKE_AVIERR(116)
01332 #define AVIERR_CANTCOMPRESS MAKE_AVIERR(117)
01333 #define AVIERR_USERABORT    MAKE_AVIERR(198)
01334 #define AVIERR_ERROR        MAKE_AVIERR(199)
01335 
01336 BOOL VFWAPIV MCIWndRegisterClass(void);
01337 
01338 HWND VFWAPIV MCIWndCreateA(HWND, HINSTANCE, DWORD, LPCSTR);
01339 HWND VFWAPIV MCIWndCreateW(HWND, HINSTANCE, DWORD, LPCWSTR);
01340 #define     MCIWndCreate WINELIB_NAME_AW(MCIWndCreate)
01341 
01342 #define MCIWNDOPENF_NEW         0x0001
01343 
01344 #define MCIWNDF_NOAUTOSIZEWINDOW    0x0001
01345 #define MCIWNDF_NOPLAYBAR       0x0002
01346 #define MCIWNDF_NOAUTOSIZEMOVIE     0x0004
01347 #define MCIWNDF_NOMENU          0x0008
01348 #define MCIWNDF_SHOWNAME        0x0010
01349 #define MCIWNDF_SHOWPOS         0x0020
01350 #define MCIWNDF_SHOWMODE        0x0040
01351 #define MCIWNDF_SHOWALL         0x0070
01352 
01353 #define MCIWNDF_NOTIFYMODE      0x0100
01354 #define MCIWNDF_NOTIFYPOS       0x0200
01355 #define MCIWNDF_NOTIFYSIZE      0x0400
01356 #define MCIWNDF_NOTIFYERROR     0x1000
01357 #define MCIWNDF_NOTIFYALL       0x1F00
01358 
01359 #define MCIWNDF_NOTIFYANSI      0x0080
01360 
01361 #define MCIWNDF_NOTIFYMEDIAA        0x0880
01362 #define MCIWNDF_NOTIFYMEDIAW        0x0800
01363 #define MCIWNDF_NOTIFYMEDIA WINELIB_NAME_AW(MCIWNDF_NOTIFYMEDIA)
01364 
01365 #define MCIWNDF_RECORD          0x2000
01366 #define MCIWNDF_NOERRORDLG      0x4000
01367 #define MCIWNDF_NOOPEN          0x8000
01368 
01369 #ifdef __cplusplus
01370 #define MCIWndSM ::SendMessage
01371 #else
01372 #define MCIWndSM SendMessage
01373 #endif
01374 
01375 #define MCIWndCanPlay(hWnd)         (BOOL)MCIWndSM(hWnd,MCIWNDM_CAN_PLAY,0,0)
01376 #define MCIWndCanRecord(hWnd)       (BOOL)MCIWndSM(hWnd,MCIWNDM_CAN_RECORD,0,0)
01377 #define MCIWndCanSave(hWnd)         (BOOL)MCIWndSM(hWnd,MCIWNDM_CAN_SAVE,0,0)
01378 #define MCIWndCanWindow(hWnd)       (BOOL)MCIWndSM(hWnd,MCIWNDM_CAN_WINDOW,0,0)
01379 #define MCIWndCanEject(hWnd)        (BOOL)MCIWndSM(hWnd,MCIWNDM_CAN_EJECT,0,0)
01380 #define MCIWndCanConfig(hWnd)       (BOOL)MCIWndSM(hWnd,MCIWNDM_CAN_CONFIG,0,0)
01381 #define MCIWndPaletteKick(hWnd)     (BOOL)MCIWndSM(hWnd,MCIWNDM_PALETTEKICK,0,0)
01382 
01383 #define MCIWndSave(hWnd,szFile)     (LONG)MCIWndSM(hWnd,MCI_SAVE,0,(LPARAM)(LPVOID)(szFile))
01384 #define MCIWndSaveDialog(hWnd)      MCIWndSave(hWnd,-1)
01385 
01386 #define MCIWndNew(hWnd,lp)          (LONG)MCIWndSM(hWnd,MCIWNDM_NEW,0,(LPARAM)(LPVOID)(lp))
01387 
01388 #define MCIWndRecord(hWnd)          (LONG)MCIWndSM(hWnd,MCI_RECORD,0,0)
01389 #define MCIWndOpen(hWnd,sz,f)       (LONG)MCIWndSM(hWnd,MCIWNDM_OPEN,(WPARAM)(UINT)(f),(LPARAM)(LPVOID)(sz))
01390 #define MCIWndOpenDialog(hWnd)      MCIWndOpen(hWnd,-1,0)
01391 #define MCIWndClose(hWnd)           (LONG)MCIWndSM(hWnd,MCI_CLOSE,0,0)
01392 #define MCIWndPlay(hWnd)            (LONG)MCIWndSM(hWnd,MCI_PLAY,0,0)
01393 #define MCIWndStop(hWnd)            (LONG)MCIWndSM(hWnd,MCI_STOP,0,0)
01394 #define MCIWndPause(hWnd)           (LONG)MCIWndSM(hWnd,MCI_PAUSE,0,0)
01395 #define MCIWndResume(hWnd)          (LONG)MCIWndSM(hWnd,MCI_RESUME,0,0)
01396 #define MCIWndSeek(hWnd,lPos)       (LONG)MCIWndSM(hWnd,MCI_SEEK,0,(LPARAM)(LONG)(lPos))
01397 #define MCIWndEject(hWnd)           (LONG)MCIWndSM(hWnd,MCIWNDM_EJECT,0,0)
01398 
01399 #define MCIWndHome(hWnd)            MCIWndSeek(hWnd,MCIWND_START)
01400 #define MCIWndEnd(hWnd)             MCIWndSeek(hWnd,MCIWND_END)
01401 
01402 #define MCIWndGetSource(hWnd,prc)   (LONG)MCIWndSM(hWnd,MCIWNDM_GET_SOURCE,0,(LPARAM)(LPRECT)(prc))
01403 #define MCIWndPutSource(hWnd,prc)   (LONG)MCIWndSM(hWnd,MCIWNDM_PUT_SOURCE,0,(LPARAM)(LPRECT)(prc))
01404 
01405 #define MCIWndGetDest(hWnd,prc)     (LONG)MCIWndSM(hWnd,MCIWNDM_GET_DEST,0,(LPARAM)(LPRECT)(prc))
01406 #define MCIWndPutDest(hWnd,prc)     (LONG)MCIWndSM(hWnd,MCIWNDM_PUT_DEST,0,(LPARAM)(LPRECT)(prc))
01407 
01408 #define MCIWndPlayReverse(hWnd)     (LONG)MCIWndSM(hWnd,MCIWNDM_PLAYREVERSE,0,0)
01409 #define MCIWndPlayFrom(hWnd,lPos)   (LONG)MCIWndSM(hWnd,MCIWNDM_PLAYFROM,0,(LPARAM)(LONG)(lPos))
01410 #define MCIWndPlayTo(hWnd,lPos)     (LONG)MCIWndSM(hWnd,MCIWNDM_PLAYTO,  0,(LPARAM)(LONG)(lPos))
01411 #define MCIWndPlayFromTo(hWnd,lStart,lEnd) (MCIWndSeek(hWnd,lStart),MCIWndPlayTo(hWnd,lEnd))
01412 
01413 #define MCIWndGetDeviceID(hWnd)     (UINT)MCIWndSM(hWnd,MCIWNDM_GETDEVICEID,0,0)
01414 #define MCIWndGetAlias(hWnd)        (UINT)MCIWndSM(hWnd,MCIWNDM_GETALIAS,0,0)
01415 #define MCIWndGetMode(hWnd,lp,len)  (LONG)MCIWndSM(hWnd,MCIWNDM_GETMODE,(WPARAM)(UINT)(len),(LPARAM)(LPTSTR)(lp))
01416 #define MCIWndGetPosition(hWnd)     (LONG)MCIWndSM(hWnd,MCIWNDM_GETPOSITION,0,0)
01417 #define MCIWndGetPositionString(hWnd,lp,len) (LONG)MCIWndSM(hWnd,MCIWNDM_GETPOSITION,(WPARAM)(UINT)(len),(LPARAM)(LPTSTR)(lp))
01418 #define MCIWndGetStart(hWnd)        (LONG)MCIWndSM(hWnd,MCIWNDM_GETSTART,0,0)
01419 #define MCIWndGetLength(hWnd)       (LONG)MCIWndSM(hWnd,MCIWNDM_GETLENGTH,0,0)
01420 #define MCIWndGetEnd(hWnd)          (LONG)MCIWndSM(hWnd,MCIWNDM_GETEND,0,0)
01421 
01422 #define MCIWndStep(hWnd,n)          (LONG)MCIWndSM(hWnd,MCI_STEP,0,(LPARAM)(LONG)(n))
01423 
01424 #define MCIWndDestroy(hWnd)         (VOID)MCIWndSM(hWnd,WM_CLOSE,0,0)
01425 #define MCIWndSetZoom(hWnd,iZoom)   (VOID)MCIWndSM(hWnd,MCIWNDM_SETZOOM,0,(LPARAM)(UINT)(iZoom))
01426 #define MCIWndGetZoom(hWnd)         (UINT)MCIWndSM(hWnd,MCIWNDM_GETZOOM,0,0)
01427 #define MCIWndSetVolume(hWnd,iVol)  (LONG)MCIWndSM(hWnd,MCIWNDM_SETVOLUME,0,(LPARAM)(UINT)(iVol))
01428 #define MCIWndGetVolume(hWnd)       (LONG)MCIWndSM(hWnd,MCIWNDM_GETVOLUME,0,0)
01429 #define MCIWndSetSpeed(hWnd,iSpeed) (LONG)MCIWndSM(hWnd,MCIWNDM_SETSPEED,0,(LPARAM)(UINT)(iSpeed))
01430 #define MCIWndGetSpeed(hWnd)        (LONG)MCIWndSM(hWnd,MCIWNDM_GETSPEED,0,0)
01431 #define MCIWndSetTimeFormat(hWnd,lp) (LONG)MCIWndSM(hWnd,MCIWNDM_SETTIMEFORMAT,0,(LPARAM)(LPTSTR)(lp))
01432 #define MCIWndGetTimeFormat(hWnd,lp,len) (LONG)MCIWndSM(hWnd,MCIWNDM_GETTIMEFORMAT,(WPARAM)(UINT)(len),(LPARAM)(LPTSTR)(lp))
01433 #define MCIWndValidateMedia(hWnd)   (VOID)MCIWndSM(hWnd,MCIWNDM_VALIDATEMEDIA,0,0)
01434 
01435 #define MCIWndSetRepeat(hWnd,f)     (void)MCIWndSM(hWnd,MCIWNDM_SETREPEAT,0,(LPARAM)(BOOL)(f))
01436 #define MCIWndGetRepeat(hWnd)       (BOOL)MCIWndSM(hWnd,MCIWNDM_GETREPEAT,0,0)
01437 
01438 #define MCIWndUseFrames(hWnd)       MCIWndSetTimeFormat(hWnd,TEXT("frames"))
01439 #define MCIWndUseTime(hWnd)         MCIWndSetTimeFormat(hWnd,TEXT("ms"))
01440 
01441 #define MCIWndSetActiveTimer(hWnd,active)               \
01442     (VOID)MCIWndSM(hWnd,MCIWNDM_SETACTIVETIMER,         \
01443     (WPARAM)(UINT)(active),0L)
01444 #define MCIWndSetInactiveTimer(hWnd,inactive)               \
01445     (VOID)MCIWndSM(hWnd,MCIWNDM_SETINACTIVETIMER,           \
01446     (WPARAM)(UINT)(inactive),0L)
01447 #define MCIWndSetTimers(hWnd,active,inactive)               \
01448         (VOID)MCIWndSM(hWnd,MCIWNDM_SETTIMERS,(WPARAM)(UINT)(active),\
01449         (LPARAM)(UINT)(inactive))
01450 #define MCIWndGetActiveTimer(hWnd)                  \
01451     (UINT)MCIWndSM(hWnd,MCIWNDM_GETACTIVETIMER,0,0L);
01452 #define MCIWndGetInactiveTimer(hWnd)                    \
01453     (UINT)MCIWndSM(hWnd,MCIWNDM_GETINACTIVETIMER,0,0L);
01454 
01455 #define MCIWndRealize(hWnd,fBkgnd) (LONG)MCIWndSM(hWnd,MCIWNDM_REALIZE,(WPARAM)(BOOL)(fBkgnd),0)
01456 
01457 #define MCIWndSendString(hWnd,sz)  (LONG)MCIWndSM(hWnd,MCIWNDM_SENDSTRING,0,(LPARAM)(LPTSTR)(sz))
01458 #define MCIWndReturnString(hWnd,lp,len)  (LONG)MCIWndSM(hWnd,MCIWNDM_RETURNSTRING,(WPARAM)(UINT)(len),(LPARAM)(LPVOID)(lp))
01459 #define MCIWndGetError(hWnd,lp,len) (LONG)MCIWndSM(hWnd,MCIWNDM_GETERROR,(WPARAM)(UINT)(len),(LPARAM)(LPVOID)(lp))
01460 
01461 #define MCIWndGetPalette(hWnd)      (HPALETTE)MCIWndSM(hWnd,MCIWNDM_GETPALETTE,0,0)
01462 #define MCIWndSetPalette(hWnd,hpal) (LONG)MCIWndSM(hWnd,MCIWNDM_SETPALETTE,(WPARAM)(HPALETTE)(hpal),0)
01463 
01464 #define MCIWndGetFileName(hWnd,lp,len) (LONG)MCIWndSM(hWnd,MCIWNDM_GETFILENAME,(WPARAM)(UINT)(len),(LPARAM)(LPVOID)(lp))
01465 #define MCIWndGetDevice(hWnd,lp,len)   (LONG)MCIWndSM(hWnd,MCIWNDM_GETDEVICE,(WPARAM)(UINT)(len),(LPARAM)(LPVOID)(lp))
01466 
01467 #define MCIWndGetStyles(hWnd) (UINT)MCIWndSM(hWnd,MCIWNDM_GETSTYLES,0,0L)
01468 #define MCIWndChangeStyles(hWnd,mask,value) (LONG)MCIWndSM(hWnd,MCIWNDM_CHANGESTYLES,(WPARAM)(UINT)(mask),(LPARAM)(LONG)(value))
01469 
01470 #define MCIWndOpenInterface(hWnd,pUnk)  (LONG)MCIWndSM(hWnd,MCIWNDM_OPENINTERFACE,0,(LPARAM)(LPUNKNOWN)(pUnk))
01471 
01472 #define MCIWndSetOwner(hWnd,hWndP)  (LONG)MCIWndSM(hWnd,MCIWNDM_SETOWNER,(WPARAM)(hWndP),0)
01473 
01474 #define MCIWNDM_GETDEVICEID (WM_USER + 100)
01475 #define MCIWNDM_GETSTART    (WM_USER + 103)
01476 #define MCIWNDM_GETLENGTH   (WM_USER + 104)
01477 #define MCIWNDM_GETEND      (WM_USER + 105)
01478 #define MCIWNDM_EJECT       (WM_USER + 107)
01479 #define MCIWNDM_SETZOOM     (WM_USER + 108)
01480 #define MCIWNDM_GETZOOM         (WM_USER + 109)
01481 #define MCIWNDM_SETVOLUME   (WM_USER + 110)
01482 #define MCIWNDM_GETVOLUME   (WM_USER + 111)
01483 #define MCIWNDM_SETSPEED    (WM_USER + 112)
01484 #define MCIWNDM_GETSPEED    (WM_USER + 113)
01485 #define MCIWNDM_SETREPEAT   (WM_USER + 114)
01486 #define MCIWNDM_GETREPEAT   (WM_USER + 115)
01487 #define MCIWNDM_REALIZE         (WM_USER + 118)
01488 #define MCIWNDM_VALIDATEMEDIA   (WM_USER + 121)
01489 #define MCIWNDM_PLAYFROM    (WM_USER + 122)
01490 #define MCIWNDM_PLAYTO          (WM_USER + 123)
01491 #define MCIWNDM_GETPALETTE      (WM_USER + 126)
01492 #define MCIWNDM_SETPALETTE      (WM_USER + 127)
01493 #define MCIWNDM_SETTIMERS   (WM_USER + 129)
01494 #define MCIWNDM_SETACTIVETIMER  (WM_USER + 130)
01495 #define MCIWNDM_SETINACTIVETIMER (WM_USER + 131)
01496 #define MCIWNDM_GETACTIVETIMER  (WM_USER + 132)
01497 #define MCIWNDM_GETINACTIVETIMER (WM_USER + 133)
01498 #define MCIWNDM_CHANGESTYLES    (WM_USER + 135)
01499 #define MCIWNDM_GETSTYLES   (WM_USER + 136)
01500 #define MCIWNDM_GETALIAS    (WM_USER + 137)
01501 #define MCIWNDM_PLAYREVERSE (WM_USER + 139)
01502 #define MCIWNDM_GET_SOURCE      (WM_USER + 140)
01503 #define MCIWNDM_PUT_SOURCE      (WM_USER + 141)
01504 #define MCIWNDM_GET_DEST        (WM_USER + 142)
01505 #define MCIWNDM_PUT_DEST        (WM_USER + 143)
01506 #define MCIWNDM_CAN_PLAY        (WM_USER + 144)
01507 #define MCIWNDM_CAN_WINDOW      (WM_USER + 145)
01508 #define MCIWNDM_CAN_RECORD      (WM_USER + 146)
01509 #define MCIWNDM_CAN_SAVE        (WM_USER + 147)
01510 #define MCIWNDM_CAN_EJECT       (WM_USER + 148)
01511 #define MCIWNDM_CAN_CONFIG      (WM_USER + 149)
01512 #define MCIWNDM_PALETTEKICK     (WM_USER + 150)
01513 #define MCIWNDM_OPENINTERFACE   (WM_USER + 151)
01514 #define MCIWNDM_SETOWNER    (WM_USER + 152)
01515 
01516 #define MCIWNDM_SENDSTRINGA (WM_USER + 101)
01517 #define MCIWNDM_GETPOSITIONA    (WM_USER + 102)
01518 #define MCIWNDM_GETMODEA    (WM_USER + 106)
01519 #define MCIWNDM_SETTIMEFORMATA  (WM_USER + 119)
01520 #define MCIWNDM_GETTIMEFORMATA  (WM_USER + 120)
01521 #define MCIWNDM_GETFILENAMEA    (WM_USER + 124)
01522 #define MCIWNDM_GETDEVICEA      (WM_USER + 125)
01523 #define MCIWNDM_GETERRORA       (WM_USER + 128)
01524 #define MCIWNDM_NEWA        (WM_USER + 134)
01525 #define MCIWNDM_RETURNSTRINGA   (WM_USER + 138)
01526 #define MCIWNDM_OPENA       (WM_USER + 153)
01527 
01528 #define MCIWNDM_SENDSTRINGW (WM_USER + 201)
01529 #define MCIWNDM_GETPOSITIONW    (WM_USER + 202)
01530 #define MCIWNDM_GETMODEW    (WM_USER + 206)
01531 #define MCIWNDM_SETTIMEFORMATW  (WM_USER + 219)
01532 #define MCIWNDM_GETTIMEFORMATW  (WM_USER + 220)
01533 #define MCIWNDM_GETFILENAMEW    (WM_USER + 224)
01534 #define MCIWNDM_GETDEVICEW      (WM_USER + 225)
01535 #define MCIWNDM_GETERRORW       (WM_USER + 228)
01536 #define MCIWNDM_NEWW        (WM_USER + 234)
01537 #define MCIWNDM_RETURNSTRINGW   (WM_USER + 238)
01538 #define MCIWNDM_OPENW       (WM_USER + 252)
01539 
01540 #define MCIWNDM_SENDSTRING  WINELIB_NAME_AW(MCIWNDM_SENDSTRING)
01541 #define MCIWNDM_GETPOSITION WINELIB_NAME_AW(MCIWNDM_GETPOSITION)
01542 #define MCIWNDM_GETMODE     WINELIB_NAME_AW(MCIWNDM_GETMODE)
01543 #define MCIWNDM_SETTIMEFORMAT   WINELIB_NAME_AW(MCIWNDM_SETTIMEFORMAT)
01544 #define MCIWNDM_GETTIMEFORMAT   WINELIB_NAME_AW(MCIWNDM_GETTIMEFORMAT)
01545 #define MCIWNDM_GETFILENAME WINELIB_NAME_AW(MCIWNDM_GETFILENAME)
01546 #define MCIWNDM_GETDEVICE   WINELIB_NAME_AW(MCIWNDM_GETDEVICE)
01547 #define MCIWNDM_GETERROR    WINELIB_NAME_AW(MCIWNDM_GETERROR)
01548 #define MCIWNDM_NEW     WINELIB_NAME_AW(MCIWNDM_NEW)
01549 #define MCIWNDM_RETURNSTRING    WINELIB_NAME_AW(MCIWNDM_RETURNSTRING)
01550 #define MCIWNDM_OPEN        WINELIB_NAME_AW(MCIWNDM_OPEN)
01551 
01552 #define MCIWNDM_NOTIFYMODE      (WM_USER + 200)
01553 #define MCIWNDM_NOTIFYPOS   (WM_USER + 201)
01554 #define MCIWNDM_NOTIFYSIZE  (WM_USER + 202)
01555 #define MCIWNDM_NOTIFYMEDIA     (WM_USER + 203)
01556 #define MCIWNDM_NOTIFYERROR     (WM_USER + 205)
01557 
01558 #define MCIWND_START                -1
01559 #define MCIWND_END                  -2
01560 
01561 /********************************************
01562  * DrawDib declarations
01563  */
01564 
01565 typedef struct
01566 { 
01567     LONG    timeCount; 
01568     LONG    timeDraw; 
01569     LONG    timeDecompress; 
01570     LONG    timeDither; 
01571     LONG    timeStretch; 
01572     LONG    timeBlt; 
01573     LONG    timeSetDIBits; 
01574 } DRAWDIBTIME, *LPDRAWDIBTIME; 
01575 
01576 HDRAWDIB VFWAPI DrawDibOpen( void );
01577 UINT VFWAPI DrawDibRealize(HDRAWDIB hdd, HDC hdc, BOOL fBackground);
01578 
01579 BOOL VFWAPI DrawDibBegin(HDRAWDIB hdd, HDC hdc, INT dxDst, INT dyDst,
01580              LPBITMAPINFOHEADER lpbi, INT dxSrc, INT dySrc, UINT wFlags);
01581 
01582 BOOL VFWAPI DrawDibDraw(HDRAWDIB hdd, HDC hdc, INT xDst, INT yDst, INT dxDst, INT dyDst,
01583             LPBITMAPINFOHEADER lpbi, LPVOID lpBits,
01584             INT xSrc, INT ySrc, INT dxSrc, INT dySrc, UINT wFlags);
01585 
01586 /* DrawDibDraw flags */
01587 
01588 #define DDF_UPDATE          0x0002
01589 #define DDF_SAME_HDC            0x0004
01590 #define DDF_SAME_DRAW           0x0008
01591 #define DDF_DONTDRAW            0x0010
01592 #define DDF_ANIMATE         0x0020
01593 #define DDF_BUFFER          0x0040
01594 #define DDF_JUSTDRAWIT          0x0080
01595 #define DDF_FULLSCREEN          0x0100
01596 #define DDF_BACKGROUNDPAL       0x0200
01597 #define DDF_NOTKEYFRAME         0x0400
01598 #define DDF_HURRYUP         0x0800
01599 #define DDF_HALFTONE            0x1000
01600 
01601 #define DDF_PREROLL                 DDF_DONTDRAW
01602 #define DDF_SAME_DIB                DDF_SAME_DRAW
01603 #define DDF_SAME_SIZE               DDF_SAME_DRAW
01604 
01605 BOOL VFWAPI DrawDibSetPalette(HDRAWDIB hdd, HPALETTE hpal);
01606 HPALETTE VFWAPI DrawDibGetPalette(HDRAWDIB hdd);
01607 BOOL VFWAPI DrawDibChangePalette(HDRAWDIB hdd, int iStart, int iLen, LPPALETTEENTRY lppe);
01608 LPVOID VFWAPI DrawDibGetBuffer(HDRAWDIB hdd, LPBITMAPINFOHEADER lpbi, DWORD dwSize, DWORD dwFlags);
01609 
01610 BOOL VFWAPI DrawDibStart(HDRAWDIB hdd, DWORD rate);
01611 BOOL VFWAPI DrawDibStop(HDRAWDIB hdd);
01612 #define DrawDibUpdate(hdd, hdc, x, y) \
01613         DrawDibDraw(hdd, hdc, x, y, 0, 0, NULL, NULL, 0, 0, 0, 0, DDF_UPDATE)
01614 
01615 BOOL VFWAPI DrawDibEnd(HDRAWDIB hdd);
01616 BOOL VFWAPI DrawDibClose(HDRAWDIB hdd);
01617 BOOL VFWAPI DrawDibTime(HDRAWDIB hdd, LPDRAWDIBTIME lpddtime);
01618 
01619 /* display profiling */
01620 #define PD_CAN_DRAW_DIB         0x0001
01621 #define PD_CAN_STRETCHDIB       0x0002
01622 #define PD_STRETCHDIB_1_1_OK    0x0004
01623 #define PD_STRETCHDIB_1_2_OK    0x0008
01624 #define PD_STRETCHDIB_1_N_OK    0x0010
01625 
01626 DWORD VFWAPI DrawDibProfileDisplay(LPBITMAPINFOHEADER lpbi);
01627 
01628 DECLARE_HANDLE(HVIDEO);
01629 typedef HVIDEO *LPHVIDEO;
01630 
01631 DWORD VFWAPI VideoForWindowsVersion(void);
01632 
01633 LONG  VFWAPI InitVFW(void);
01634 LONG  VFWAPI TermVFW(void);
01635 
01636 #define DV_ERR_OK            (0)
01637 #define DV_ERR_BASE          (1)
01638 #define DV_ERR_NONSPECIFIC   (DV_ERR_BASE)
01639 #define DV_ERR_BADFORMAT     (DV_ERR_BASE + 1)
01640 #define DV_ERR_STILLPLAYING  (DV_ERR_BASE + 2)
01641 #define DV_ERR_UNPREPARED    (DV_ERR_BASE + 3)
01642 #define DV_ERR_SYNC          (DV_ERR_BASE + 4)
01643 #define DV_ERR_TOOMANYCHANNELS (DV_ERR_BASE + 5)
01644 #define DV_ERR_NOTDETECTED   (DV_ERR_BASE + 6)
01645 #define DV_ERR_BADINSTALL    (DV_ERR_BASE + 7)
01646 #define DV_ERR_CREATEPALETTE (DV_ERR_BASE + 8)
01647 #define DV_ERR_SIZEFIELD     (DV_ERR_BASE + 9)
01648 #define DV_ERR_PARAM1        (DV_ERR_BASE + 10)
01649 #define DV_ERR_PARAM2        (DV_ERR_BASE + 11)
01650 #define DV_ERR_CONFIG1       (DV_ERR_BASE + 12)
01651 #define DV_ERR_CONFIG2       (DV_ERR_BASE + 13)
01652 #define DV_ERR_FLAGS         (DV_ERR_BASE + 14)
01653 #define DV_ERR_13            (DV_ERR_BASE + 15)
01654 
01655 #define DV_ERR_NOTSUPPORTED  (DV_ERR_BASE + 16)
01656 #define DV_ERR_NOMEM         (DV_ERR_BASE + 17)
01657 #define DV_ERR_ALLOCATED     (DV_ERR_BASE + 18)
01658 #define DV_ERR_BADDEVICEID   (DV_ERR_BASE + 19)
01659 #define DV_ERR_INVALHANDLE   (DV_ERR_BASE + 20)
01660 #define DV_ERR_BADERRNUM     (DV_ERR_BASE + 21)
01661 #define DV_ERR_NO_BUFFERS    (DV_ERR_BASE + 22)
01662 
01663 #define DV_ERR_MEM_CONFLICT  (DV_ERR_BASE + 23)
01664 #define DV_ERR_IO_CONFLICT   (DV_ERR_BASE + 24)
01665 #define DV_ERR_DMA_CONFLICT  (DV_ERR_BASE + 25)
01666 #define DV_ERR_INT_CONFLICT  (DV_ERR_BASE + 26)
01667 #define DV_ERR_PROTECT_ONLY  (DV_ERR_BASE + 27)
01668 #define DV_ERR_LASTERROR     (DV_ERR_BASE + 27)
01669 
01670 #define DV_ERR_USER_MSG      (DV_ERR_BASE + 1000)
01671 
01672 #ifndef MM_DRVM_OPEN
01673 #define MM_DRVM_OPEN       0x3D0
01674 #define MM_DRVM_CLOSE      0x3D1
01675 #define MM_DRVM_DATA       0x3D2
01676 #define MM_DRVM_ERROR      0x3D3
01677 
01678 #define DV_VM_OPEN         MM_DRVM_OPEN
01679 #define DV_VM_CLOSE        MM_DRVM_CLOSE
01680 #define DV_VM_DATA         MM_DRVM_DATA
01681 #define DV_VM_ERROR        MM_DRVM_ERROR
01682 #endif
01683 
01684 typedef struct videohdr_tag {
01685     LPBYTE      lpData;
01686     DWORD       dwBufferLength;
01687     DWORD       dwBytesUsed;
01688     DWORD       dwTimeCaptured;
01689     DWORD_PTR   dwUser;
01690     DWORD       dwFlags;
01691     DWORD_PTR   dwReserved[4];
01692 } VIDEOHDR, *PVIDEOHDR, *LPVIDEOHDR;
01693 
01694 #define VHDR_DONE       0x00000001
01695 #define VHDR_PREPARED   0x00000002
01696 #define VHDR_INQUEUE    0x00000004
01697 #define VHDR_KEYFRAME   0x00000008
01698 
01699 typedef struct channel_caps_tag {
01700     DWORD       dwFlags;
01701     DWORD       dwSrcRectXMod;
01702     DWORD       dwSrcRectYMod;
01703     DWORD       dwSrcRectWidthMod;
01704     DWORD       dwSrcRectHeightMod;
01705     DWORD       dwDstRectXMod;
01706     DWORD       dwDstRectYMod;
01707     DWORD       dwDstRectWidthMod;
01708     DWORD       dwDstRectHeightMod;
01709 } CHANNEL_CAPS, *PCHANNEL_CAPS, *LPCHANNEL_CAPS;
01710 
01711 #define VCAPS_OVERLAY       0x00000001
01712 #define VCAPS_SRC_CAN_CLIP  0x00000002
01713 #define VCAPS_DST_CAN_CLIP  0x00000004
01714 #define VCAPS_CAN_SCALE     0x00000008
01715 
01716 #define VIDEO_EXTERNALIN        0x0001
01717 #define VIDEO_EXTERNALOUT       0x0002
01718 #define VIDEO_IN                0x0004
01719 #define VIDEO_OUT               0x0008
01720 
01721 #define VIDEO_DLG_QUERY         0x0010
01722 
01723 #define VIDEO_CONFIGURE_QUERY   0x8000
01724 
01725 #define VIDEO_CONFIGURE_SET     0x1000
01726 
01727 #define VIDEO_CONFIGURE_GET     0x2000
01728 #define VIDEO_CONFIGURE_QUERYSIZE 0x0001
01729 
01730 #define VIDEO_CONFIGURE_CURRENT 0x0010
01731 #define VIDEO_CONFIGURE_NOMINAL 0x0020
01732 #define VIDEO_CONFIGURE_MIN     0x0040
01733 #define VIDEO_CONFIGURE_MAX     0x0080
01734 
01735 #define DVM_USER                0x4000
01736 
01737 #define DVM_CONFIGURE_START     0x1000
01738 #define DVM_CONFIGURE_END       0x1FFF
01739 
01740 #define DVM_PALETTE             (DVM_CONFIGURE_START + 1)
01741 #define DVM_FORMAT              (DVM_CONFIGURE_START + 2)
01742 #define DVM_PALETTERGB555       (DVM_CONFIGURE_START + 3)
01743 #define DVM_SRC_RECT            (DVM_CONFIGURE_START + 4)
01744 #define DVM_DST_RECT            (DVM_CONFIGURE_START + 5)
01745 
01746 #define AVICapSM(hwnd,m,w,l) ((IsWindow(hwnd)) ? SendMessage(hwnd,m,w,l) : 0)
01747 
01748 #define WM_CAP_START                    WM_USER
01749 
01750 #define WM_CAP_UNICODE_START            WM_USER+100
01751 
01752 #define WM_CAP_GET_CAPSTREAMPTR         (WM_CAP_START + 1)
01753 
01754 #define WM_CAP_SET_CALLBACK_ERRORW      (WM_CAP_UNICODE_START + 2)
01755 #define WM_CAP_SET_CALLBACK_STATUSW     (WM_CAP_UNICODE_START + 3)
01756 #define WM_CAP_SET_CALLBACK_ERRORA      (WM_CAP_START + 2)
01757 #define WM_CAP_SET_CALLBACK_STATUSA     (WM_CAP_START+ 3)
01758 
01759 #define WM_CAP_SET_CALLBACK_ERROR       WINELIB_NAME_AW(WM_CAP_SET_CALLBACK_ERROR)
01760 #define WM_CAP_SET_CALLBACK_STATUS      WINELIB_NAME_AW(WM_CAP_SET_CALLBACK_STATUS)
01761 
01762 #define WM_CAP_SET_CALLBACK_YIELD       (WM_CAP_START +  4)
01763 #define WM_CAP_SET_CALLBACK_FRAME       (WM_CAP_START +  5)
01764 #define WM_CAP_SET_CALLBACK_VIDEOSTREAM (WM_CAP_START +  6)
01765 #define WM_CAP_SET_CALLBACK_WAVESTREAM  (WM_CAP_START +  7)
01766 #define WM_CAP_GET_USER_DATA            (WM_CAP_START +  8)
01767 #define WM_CAP_SET_USER_DATA            (WM_CAP_START +  9)
01768 
01769 #define WM_CAP_DRIVER_CONNECT           (WM_CAP_START +  10)
01770 #define WM_CAP_DRIVER_DISCONNECT        (WM_CAP_START +  11)
01771 
01772 #define WM_CAP_DRIVER_GET_NAMEA         (WM_CAP_START +  12)
01773 #define WM_CAP_DRIVER_GET_VERSIONA      (WM_CAP_START +  13)
01774 #define WM_CAP_DRIVER_GET_NAMEW         (WM_CAP_UNICODE_START +  12)
01775 #define WM_CAP_DRIVER_GET_VERSIONW      (WM_CAP_UNICODE_START +  13)
01776 
01777 #define WM_CAP_DRIVER_GET_NAME          WINELIB_NAME_AW(WM_CAP_DRIVER_GET_NAME)
01778 #define WM_CAP_DRIVER_GET_VERSION       WINELIB_NAME_AW(WM_CAP_DRIVER_GET_VERSION)
01779 
01780 #define WM_CAP_DRIVER_GET_CAPS          (WM_CAP_START +  14)
01781 
01782 #define WM_CAP_FILE_SET_CAPTURE_FILEA   (WM_CAP_START +  20)
01783 #define WM_CAP_FILE_GET_CAPTURE_FILEA   (WM_CAP_START +  21)
01784 #define WM_CAP_FILE_ALLOCATE            (WM_CAP_START +  22)
01785 #define WM_CAP_FILE_SAVEASA             (WM_CAP_START +  23)
01786 #define WM_CAP_FILE_SET_INFOCHUNK       (WM_CAP_START +  24)
01787 #define WM_CAP_FILE_SAVEDIBA            (WM_CAP_START +  25)
01788 #define WM_CAP_FILE_SET_CAPTURE_FILEW   (WM_CAP_UNICODE_START +  20)
01789 #define WM_CAP_FILE_GET_CAPTURE_FILEW   (WM_CAP_UNICODE_START +  21)
01790 #define WM_CAP_FILE_SAVEASW             (WM_CAP_UNICODE_START +  23)
01791 #define WM_CAP_FILE_SAVEDIBW            (WM_CAP_UNICODE_START +  25)
01792 
01793 #define WM_CAP_FILE_SET_CAPTURE_FILE    WINELIB_NAME_AW(WM_CAP_FILE_SET_CAPTURE_FILE)
01794 #define WM_CAP_FILE_GET_CAPTURE_FILE    WINELIB_NAME_AW(WM_CAP_FILE_GET_CAPTURE_FILE)
01795 #define WM_CAP_FILE_SAVEAS              WINELIB_NAME_AW(WM_CAP_FILE_SAVEAS)
01796 #define WM_CAP_FILE_SAVEDIB             WINELIB_NAME_AW(WM_CAP_FILE_SAVEDIB)
01797 
01798 #define WM_CAP_EDIT_COPY                (WM_CAP_START +  30)
01799 
01800 #define WM_CAP_SET_AUDIOFORMAT          (WM_CAP_START +  35)
01801 #define WM_CAP_GET_AUDIOFORMAT          (WM_CAP_START +  36)
01802 
01803 #define WM_CAP_DLG_VIDEOFORMAT          (WM_CAP_START +  41)
01804 #define WM_CAP_DLG_VIDEOSOURCE          (WM_CAP_START +  42)
01805 #define WM_CAP_DLG_VIDEODISPLAY         (WM_CAP_START +  43)
01806 #define WM_CAP_GET_VIDEOFORMAT          (WM_CAP_START +  44)
01807 #define WM_CAP_SET_VIDEOFORMAT          (WM_CAP_START +  45)
01808 #define WM_CAP_DLG_VIDEOCOMPRESSION     (WM_CAP_START +  46)
01809 
01810 #define WM_CAP_SET_PREVIEW              (WM_CAP_START +  50)
01811 #define WM_CAP_SET_OVERLAY              (WM_CAP_START +  51)
01812 #define WM_CAP_SET_PREVIEWRATE          (WM_CAP_START +  52)
01813 #define WM_CAP_SET_SCALE                (WM_CAP_START +  53)
01814 #define WM_CAP_GET_STATUS               (WM_CAP_START +  54)
01815 #define WM_CAP_SET_SCROLL               (WM_CAP_START +  55)
01816 
01817 #define WM_CAP_GRAB_FRAME               (WM_CAP_START +  60)
01818 #define WM_CAP_GRAB_FRAME_NOSTOP        (WM_CAP_START +  61)
01819 
01820 #define WM_CAP_SEQUENCE                 (WM_CAP_START +  62)
01821 #define WM_CAP_SEQUENCE_NOFILE          (WM_CAP_START +  63)
01822 #define WM_CAP_SET_SEQUENCE_SETUP       (WM_CAP_START +  64)
01823 #define WM_CAP_GET_SEQUENCE_SETUP       (WM_CAP_START +  65)
01824 
01825 #define WM_CAP_SET_MCI_DEVICEA          (WM_CAP_START +  66)
01826 #define WM_CAP_GET_MCI_DEVICEA          (WM_CAP_START +  67)
01827 #define WM_CAP_SET_MCI_DEVICEW          (WM_CAP_UNICODE_START +  66)
01828 #define WM_CAP_GET_MCI_DEVICEW          (WM_CAP_UNICODE_START +  67)
01829 
01830 #define WM_CAP_SET_MCI_DEVICE           WINELIB_NAME_AW(WM_CAP_SET_MCI_DEVICE)
01831 #define WM_CAP_GET_MCI_DEVICE           WINELIB_NAME_AW(WM_CAP_GET_MCI_DEVICE)
01832 
01833 #define WM_CAP_STOP                     (WM_CAP_START +  68)
01834 #define WM_CAP_ABORT                    (WM_CAP_START +  69)
01835 
01836 #define WM_CAP_SINGLE_FRAME_OPEN        (WM_CAP_START +  70)
01837 #define WM_CAP_SINGLE_FRAME_CLOSE       (WM_CAP_START +  71)
01838 #define WM_CAP_SINGLE_FRAME             (WM_CAP_START +  72)
01839 
01840 #define WM_CAP_PAL_OPENA                (WM_CAP_START +  80)
01841 #define WM_CAP_PAL_SAVEA                (WM_CAP_START +  81)
01842 #define WM_CAP_PAL_OPENW                (WM_CAP_UNICODE_START +  80)
01843 #define WM_CAP_PAL_SAVEW                (WM_CAP_UNICODE_START +  81)
01844 
01845 #define WM_CAP_PAL_OPEN                 WINELIB_NAME_AW(WM_CAP_PAL_OPEN)
01846 #define WM_CAP_PAL_SAVE                 WINELIB_NAME_AW(WM_CAP_PAL_SAVE)
01847 
01848 #define WM_CAP_PAL_PASTE                (WM_CAP_START +  82)
01849 #define WM_CAP_PAL_AUTOCREATE           (WM_CAP_START +  83)
01850 #define WM_CAP_PAL_MANUALCREATE         (WM_CAP_START +  84)
01851 
01852 #define WM_CAP_SET_CALLBACK_CAPCONTROL  (WM_CAP_START +  85)
01853 
01854 #define WM_CAP_UNICODE_END              WM_CAP_PAL_SAVEW
01855 #define WM_CAP_END                      WM_CAP_UNICODE_END
01856 
01857 typedef struct tagCapDriverCaps {
01858     UINT        wDeviceIndex;
01859     BOOL        fHasOverlay;
01860     BOOL        fHasDlgVideoSource;
01861     BOOL        fHasDlgVideoFormat;
01862     BOOL        fHasDlgVideoDisplay;
01863     BOOL        fCaptureInitialized;
01864     BOOL        fDriverSuppliesPalettes;
01865     HANDLE      hVideoIn;
01866     HANDLE      hVideoOut;
01867     HANDLE      hVideoExtIn;
01868     HANDLE      hVideoExtOut;
01869 } CAPDRIVERCAPS, *PCAPDRIVERCAPS, *LPCAPDRIVERCAPS;
01870 
01871 typedef struct tagCapStatus {
01872     UINT        uiImageWidth;
01873     UINT        uiImageHeight;
01874     BOOL        fLiveWindow;
01875     BOOL        fOverlayWindow;
01876     BOOL        fScale;
01877     POINT       ptScroll;
01878     BOOL        fUsingDefaultPalette;
01879     BOOL        fAudioHardware;
01880     BOOL        fCapFileExists;
01881     DWORD       dwCurrentVideoFrame;
01882     DWORD       dwCurrentVideoFramesDropped;
01883     DWORD       dwCurrentWaveSamples;
01884     DWORD       dwCurrentTimeElapsedMS;
01885     HPALETTE    hPalCurrent;
01886     BOOL        fCapturingNow;
01887     DWORD       dwReturn;
01888     UINT        wNumVideoAllocated;
01889     UINT        wNumAudioAllocated;
01890 } CAPSTATUS, *PCAPSTATUS, *LPCAPSTATUS;
01891 
01892 
01893 typedef struct tagCaptureParms {
01894     DWORD       dwRequestMicroSecPerFrame;
01895     BOOL        fMakeUserHitOKToCapture;
01896     UINT        wPercentDropForError;
01897     BOOL        fYield;
01898     DWORD       dwIndexSize;
01899     UINT        wChunkGranularity;
01900     BOOL        fUsingDOSMemory;
01901     UINT        wNumVideoRequested;
01902     BOOL        fCaptureAudio;
01903     UINT        wNumAudioRequested;
01904     UINT        vKeyAbort;
01905     BOOL        fAbortLeftMouse;
01906     BOOL        fAbortRightMouse;
01907     BOOL        fLimitEnabled;
01908     UINT        wTimeLimit;
01909     BOOL        fMCIControl;
01910     BOOL        fStepMCIDevice;
01911     DWORD       dwMCIStartTime;
01912     DWORD       dwMCIStopTime;
01913     BOOL        fStepCaptureAt2x;
01914     UINT        wStepCaptureAverageFrames;
01915     DWORD       dwAudioBufferSize;
01916     BOOL        fDisableWriteCache;
01917     UINT        AVStreamMaster;
01918 } CAPTUREPARMS, *PCAPTUREPARMS, *LPCAPTUREPARMS;
01919 
01920 typedef LRESULT (CALLBACK* CAPYIELDCALLBACK)  (HWND hWnd);
01921 typedef LRESULT (CALLBACK* CAPSTATUSCALLBACKW) (HWND hWnd, int nID, LPCWSTR lpsz);
01922 typedef LRESULT (CALLBACK* CAPERRORCALLBACKW)  (HWND hWnd, int nID, LPCWSTR lpsz);
01923 typedef LRESULT (CALLBACK* CAPSTATUSCALLBACKA) (HWND hWnd, int nID, LPCSTR lpsz);
01924 typedef LRESULT (CALLBACK* CAPERRORCALLBACKA)  (HWND hWnd, int nID, LPCSTR lpsz);
01925 typedef LRESULT (CALLBACK* CAPVIDEOCALLBACK)  (HWND hWnd, LPVIDEOHDR lpVHdr);
01926 typedef LRESULT (CALLBACK* CAPWAVECALLBACK)   (HWND hWnd, LPWAVEHDR lpWHdr);
01927 typedef LRESULT (CALLBACK* CAPCONTROLCALLBACK)(HWND hWnd, int nState);
01928 
01929 HWND VFWAPI capCreateCaptureWindowA(LPCSTR,DWORD,INT,INT,INT,INT,HWND,INT);
01930 HWND VFWAPI capCreateCaptureWindowW(LPCWSTR,DWORD,INT,INT,INT,INT,HWND,INT);
01931 #define     capCreateCaptureWindow WINELIB_NAME_AW(capCreateCaptureWindow)
01932 BOOL VFWAPI capGetDriverDescriptionA(WORD,LPSTR,INT,LPSTR,INT);
01933 BOOL VFWAPI capGetDriverDescriptionW(WORD,LPWSTR,INT,LPWSTR,INT);
01934 #define     capGetDriverDescription WINELIB_NAME_AW(capGetDriverDescription)
01935 
01936 #ifdef __cplusplus
01937 }
01938 #endif  /* __cplusplus */
01939 
01940 #endif /* __WINE_VFW_H */

Generated on Sat May 26 2012 04:31:20 for ReactOS by doxygen 1.7.6.1

ReactOS is a registered trademark or a trademark of ReactOS Foundation in the United States and other countries.