[XviD-devel] XviD-devel I-FRAMES

suxen_drol suxen_drol at hotmail.com
Fri Jun 27 18:36:12 CEST 2003


hi,

On Fri, 27 Jun 2003 14:18:06 +0900 "bwahn" <bwahn at digitalpulse.co.kr>
wrote:
> i'm looking inside code but i can't understand how XVID choose IFRME.
> i doesn't understand how it choose how to code a i-frame ..
> 
> decoder_decode() {
> .
> image_output(&dec->cur, dec->width, dec->height, dec->edged_width,
> 	 frame->image, frame->stride, frame->colorspace);
> 
>     // "frame->image" is I-frame picture?

image_output is used to translate between xvid internal yuv 4:2:0
colorspace to the decoding colorspace (which could be any of the packed
or planar yuv, or rgb, formats). 
this function has nothing to do with frame type decision.

> 
> Can you help me ?

sure, though your question really isnt clear. i'll try to answer both
interpretations of it:

* how xvid decides on i/p/b-frames whilst encoding or decoding?
	the encoder has an MEAnalayis function which determines frame
	type. thedecode reads the vop_type token from the bitstream,
	which indicates the frame type.

* how can an application using libxvidcore determine the frame type
whilst encoding or decoding?
	this depends largely on the xvid api you're using. the tradition
api has a encoder "frame.intra" field which indicates if the frame is an
intra-frame. whilst the new api (in the dev-api-4 tree) has "stats.type"
field.

cheers,
-- pete




More information about the XviD-devel mailing list