fix only first movie working

This commit is contained in:
Glenn Maynard
2003-12-06 01:33:10 +00:00
parent 7355fe9661
commit b4569b3b18
@@ -491,20 +491,20 @@ static avcodec::URLProtocol RageProtocol =
NULL
};
static void InitProtocol()
static void RegisterProtocols()
{
static bool Done = false;
if( Done )
return;
Done = true;
avcodec::av_register_all();
avcodec::register_protocol( &RageProtocol );
}
void MovieTexture_FFMpeg::CreateDecoder()
{
avcodec::av_register_all();
InitProtocol();
RegisterProtocols();
int ret = avcodec::av_open_input_file( &decoder->m_fctx, "rage://" + GetID().filename, NULL, 0, NULL );
if( ret < 0 )