[FFmpeg-devel] A question about execute_ref_pic_marking....

Hadi Hadizadeh hadi.hadizadeh
Sun Feb 8 20:32:17 CET 2009

Hi,I want to add a whole frame error concealment algorithm too ffmpeg.I found that whenever a NAL unit corresponding to a frame is lost, the frame number of the lost frame can be detected in function H.264.c\decode_slice_header using the following code:while(h->frame_num != h->prev_frame_num &&h->frame_num != (h->prev_frame_num+1)%(1<<h->sps.log2_max_frame_num)){av_log(NULL, AV_LOG_DEBUG, "Frame num gap %d %d\n", h->frame_num, h->prev_frame_num);frame_start(h);h->prev_frame_num++;h->prev_frame_num %= 1<<h->sps.log2_max_frame_num;//=======h->prev_frame_num shows the frame number of lost frame============s->current_picture_ptr->frame_num= h->prev_frame_num;execute_ref_pic_marking(h, NULL, 0);}After detecting the lost frame, function execute_ref_pic_marking is called.But do you know the exact role of this function? I think it is used to find/remove the reference frame of each frame? Right?Thanks!
How fun is this? IMing with Windows Live Messenger just got better.

More information about the ffmpeg-devel mailing list