From patchwork Sun Apr 9 13:27:40 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anton Khirnov X-Patchwork-Id: 41037 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:4645:b0:e3:3194:9d20 with SMTP id eb5csp1571867pzb; Sun, 9 Apr 2023 06:29:04 -0700 (PDT) X-Google-Smtp-Source: AKy350bFMgzEWEikCStoO5n3ZXrgW+Uuq/9Brv+2rVrbM+ocYqUNU6OK1+lVL2YRXr1rZ0qyo3Zr X-Received: by 2002:a17:907:728a:b0:947:6ce9:705d with SMTP id dt10-20020a170907728a00b009476ce9705dmr5074910ejc.55.1681046944645; Sun, 09 Apr 2023 06:29:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681046944; cv=none; d=google.com; s=arc-20160816; b=CgSaTo22+9xSDDwsirLC5fbxQXFHZh4pKTEjvEezrDccvrGAkVtKF/GjK38Fjq7qix p/Pa/YtBdPU8Ryn2JZUlmgkFUDDT2XH61MlvGQFAWrPMCwqQmBG0oAdrn3UJfSWSwQIw jVOsXZdzmfN7EWcvkP9arS9dfhZ+Y06qN2wu9EmgKGeWXpeLQETSdd+58kcnp3fMqTMp kDBQM5a4ffC4ISj7h5nxYRBTILqrfbrfwteeBNO6s9ydwGOTGJ4CXh+M3cm6QMplXOrH WP0W9CKNUi7B/bBbv/h68uaj35J6hEn0nHBpFEDFrDTwwfzmFk5gTM8VVC/uP0k8DeOh whwA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:reply-to:list-subscribe :list-help:list-post:list-archive:list-unsubscribe:list-id :precedence:subject:mime-version:message-id:date:to:from :delivered-to; bh=lAhiC2lcANrnz7O1v0+9maAAyJ+Si+KU9n4aTwXbk1w=; b=WzHu3SKTRk3VByOFD2eY6h33oALYKNib/8V0ZiGG/ylC8MGMnefkK0IPsr3ksLmTqr SN4YQ/y05GVurambk8o3w8mmpY4iBlxGMC7dpd3mRKOMlhcAHBMn2Ti/xH5EPt1lq1Bv LnrvdyyDsfCshaUwOQfyg2OfOlzRYAdn3ae/f3NDSJjCzwykwOEdfpmFboSPefqfZoE6 /1Zw9ry64nYOJsARL86k6X1wkXNu43ML3EfQLWI4RL6Qgn3CJBpDNw4L/+PpRR2Z2cQe DWjf5SMnEjbxiDmYSnrxwlWF/VWyocacrz1dzH/8Bt/oemqc1b+A5I8vDBoaBlRFEZh5 ia4A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id ib23-20020a1709072c7700b00946c1d28b59si4212727ejc.355.2023.04.09.06.29.04; Sun, 09 Apr 2023 06:29:04 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id F188A689F18; Sun, 9 Apr 2023 16:28:51 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mail0.khirnov.net (red.khirnov.net [176.97.15.12]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 9FAA8689EBF for ; Sun, 9 Apr 2023 16:28:44 +0300 (EEST) Received: from localhost (localhost [IPv6:::1]) by mail0.khirnov.net (Postfix) with ESMTP id 34B682404EE for ; Sun, 9 Apr 2023 15:28:44 +0200 (CEST) Received: from mail0.khirnov.net ([IPv6:::1]) by localhost (mail0.khirnov.net [IPv6:::1]) (amavisd-new, port 10024) with ESMTP id DtxKboMKssDP for ; Sun, 9 Apr 2023 15:28:43 +0200 (CEST) Received: from libav.khirnov.net (libav.khirnov.net [IPv6:2a00:c500:561:201::7]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "libav.khirnov.net", Issuer "smtp.khirnov.net SMTP CA" (verified OK)) by mail0.khirnov.net (Postfix) with ESMTPS id 6F4902404EC for ; Sun, 9 Apr 2023 15:28:43 +0200 (CEST) Received: from libav.khirnov.net (libav.khirnov.net [IPv6:::1]) by libav.khirnov.net (Postfix) with ESMTP id F24CB3A038E for ; Sun, 9 Apr 2023 15:28:36 +0200 (CEST) From: Anton Khirnov To: ffmpeg-devel@ffmpeg.org Date: Sun, 9 Apr 2023 15:27:40 +0200 Message-Id: <20230409132746.19756-1-anton@khirnov.net> X-Mailer: git-send-email 2.39.1 MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH 1/7] lavf/rawdec: set avg_frame_rate X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: iSQi9KRQoIsm Timestamps in two FATE H.264 conformance tests now start at 1 instead of 0, which also happens in some other H.264 tests before this commit and so is not a big issue. Conversely, timestamps in some HEVC conformance tests start from a smaller value now. Ideally this should be addressed later in a more general way. h264-conformance-frext-frext2_panasonic_b no longer requires -vsync passthrough. --- libavformat/rawdec.c | 1 + tests/fate/h264.mak | 2 +- .../h264-conformance-frext-frext2_panasonic_b | 30 +++++++++---------- .../h264-conformance-frext-frext4_panasonic_a | 20 ++++++------- .../fate/hevc-conformance-CIP_A_Panasonic_3 | 4 +-- .../fate/hevc-conformance-CIP_C_Panasonic_2 | 4 +-- .../ref/fate/hevc-conformance-SDH_A_Orange_3 | 4 +-- tests/ref/fate/hevc-small422chroma | 2 +- 8 files changed, 34 insertions(+), 33 deletions(-) diff --git a/libavformat/rawdec.c b/libavformat/rawdec.c index de804366ed1..9126a9e53b0 100644 --- a/libavformat/rawdec.c +++ b/libavformat/rawdec.c @@ -86,6 +86,7 @@ int ff_raw_video_read_header(AVFormatContext *s) st->codecpar->codec_id = s->iformat->raw_codec_id; sti->need_parsing = AVSTREAM_PARSE_FULL_RAW; + st->avg_frame_rate = s1->framerate; sti->avctx->framerate = s1->framerate; avpriv_set_pts_info(st, 64, 1, 1200000); diff --git a/tests/fate/h264.mak b/tests/fate/h264.mak index b883f3a3ffa..c8ed23955ac 100644 --- a/tests/fate/h264.mak +++ b/tests/fate/h264.mak @@ -346,7 +346,7 @@ fate-h264-conformance-frext-freh7_b: CMD = framecrc -i $(TARGET_SAM fate-h264-conformance-frext-frext01_jvc_d: CMD = framecrc -i $(TARGET_SAMPLES)/h264-conformance/FRext/FREXT01_JVC_D.264 fate-h264-conformance-frext-frext02_jvc_c: CMD = framecrc -i $(TARGET_SAMPLES)/h264-conformance/FRext/FREXT02_JVC_C.264 fate-h264-conformance-frext-frext1_panasonic_c: CMD = framecrc -i $(TARGET_SAMPLES)/h264-conformance/FRext/FRExt1_Panasonic.avc -fate-h264-conformance-frext-frext2_panasonic_b: CMD = framecrc -i $(TARGET_SAMPLES)/h264-conformance/FRext/FRExt2_Panasonic.avc -vsync passthrough +fate-h264-conformance-frext-frext2_panasonic_b: CMD = framecrc -i $(TARGET_SAMPLES)/h264-conformance/FRext/FRExt2_Panasonic.avc fate-h264-conformance-frext-frext3_panasonic_d: CMD = framecrc -i $(TARGET_SAMPLES)/h264-conformance/FRext/FRExt3_Panasonic.avc fate-h264-conformance-frext-frext4_panasonic_a: CMD = framecrc -i $(TARGET_SAMPLES)/h264-conformance/FRext/FRExt4_Panasonic.avc fate-h264-conformance-frext-frext_mmco4_sony_b: CMD = framecrc -i $(TARGET_SAMPLES)/h264-conformance/FRext/FRExt_MMCO4_Sony_B.264 diff --git a/tests/ref/fate/h264-conformance-frext-frext2_panasonic_b b/tests/ref/fate/h264-conformance-frext-frext2_panasonic_b index 76e4d26cf8f..d4435700828 100644 --- a/tests/ref/fate/h264-conformance-frext-frext2_panasonic_b +++ b/tests/ref/fate/h264-conformance-frext-frext2_panasonic_b @@ -3,18 +3,18 @@ #codec_id 0: rawvideo #dimensions 0: 352x288 #sar 0: 0/1 -0, 0, 0, 1, 152064, 0x0147a2a9 -0, 1, 1, 1, 152064, 0xe2365351 -0, 2, 2, 1, 152064, 0xb5f9daee -0, 3, 3, 1, 152064, 0xd60818b2 -0, 4, 4, 1, 152064, 0x21b528e5 -0, 5, 5, 1, 152064, 0x9c9dda18 -0, 6, 6, 1, 152064, 0x387fe7de -0, 7, 7, 1, 152064, 0x8f0c5a1e -0, 8, 8, 1, 152064, 0x02409694 -0, 9, 9, 1, 152064, 0x2b36a7a7 -0, 10, 10, 1, 152064, 0x3c6d3863 -0, 11, 11, 1, 152064, 0xaa7835e1 -0, 12, 12, 1, 152064, 0x6d105fe7 -0, 13, 13, 1, 152064, 0x9a348732 -0, 14, 14, 1, 152064, 0x96a3af13 +0, 1, 1, 1, 152064, 0x0147a2a9 +0, 2, 2, 1, 152064, 0xe2365351 +0, 3, 3, 1, 152064, 0xb5f9daee +0, 4, 4, 1, 152064, 0xd60818b2 +0, 5, 5, 1, 152064, 0x21b528e5 +0, 6, 6, 1, 152064, 0x9c9dda18 +0, 7, 7, 1, 152064, 0x387fe7de +0, 8, 8, 1, 152064, 0x8f0c5a1e +0, 9, 9, 1, 152064, 0x02409694 +0, 10, 10, 1, 152064, 0x2b36a7a7 +0, 11, 11, 1, 152064, 0x3c6d3863 +0, 12, 12, 1, 152064, 0xaa7835e1 +0, 13, 13, 1, 152064, 0x6d105fe7 +0, 14, 14, 1, 152064, 0x9a348732 +0, 15, 15, 1, 152064, 0x96a3af13 diff --git a/tests/ref/fate/h264-conformance-frext-frext4_panasonic_a b/tests/ref/fate/h264-conformance-frext-frext4_panasonic_a index 5640228a263..1f678d1122c 100644 --- a/tests/ref/fate/h264-conformance-frext-frext4_panasonic_a +++ b/tests/ref/fate/h264-conformance-frext-frext4_panasonic_a @@ -3,13 +3,13 @@ #codec_id 0: rawvideo #dimensions 0: 352x288 #sar 0: 0/1 -0, 0, 0, 1, 152064, 0xd604d440 -0, 1, 1, 1, 152064, 0x08ef262c -0, 2, 2, 1, 152064, 0x992fca8e -0, 3, 3, 1, 152064, 0x5a02ee15 -0, 4, 4, 1, 152064, 0xf15d5c66 -0, 5, 5, 1, 152064, 0x360dda12 -0, 6, 6, 1, 152064, 0x18b54985 -0, 7, 7, 1, 152064, 0xf12b6cde -0, 8, 8, 1, 152064, 0x3b2e63f7 -0, 9, 9, 1, 152064, 0x140abcfd +0, 1, 1, 1, 152064, 0xd604d440 +0, 2, 2, 1, 152064, 0x08ef262c +0, 3, 3, 1, 152064, 0x992fca8e +0, 4, 4, 1, 152064, 0x5a02ee15 +0, 5, 5, 1, 152064, 0xf15d5c66 +0, 6, 6, 1, 152064, 0x360dda12 +0, 7, 7, 1, 152064, 0x18b54985 +0, 8, 8, 1, 152064, 0xf12b6cde +0, 9, 9, 1, 152064, 0x3b2e63f7 +0, 10, 10, 1, 152064, 0x140abcfd diff --git a/tests/ref/fate/hevc-conformance-CIP_A_Panasonic_3 b/tests/ref/fate/hevc-conformance-CIP_A_Panasonic_3 index ebe0f676d27..3adef2f366e 100644 --- a/tests/ref/fate/hevc-conformance-CIP_A_Panasonic_3 +++ b/tests/ref/fate/hevc-conformance-CIP_A_Panasonic_3 @@ -3,5 +3,5 @@ #codec_id 0: rawvideo #dimensions 0: 416x240 #sar 0: 0/1 -0, 2, 2, 1, 149760, 0x6e1f16d0 -0, 3, 3, 1, 149760, 0x5be5bde9 +0, 0, 0, 1, 149760, 0x6e1f16d0 +0, 1, 1, 1, 149760, 0x5be5bde9 diff --git a/tests/ref/fate/hevc-conformance-CIP_C_Panasonic_2 b/tests/ref/fate/hevc-conformance-CIP_C_Panasonic_2 index 74f7f8cd74b..8e6c681cfef 100644 --- a/tests/ref/fate/hevc-conformance-CIP_C_Panasonic_2 +++ b/tests/ref/fate/hevc-conformance-CIP_C_Panasonic_2 @@ -3,5 +3,5 @@ #codec_id 0: rawvideo #dimensions 0: 416x240 #sar 0: 0/1 -0, 2, 2, 1, 149760, 0xcd1019b2 -0, 3, 3, 1, 149760, 0xeb39efeb +0, 0, 0, 1, 149760, 0xcd1019b2 +0, 1, 1, 1, 149760, 0xeb39efeb diff --git a/tests/ref/fate/hevc-conformance-SDH_A_Orange_3 b/tests/ref/fate/hevc-conformance-SDH_A_Orange_3 index e5bc4f8121b..f3ef192c6a6 100644 --- a/tests/ref/fate/hevc-conformance-SDH_A_Orange_3 +++ b/tests/ref/fate/hevc-conformance-SDH_A_Orange_3 @@ -3,5 +3,5 @@ #codec_id 0: rawvideo #dimensions 0: 1920x1080 #sar 0: 0/1 -0, 2, 2, 1, 3110400, 0x0117aa5d -0, 3, 3, 1, 3110400, 0xa737bc56 +0, 0, 0, 1, 3110400, 0x0117aa5d +0, 1, 1, 1, 3110400, 0xa737bc56 diff --git a/tests/ref/fate/hevc-small422chroma b/tests/ref/fate/hevc-small422chroma index 954829a0ab6..de0ea46c31a 100644 --- a/tests/ref/fate/hevc-small422chroma +++ b/tests/ref/fate/hevc-small422chroma @@ -3,4 +3,4 @@ #codec_id 0: rawvideo #dimensions 0: 3840x2160 #sar 0: 1/1 -0, 11, 11, 1, 33177600, 0x53015e18 +0, 7, 7, 1, 33177600, 0x53015e18