Commit a6bc5de8 authored by Christophe Massiot's avatar Christophe Massiot

Suite des images I.

parent f0f225c4
......@@ -293,10 +293,10 @@
/* Number of macroblock buffers available. It should be always greater than
* twice the number of macroblocks in a picture. VFIFO_SIZE + 1 should also
* be a power of two. */
#define VFIFO_SIZE 4095
#define VFIFO_SIZE 8191
/* Maximum number of macroblocks in a picture. */
#define MAX_MB 32767
#define MAX_MB 2048
/*******************************************************************************
* Video decoder configuration
......
......@@ -186,7 +186,7 @@ static void RunThread( vdec_thread_t *p_vdec )
return;
}
p_vdec->b_run = 1;
p_vdec->b_error = 1;
/*
* Main loop - it is not executed if an error occured during
* initialization
......@@ -230,9 +230,6 @@ static void ErrorThread( vdec_thread_t *p_vdec )
{
p_mb = vpar_GetMacroblock( &p_vdec->p_vpar->vfifo );
vpar_DestroyMacroblock( &p_vdec->p_vpar->vfifo, p_mb );
/* Sleep a while */
msleep( VDEC_IDLE_SLEEP );
}
}
......
......@@ -668,11 +668,17 @@ static void PictureHeader( vpar_thread_t * p_vpar )
if( !p_vpar->picture.i_current_structure )
{
/* This is a new frame. Get a structure from the video_output. */
P_picture = vout_CreatePicture( p_vpar->p_vout,
if( ( P_picture = vout_CreatePicture( p_vpar->p_vout,
99+p_vpar->sequence.i_chroma_format, /*???*/
p_vpar->sequence.i_width,
p_vpar->sequence.i_height,
p_vpar->sequence.i_width*sizeof(yuv_data_t) );
p_vpar->sequence.i_width*sizeof(yuv_data_t) ) )
== NULL )
{
intf_ErrMsg("vpar debug: allocation error in vout_CreatePicture\n");
p_vpar->b_error = 1;
return;
}
/* Initialize values. */
P_picture->date = vpar_SynchroDecode( p_vpar,
......@@ -757,14 +763,18 @@ fprintf(stderr, "Image parsee\n");
/* Link referenced pictures for the decoder
* They are unlinked in vpar_ReleaseMacroblock() & vpar_DestroyMacroblock() */
#if 0
if( p_vpar->sequence.p_forward != NULL )
{
vout_LinkPicture( p_vpar->p_vout, p_vpar->sequence.p_forward );
vout_LinkPicture( p_vpar->p_vout, p_vpar->sequence.p_forward );
}
if( p_vpar->sequence.p_backward != NULL )
{
vout_LinkPicture( p_vpar->p_vout, p_vpar->sequence.p_backward );
}
#endif
/* Send signal to the video_decoder. */
vlc_cond_signal( &p_vpar->vfifo.wait );
/* Prepare context for the next picture. */
P_picture = NULL;
......
......@@ -67,7 +67,7 @@ void vpar_SynchroTrash( vpar_thread_t * p_vpar, int i_coding_type,
mtime_t vpar_SynchroDecode( vpar_thread_t * p_vpar, int i_coding_type,
int i_structure )
{
return mdate() + 500000;
}
/*****************************************************************************
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment