Changeset 4fac9bb2655ad8894ad15b8bc896f88b08fbba0a
- Timestamp:
- 14/06/08 23:12:28 (4 months ago)
- git-parent:
- Files:
-
- modules/codec/realvideo.c (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
modules/codec/realvideo.c
rb2507fd r4fac9bb 108 108 109 109 int dll_type = 1; 110 #ifdef WIN32111 const char *g_decode_path="plugins\\drv43260.dll";112 #else113 const char *g_decode_path="../lib/vlc/codec/drv4.so.6.0";114 #endif115 110 116 111 static unsigned long (*rvyuv_custom_message)(cmsg_data_t* ,void*); … … 124 119 static unsigned long WINAPI (*wrvyuv_transform)(char*, char*,transform_in_t*,unsigned int*,void*); 125 120 #endif 121 126 122 /***************************************************************************** 127 123 * Module descriptor … … 214 210 char fcc[4]; 215 211 vlc_mutex_t *lock; 212 char *g_decode_path; 213 216 214 int i_vide = p_dec->fmt_in.i_extra; 217 215 unsigned int *p_vide = p_dec->fmt_in.p_extra; … … 246 244 init_data.unk5 = 1; 247 245 init_data.format = (unsigned int*)p_vide[1]; 248 246 249 247 /* first try to load linux dlls, if failed and we're supporting win32 dlls, 250 248 then try to load the windows ones */ 249 bool b_so_opened = false; 250 251 251 #ifdef WIN32 252 if ( NULL== (p_sys->rv_handle = load_syms(p_dec, g_decode_path)) ) 252 g_decode_path="plugins\\drv43260.dll"; 253 254 if( (p_sys->rv_handle = load_syms(p_dec, g_decode_path)) ) 255 b_so_opened = true; 253 256 #else 254 if ( NULL== (p_sys->rv_handle = load_syms_linux(p_dec, g_decode_path)) ) 255 #endif 256 { 257 msg_Err( p_dec, "Cannot load real decoder library: %s", g_decode_path); 257 const char *ppsz_path[] = 258 { 259 "/usr/lib/win32", 260 "/usr/lib/codecs", 261 "/usr/local/RealPlayer8/Codecs", 262 "/usr/RealPlayer8/Codecs", 263 "/usr/lib/RealPlayer8/Codecs", 264 "/opt/RealPlayer8/Codecs", 265 "/usr/lib/RealPlayer9/users/Real/Codecs", 266 "/usr/lib/RealPlayer10/codecs", 267 "/usr/lib/RealPlayer10GOLD/codecs", 268 "/usr/lib/helix/player/codecs", 269 "/usr/lib64/RealPlayer8/Codecs", 270 "/usr/lib64/RealPlayer9/users/Real/Codecs", 271 "/usr/lib64/RealPlayer10/codecs", 272 "/usr/lib64/RealPlayer10GOLD/codecs", 273 "/usr/local/lib/codecs", 274 NULL 275 }; 276 277 for( int i = 0; ppsz_path[i]; i++ ) 278 { 279 asprintf( &g_decode_path, "%s/drv4.so.6.0", ppsz_path[i] ); 280 if( (p_sys->rv_handle = load_syms_linux(p_dec, g_decode_path)) ) 281 { 282 b_so_opened = true; 283 free( g_decode_path ); 284 break; 285 } 286 287 asprintf( &g_decode_path, "%s/drv3.so.6.0", ppsz_path[i] ); 288 if( (p_sys->rv_handle = load_syms_linux(p_dec, g_decode_path)) ) 289 { 290 b_so_opened = true; 291 free( g_decode_path ); 292 break; 293 } 294 295 msg_Dbg( p_dec, "Cannot load real decoder library: %s", g_decode_path); 296 free( g_decode_path ); 297 } 298 #endif 299 300 if(!b_so_opened ) 301 { 302 msg_Err( p_dec, "Cannot any real decoder library" ); 258 303 free( p_sys ); 259 304 return VLC_EGENERIC;
