Mercurial > mplayer.hg
changeset 9897:74c60b95660d
Fixes for vss h264
author | rtognimp |
---|---|
date | Wed, 09 Apr 2003 21:34:05 +0000 |
parents | acf96aea152c |
children | 51b2ab729370 |
files | etc/codecs.conf loader/win32.c |
diffstat | 2 files changed, 37 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/etc/codecs.conf Wed Apr 09 21:28:01 2003 +0000 +++ b/etc/codecs.conf Wed Apr 09 21:34:05 2003 +0000 @@ -1154,7 +1154,7 @@ videocodec vssh264 info "VSS H.264" - status buggy + status working fourcc VSSH driver vfw dll "vssh264.dll"
--- a/loader/win32.c Wed Apr 09 21:28:01 2003 +0000 +++ b/loader/win32.c Wed Apr 09 21:34:05 2003 +0000 @@ -5102,8 +5102,8 @@ } #ifndef LOADLIB_TRY_NATIVE - /* hack for truespeech */ - if (!strcmp(library, "tsd32.dll")) + /* hack for truespeech and vssh264*/ + if (!strcmp(library, "tsd32.dll") || !strcmp(library,"vssh264dec.dll")) #endif /* ok, this is a hack, and a big memory leak. should be fixed. - alex */ { @@ -5167,6 +5167,40 @@ return libraries[i].exps[j].func; } } + +#ifndef LOADLIB_TRY_NATIVE + /* hack for vss h264 */ + if (!strcmp(library,"vssh264core.dll")) +#endif + /* ok, this is a hack, and a big memory leak. should be fixed. - alex */ + { + int hand; + WINE_MODREF *wm; + void *func; + + hand = LoadLibraryA(library); + if (!hand) + goto no_dll_byname; + wm = MODULE32_LookupHMODULE(hand); + if (!wm) + { + FreeLibrary(hand); + goto no_dll_byname; + } + func = PE_FindExportedFunction(wm, name, 0); + if (!func) + { + printf("No such name in external dll\n"); + FreeLibrary((int)hand); + goto no_dll_byname; + } + + printf("External dll loaded (offset: 0x%x, func: %p)\n", + hand, func); + return func; + } + +no_dll_byname: if(pos>150)return 0;// to many symbols strcpy(export_names[pos], name); return add_stub();