GNOME Bugzilla – Bug 771507
[gst-vaapi-master][vp9][encoder] reference Mode 1 produces blocky pixels content
Last modified: 2016-09-30 07:05:30 UTC
This pipeline produces blocky pixels content. Analyzing the output it is losing the proper reference frame at the 8th frame. gst-launch-1.0 -e filesrc location=./someyuv_1920x1080.I420 blocksize=3110400 ! video/x-raw, format=I420, width=1920, height=1080, framerate=30/1, pixel-aspect-ratio=1/1 ! y4menc ! y4mdec ! vaapivp9enc rate-control=cqp keyframe-period=300 ref-pic-mode=1 ! webmmux ! filesink location=./gstvp9enc_2Mbps_mode1ref.webm
Thanks for reporting it.. Can't see visible artifacts in stream generated from videotestsrc. Will have to test with some real streams :) Might be messed-up something with the circular insertion algoritham used for ref-pic mode 1 ...We will investigate it...unfortunately not sure about the inclusion of fix in 1.10 release..
Created attachment 335695 [details] [review] encoder: vp9: Fix refresh frame flag setting While doing the mode-1 referece picture selection, the circular buffer logic was not correctly setting the refresh frame flags as per VP9 spec. Make sure refresh_flag[0] get updated correclty after each cycle of GST_VP9_REF_FRAMES. Daniel, Could you please have a try with the attached patch?
Patch does fix the error. Tested-by:"Daniel Charles <daniel.charles@intel.com>"
FWIW, videotestsrc shows also the problem when analyzing the resultant file. It does not show a visual problem as only 4 frames are wrong and videotestsrc patterns don't help in this situation My pipeline gst-launch-1.0 -e videotestsrc num-buffers=1700 pattern=11 ! video/x-raw, format=I420, width=1920, height=1080, framerate=30/1, pixel-aspect-ratio=1/1 ! vaapivp9enc rate-control=cqp keyframe-period=300 ref-pic-mode=1 ! webmmux ! filesink location=./gstvp9enc_mode1ref.webm
I think it is good to have this fix in 1.10, late alredy? :)
(In reply to sreerenj from comment #5) > I think it is good to have this fix in 1.10, late alredy? :) Nope. Go ahead!
Review of attachment 335695 [details] [review]: pushed, closing
commit 44a90c196ddce97519d99311983ac04631e43d58 Author: Sreerenj Balachandran <sreerenj.balachandran@intel.com> Date: Wed Sep 21 09:52:21 2016 +0300 encoder: vp9: Fix refresh frame flag setting While doing the mode-1 referece picture selection, the circular buffer logic was not correctly setting the refresh frame flags as per VP9 spec. Make sure refresh_flag[0] get updated correclty after each cycle of GST_VP9_REF_FRAMES. https://bugzilla.gnome.org/show_bug.cgi?id=771507