diff options
author | arpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2002-12-14 17:56:35 +0000 |
---|---|---|
committer | arpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2002-12-14 17:56:35 +0000 |
commit | b987127e0e7eb90d8a0a618035a377e92f098447 (patch) | |
tree | 93886db1483e2ad6c3901f6646638e6da6079afa /libmpcodecs | |
parent | bbeb54d80aa6d1d6945ce3b6461b7d24c57841e9 (diff) | |
download | mpv-b987127e0e7eb90d8a0a618035a377e92f098447.tar.bz2 mpv-b987127e0e7eb90d8a0a618035a377e92f098447.tar.xz |
compiler warning fixes
based on patch by Dominik Mierzejewski <dominik@rangers.eu.org>
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@8452 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpcodecs')
-rw-r--r-- | libmpcodecs/ad_qtaudio.c | 4 | ||||
-rw-r--r-- | libmpcodecs/vd_lcl.c | 6 | ||||
-rw-r--r-- | libmpcodecs/vd_qtvideo.c | 34 |
3 files changed, 27 insertions, 17 deletions
diff --git a/libmpcodecs/ad_qtaudio.c b/libmpcodecs/ad_qtaudio.c index 8ba47c2bb2..a5547e1df8 100644 --- a/libmpcodecs/ad_qtaudio.c +++ b/libmpcodecs/ad_qtaudio.c @@ -10,6 +10,10 @@ #include "ad_internal.h" #include "bswap.h" +#ifdef USE_WIN32DLL +#include "ldt_keeper.h" +#endif + static ad_info_t info = { "QuickTime Audio Decoder", "qtaudio", diff --git a/libmpcodecs/vd_lcl.c b/libmpcodecs/vd_lcl.c index dc6d2f04a0..ded7642db7 100644 --- a/libmpcodecs/vd_lcl.c +++ b/libmpcodecs/vd_lcl.c @@ -491,7 +491,8 @@ static mp_image_t* decode(sh_video_t *sh,void* data,int len,int flags) for (row = 0; row < height; row++) { pixel_ptr = row * width * 3; yq = encoded[pixel_ptr++]; - uqvq = encoded[pixel_ptr++] + (encoded[pixel_ptr++] << 8); + uqvq = encoded[pixel_ptr++]; + uqvq+=(encoded[pixel_ptr++] << 8); for (col = 1; col < width; col++) { encoded[pixel_ptr] = yq -= encoded[pixel_ptr]; uqvq -= (encoded[pixel_ptr+1] | (encoded[pixel_ptr+2]<<8)); @@ -505,7 +506,8 @@ static mp_image_t* decode(sh_video_t *sh,void* data,int len,int flags) for (row = 0; row < height; row++) { pixel_ptr = row * width * 3; yq = encoded[pixel_ptr++]; - uqvq = encoded[pixel_ptr++] + (encoded[pixel_ptr++] << 8); + uqvq = encoded[pixel_ptr++]; + uqvq+=(encoded[pixel_ptr++] << 8); for (col = 1; col < width; col++) { encoded[pixel_ptr] = yq -= encoded[pixel_ptr]; uqvq -= (encoded[pixel_ptr+1] | (encoded[pixel_ptr+2]<<8)); diff --git a/libmpcodecs/vd_qtvideo.c b/libmpcodecs/vd_qtvideo.c index 9873fbb530..6bb39952fc 100644 --- a/libmpcodecs/vd_qtvideo.c +++ b/libmpcodecs/vd_qtvideo.c @@ -8,6 +8,10 @@ #include "mp_msg.h" #include "vd_internal.h" +#ifdef USE_WIN32DLL +#include "ldt_keeper.h" +#endif + static vd_info_t info = { "Quicktime Video decoder", "qtvideo", @@ -100,20 +104,20 @@ static int init(sh_video_t *sh){ handler = LoadLibraryA("qtmlClient.dll"); - InitializeQTML = GetProcAddress(handler, "InitializeQTML"); - EnterMovies = GetProcAddress(handler, "EnterMovies"); - FindNextComponent = GetProcAddress(handler, "FindNextComponent"); - CountComponents = GetProcAddress(handler, "CountComponents"); - GetComponentInfo = GetProcAddress(handler, "GetComponentInfo"); - OpenComponent = GetProcAddress(handler, "OpenComponent"); - ImageCodecInitialize = GetProcAddress(handler, "ImageCodecInitialize"); - ImageCodecGetCodecInfo = GetProcAddress(handler, "ImageCodecGetCodecInfo"); - ImageCodecBeginBand = GetProcAddress(handler, "ImageCodecBeginBand"); - ImageCodecPreDecompress = GetProcAddress(handler, "ImageCodecPreDecompress"); - ImageCodecBandDecompress = GetProcAddress(handler, "ImageCodecBandDecompress"); - GetGWorldPixMap = GetProcAddress(handler, "GetGWorldPixMap"); - QTNewGWorldFromPtr = GetProcAddress(handler, "QTNewGWorldFromPtr"); - NewHandleClear = GetProcAddress(handler, "NewHandleClear"); + InitializeQTML = (OSErr (*)(long))GetProcAddress(handler, "InitializeQTML"); + EnterMovies = (OSErr (*)(void))GetProcAddress(handler, "EnterMovies"); + FindNextComponent = (Component (*)(Component,ComponentDescription*))GetProcAddress(handler, "FindNextComponent"); + CountComponents = (long (*)(ComponentDescription*))GetProcAddress(handler, "CountComponents"); + GetComponentInfo = (OSErr (*)(Component,ComponentDescription*,Handle,Handle,Handle))GetProcAddress(handler, "GetComponentInfo"); + OpenComponent = (ComponentInstance (*)(Component))GetProcAddress(handler, "OpenComponent"); + ImageCodecInitialize = (ComponentResult (*)(ComponentInstance,ImageSubCodecDecompressCapabilities *))GetProcAddress(handler, "ImageCodecInitialize"); + ImageCodecGetCodecInfo = (ComponentResult (*)(ComponentInstance,CodecInfo *))GetProcAddress(handler, "ImageCodecGetCodecInfo"); + ImageCodecBeginBand = (ComponentResult (*)(ComponentInstance,CodecDecompressParams *,ImageSubCodecDecompressRecord *,long))GetProcAddress(handler, "ImageCodecBeginBand"); + ImageCodecPreDecompress = (ComponentResult (*)(ComponentInstance,CodecDecompressParams *))GetProcAddress(handler, "ImageCodecPreDecompress"); + ImageCodecBandDecompress = (ComponentResult (*)(ComponentInstance,CodecDecompressParams *))GetProcAddress(handler, "ImageCodecBandDecompress"); + GetGWorldPixMap = (PixMapHandle (*)(GWorldPtr))GetProcAddress(handler, "GetGWorldPixMap"); + QTNewGWorldFromPtr = (OSErr(*)(GWorldPtr *,OSType,const Rect *,CTabHandle,void*,GWorldFlags,void *,long))GetProcAddress(handler, "QTNewGWorldFromPtr"); + NewHandleClear = (OSErr(*)(Size))GetProcAddress(handler, "NewHandleClear"); // = GetProcAddress(handler, ""); if(!InitializeQTML || !EnterMovies || !FindNextComponent || !ImageCodecBandDecompress){ @@ -371,7 +375,7 @@ if(!codec_inited){ if((int)sh->context==0x73797639){ // Sorenson 16-bit YUV -> std YVU9 - short *src0=((char*)decpar.dstPixMap.baseAddr+0x20); + short *src0=(short *)((char*)decpar.dstPixMap.baseAddr+0x20); for(i=0;i<mpi->h;i++){ int x; |