[XviD-devel] xvid_decore return values

Pedro Miguel Felizardo Antunes pmfa at student.dei.uc.pt
Sat Oct 1 02:44:51 CEST 2005


On Fri, 30 Sep 2005, Bryan Mayland wrote:

> Pedro Miguel Felizardo Antunes wrote:
>
>> After some coding done, I noticed that the xvid_decore function returned 
>> the value -4 when using the XVID_DEC_DECODE opt.
>> Does anyone know where I can find a list of return values for the function, 
>> or perhaps anyone can tell me what the -4 stands for?
>
>   The return codes are in xvid.h.  -4 is XVID_ERR_VERSION, in that either 
> the xvid_dec_frame_t.version (param1) or the xvid_dec_stats_t.version 
> (param2) isn't right.  I believe both should be 1.

Hi again

After trying to solve the problem as sugested, I noticed that the -4
return comes even from an earlyer stage, when I use the xvid_global
function with the xvid_glb_init struct.

I try putting the version as 1, but it always returns -4 even if I leave
it untouched.

Here's the code i'm using:



<CODE>

 	memset(&xvid_gbl_init, 0, sizeof(xvid_gbl_init_t));
 	memset(&xvid_dec_create, 0, sizeof(xvid_dec_create_t));


/*------------------------------------------------------------------------
 	 * XviD core initialization
*----------------------------------------------------------------------*/
 	/* Version */
 	//xvid_gbl_init.version = XVID_VERSION;
 	xvid_gbl_init.version = 1;

 	//CPU_FLAGS
 	//xvid_gbl_init.cpu_flags = 0;

 	//DEBUG_LEVEL
 	//xvid_gbl_init.debug = debug_level;

 	// !!!BUG!!!
 	ret = xvid_global(NULL, 0, &xvid_gbl_init, NULL);
 	printf("XVID_INIT RETURN: %i\n",ret);

</CODE>


More information about the XviD-devel mailing list