wine headers cleanup

- WAVEFORMATEX & BITMAPINFOHEADER decl moved to stheader.h
- lots of useless include wine/* removed from mplayer code
- fixed few warnings


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@7472 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
arpi 2002-09-22 00:43:14 +00:00
parent 2059c26359
commit 61c5a99851
6 changed files with 50 additions and 18 deletions

View File

@ -8,10 +8,7 @@
#ifdef USE_WIN32DLL
#include "loader.h"
//#include "wine/mmreg.h"
#include "wine/vfw.h"
#include "wine/avifmt.h"
#include "wineacm.h"
#include "ad_internal.h"
@ -144,10 +141,10 @@ static void uninit(sh_audio_t *sh)
return(uninit(sh));
case ACMERR_UNPREPARED:
case ACMERR_NOTPOSSIBLE:
return(0);
return;
default:
mp_msg(MSGT_WIN32, MSGL_WARN, "ACM_Decoder: unknown error occured: %d\n", ret);
return(0);
return;
}
MSACM_UnregisterAllDrivers();

View File

@ -1,4 +1,5 @@
#include "mp_image.h"
#include "mpc_info.h"
typedef mp_codec_info_t vd_info_t;

View File

@ -7,13 +7,11 @@
#ifdef USE_WIN32DLL
#include "loader.h"
//#include "wine/mmreg.h"
#include "wine/vfw.h"
#include "wine/avifmt.h"
#include "vd_internal.h"
#include "wine/driver.h"
#include "wine/vfw.h"
static vd_info_t info = {
#ifdef BUILD_VFWEX
"Win32/VfWex video codecs",
@ -143,7 +141,6 @@ static int control(sh_video_t *sh,int cmd,void* arg,...){
// init driver
static int init(sh_video_t *sh){
HRESULT ret;
int yuv=0;
// unsigned int outfmt=sh->codec->outfmt[sh->outfmtidx];
int i, o_bih_len;
vd_vfw_ctx *priv;
@ -160,7 +157,7 @@ static int init(sh_video_t *sh){
// win32_codec_name = sh->codec->dll;
// sh->hic = ICOpen( 0x63646976, sh->bih->biCompression, ICMODE_FASTDECOMPRESS);
// priv->handle = ICOpen( 0x63646976, sh->bih->biCompression, ICMODE_DECOMPRESS);
priv->handle = ICOpen( sh->codec->dll, sh->bih->biCompression, ICMODE_DECOMPRESS);
priv->handle = ICOpen( (long)(sh->codec->dll), sh->bih->biCompression, ICMODE_DECOMPRESS);
if(!priv->handle){
mp_msg(MSGT_WIN32,MSGL_ERR,"ICOpen failed! unknown codec / wrong parameters?\n");
return 0;

View File

@ -5,6 +5,7 @@
#include "config.h"
// for avi_stream_id():
#include "stream.h"
#include "demuxer.h"

View File

@ -1,13 +1,45 @@
#ifndef __ST_HEADER_H
#define __ST_HEADER_H 1
// Stream headers:
#include "wine/mmreg.h"
// for AVIStreamHeader:
#include "wine/avifmt.h"
#include "wine/vfw.h"
#include "../libmpcodecs/mp_image.h"
#ifndef _WAVEFORMATEX_
#define _WAVEFORMATEX_
typedef struct __attribute__((__packed__)) _WAVEFORMATEX {
WORD wFormatTag;
WORD nChannels;
DWORD nSamplesPerSec;
DWORD nAvgBytesPerSec;
WORD nBlockAlign;
WORD wBitsPerSample;
WORD cbSize;
} WAVEFORMATEX, *PWAVEFORMATEX, *NPWAVEFORMATEX, *LPWAVEFORMATEX;
#endif /* _WAVEFORMATEX_ */
#ifndef _BITMAPINFOHEADER_
#define _BITMAPINFOHEADER_
typedef struct __attribute__((__packed__))
{
int biSize;
int biWidth;
int biHeight;
short biPlanes;
short biBitCount;
int biCompression;
int biSizeImage;
int biXPelsPerMeter;
int biYPelsPerMeter;
int biClrUsed;
int biClrImportant;
} BITMAPINFOHEADER, *PBITMAPINFOHEADER, *LPBITMAPINFOHEADER;
typedef struct {
BITMAPINFOHEADER bmiHeader;
int bmiColors[1];
} BITMAPINFO, *LPBITMAPINFO;
#endif
// Stream headers:
typedef struct {
demux_stream_t *ds;

View File

@ -43,12 +43,16 @@ static char* banner_text=
#include "libvo/video_out.h"
#include "libmpcodecs/mp_image.h"
#include "libmpcodecs/dec_audio.h"
#include "libmpcodecs/dec_video.h"
#include "libmpcodecs/vf.h"
#include "libmpdemux/mp3_hdr.h"
// for MPEGLAYER3WAVEFORMAT:
#include "loader/wine/mmreg.h"
#ifdef HAVE_MP3LAME
#undef CDECL
#include <lame/lame.h>