From: "jianfeng.zheng" <ggjogh@gmail.com> To: ffmpeg-devel@ffmpeg.org Cc: "jianfeng.zheng" <jianfeng.zheng@mthreads.com> Subject: [FFmpeg-devel] [vaapi-cavs 3/7] cavs: time code debug Date: Sun, 21 Jan 2024 22:18:42 +0800 Message-ID: <20240121141846.4077778-3-jianfeng.zheng@mthreads.com> (raw) In-Reply-To: <20240121141846.4077778-1-jianfeng.zheng@mthreads.com> Signed-off-by: jianfeng.zheng <jianfeng.zheng@mthreads.com> --- libavcodec/cavsdec.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/libavcodec/cavsdec.c b/libavcodec/cavsdec.c index 9742bd1011..9ad0f29b01 100644 --- a/libavcodec/cavsdec.c +++ b/libavcodec/cavsdec.c @@ -1061,6 +1061,7 @@ static int decode_pic(AVSContext *h) int ret; int skip_count = -1; enum cavs_mb mb_type; + char tc[4]; if (!h->top_qp) { av_log(h->avctx, AV_LOG_ERROR, "No sequence header decoded yet\n"); @@ -1082,8 +1083,16 @@ static int decode_pic(AVSContext *h) return AVERROR_INVALIDDATA; } else { h->cur.f->pict_type = AV_PICTURE_TYPE_I; - if (get_bits1(&h->gb)) - skip_bits(&h->gb, 24);//time_code + if (get_bits1(&h->gb)) { //time_code + skip_bits(&h->gb, 1); + tc[0] = get_bits(&h->gb, 5); + tc[1] = get_bits(&h->gb, 6); + tc[2] = get_bits(&h->gb, 6); + tc[3] = get_bits(&h->gb, 6); + av_log(h->avctx, AV_LOG_DEBUG, "timecode: %d:%d:%d.%d\n", + tc[0], tc[1], tc[2], tc[3]); + } + /* old sample clips were all progressive and no low_delay, bump stream revision if detected otherwise */ if (h->low_delay || !(show_bits(&h->gb, 9) & 1)) -- 2.25.1 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
next prev parent reply other threads:[~2024-01-21 14:19 UTC|newest] Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top 2024-01-21 14:18 [FFmpeg-devel] [vaapi-cavs 1/7] cavs: add cavs profile defs jianfeng.zheng 2024-01-21 14:18 ` [FFmpeg-devel] [vaapi-cavs 2/7] cavs: skip bits between pic header and slc header jianfeng.zheng 2024-01-21 14:18 ` jianfeng.zheng [this message] 2024-01-21 14:18 ` [FFmpeg-devel] [vaapi-cavs 4/7] cavs: fix dpb reorder issues when 'low_delay' is varied jianfeng.zheng 2024-01-21 14:18 ` [FFmpeg-devel] [vaapi-cavs 5/7] cavs: decode wqm and slice weighting for future usage jianfeng.zheng 2024-01-21 14:18 ` [FFmpeg-devel] [vaapi-cavs 6/7] cavs: set profile & level for AVCodecContext jianfeng.zheng 2024-01-21 14:18 ` [FFmpeg-devel] [vaapi-cavs 7/7] cavs: support vaapi hwaccel decoding jianfeng.zheng 2024-01-22 21:24 ` Mark Thompson
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20240121141846.4077778-3-jianfeng.zheng@mthreads.com \ --to=ggjogh@gmail.com \ --cc=ffmpeg-devel@ffmpeg.org \ --cc=jianfeng.zheng@mthreads.com \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel This inbox may be cloned and mirrored by anyone: git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \ ffmpegdev@gitmailbox.com public-inbox-index ffmpegdev Example config snippet for mirrors. AGPL code for this site: git clone https://public-inbox.org/public-inbox.git