Hi Loren, Thank you for your reply. Are you saying that when pic->reference ==3 means a valid reference frame and need to be output pic->reference ==1 means a frame pending to be output and no longer be referred to pic->reference ==0 means a freme has been outputed and will no longer be refered to? Best regards Chengji