From patchwork Sun Jan 2 17:46:04 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anton Khirnov X-Patchwork-Id: 33018 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a6b:cd86:0:0:0:0:0 with SMTP id d128csp15552032iog; Sun, 2 Jan 2022 09:46:52 -0800 (PST) X-Google-Smtp-Source: ABdhPJyk00ciUdI/+iGzi12YBYuqH8JrMLXZkf/n2PdG11ZlWbL1CvonVlVf0y6obeFrc+fFNYWS X-Received: by 2002:aa7:d6d5:: with SMTP id x21mr42177188edr.201.1641145612352; Sun, 02 Jan 2022 09:46:52 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1641145612; cv=none; d=google.com; s=arc-20160816; b=VOUAbqRwrOpA8yYX+ajkMnU6pEp7UYYjVjchz/aGEf+cCnCy7oyjYl1t0MblSb7REC 3C+SIcjjPBatdBYzzv18Qpa6oGNnJNJtAVRNMlxZLb+q/EeF5PRJhAoPwK+f8L/Jabmb rI7MvviaIyT67eieeL9WnbxS8pxRlCPoR2r6RnxM11IbBERdcmUaDp7rJ2pajZ0MBFGW iF0N04FQWUjT/pQ5Ss36YFG4OIN6QIbyvRFFnVUBoHK+UxXeAKdumWFcJxn0zzS1/rOD aWRf4GjiYwKwni1VRkg6daRtKb5aiUTWE0lYJ7EHtymN3ELO4oc1EhqiEnwxcyHjyYHT s2SQ== 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=m6vfIOYWcU3EkVlNNFcGBINTsTd/LY0Rvlfd8/I25bY=; b=Tl/M6I0tZRTaOoU1kQdaYvHUntp2WLX/IiSr4mM1B7uQXDqSvOsKnxKVo8ofLjdqm3 Drb3FWisSPyqstNS/B+ybfuegFUGZssFe2Nuia5AtXAeD4dv39z8D+zilYxRxlkTYOOd UtYE5VkhLdBS4PYHTZbh5qXrNhEOtwicbt8ZchOqLMPPXs7U+Qf2jCsdL3IteXDVzn5/ sd8FnQqhddf5Vr2W0gVNp1+379HV8iaM60OIk/YRYYwz4GhiweXCJOpGE3AqFXCgvI87 5vmCxXjtSmTSrzqxzXoqSAywckrsIvIJLJVrV1qxo2ttLQlhyUtn1HKZDvJO18dNBo6u KYtw== 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 q7si17737946edd.118.2022.01.02.09.46.51; Sun, 02 Jan 2022 09:46:52 -0800 (PST) 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 9066868B176; Sun, 2 Jan 2022 19:46:40 +0200 (EET) 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 4373168B153 for ; Sun, 2 Jan 2022 19:46:34 +0200 (EET) Received: from localhost (localhost [IPv6:::1]) by mail0.khirnov.net (Postfix) with ESMTP id E331524017C for ; Sun, 2 Jan 2022 18:46:33 +0100 (CET) Received: from mail0.khirnov.net ([IPv6:::1]) by localhost (mail0.khirnov.net [IPv6:::1]) (amavisd-new, port 10024) with ESMTP id aei4YwOdcYOP for ; Sun, 2 Jan 2022 18:46:31 +0100 (CET) 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 35BA2240179 for ; Sun, 2 Jan 2022 18:46:31 +0100 (CET) Received: by libav.khirnov.net (Postfix, from userid 1000) id 2DA643A0631; Sun, 2 Jan 2022 18:46:31 +0100 (CET) From: Anton Khirnov To: ffmpeg-devel@ffmpeg.org Date: Sun, 2 Jan 2022 18:46:04 +0100 Message-Id: <20220102174605.2438-1-anton@khirnov.net> X-Mailer: git-send-email 2.33.0 MIME-Version: 1.0 Subject: [FFmpeg-devel] [RFC/PATCH 1/2] lavf: add a flag for experimental (de)muxers 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: hwwEzSh4T07P --- doc/APIchanges | 3 +++ libavformat/avformat.h | 7 +++++++ libavformat/format.c | 2 ++ libavformat/version.h | 2 +- 4 files changed, 13 insertions(+), 1 deletion(-) diff --git a/doc/APIchanges b/doc/APIchanges index 670a59329e..29c235630e 100644 --- a/doc/APIchanges +++ b/doc/APIchanges @@ -14,6 +14,9 @@ libavutil: 2021-04-27 API changes, most recent first: +2022-01-xx - xxxxxxxxxx - lavf 59.13.100 - avformat.h + Add AVFMT_EXPERIMENTAL flag. + 2021-12-xx - xxxxxxxxxx - lavu 57.13.100 - hwcontext_videotoolbox.h Add av_vt_pixbuf_set_attachments diff --git a/libavformat/avformat.h b/libavformat/avformat.h index 70b36d7682..6ce367e854 100644 --- a/libavformat/avformat.h +++ b/libavformat/avformat.h @@ -463,6 +463,13 @@ typedef struct AVProbeData { /// Demuxer will use avio_open, no opened file should be provided by the caller. #define AVFMT_NOFILE 0x0001 #define AVFMT_NEEDNUMBER 0x0002 /**< Needs '%d' in filename. */ +/** + * The muxer/demuxer is experimental and should be used with caution. + * + * - demuxers: will not be selected automatically by probing, must be specified + * explicitly. + */ +#define AVFMT_EXPERIMENTAL 0x0004 #define AVFMT_SHOW_IDS 0x0008 /**< Show format stream IDs numbers. */ #define AVFMT_GLOBALHEADER 0x0040 /**< Format wants global header. */ #define AVFMT_NOTIMESTAMPS 0x0080 /**< Format does not need / have any timestamps. */ diff --git a/libavformat/format.c b/libavformat/format.c index 387627009e..52b85c16a2 100644 --- a/libavformat/format.c +++ b/libavformat/format.c @@ -158,6 +158,8 @@ const AVInputFormat *av_probe_input_format3(const AVProbeData *pd, } while ((fmt1 = av_demuxer_iterate(&i))) { + if (fmt1->flags & AVFMT_EXPERIMENTAL) + continue; if (!is_opened == !(fmt1->flags & AVFMT_NOFILE) && strcmp(fmt1->name, "image2")) continue; score = 0; diff --git a/libavformat/version.h b/libavformat/version.h index 917b9ffa5d..29dcce352b 100644 --- a/libavformat/version.h +++ b/libavformat/version.h @@ -32,7 +32,7 @@ // Major bumping may affect Ticket5467, 5421, 5451(compatibility with Chromium) // Also please add any ticket numbers that you believe might be affected here #define LIBAVFORMAT_VERSION_MAJOR 59 -#define LIBAVFORMAT_VERSION_MINOR 12 +#define LIBAVFORMAT_VERSION_MINOR 13 #define LIBAVFORMAT_VERSION_MICRO 100 #define LIBAVFORMAT_VERSION_INT AV_VERSION_INT(LIBAVFORMAT_VERSION_MAJOR, \ From patchwork Sun Jan 2 17:46:05 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anton Khirnov X-Patchwork-Id: 33017 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a6b:cd86:0:0:0:0:0 with SMTP id d128csp15551973iog; Sun, 2 Jan 2022 09:46:43 -0800 (PST) X-Google-Smtp-Source: ABdhPJz2efREbCVSuJ49thc1ohrFgBCzAuU6GPSTyBvoKaeHrX4KnT3V66CbbCCLTtP9QSy0+Yyx X-Received: by 2002:a05:6402:41a:: with SMTP id q26mr42154058edv.387.1641145603779; Sun, 02 Jan 2022 09:46:43 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1641145603; cv=none; d=google.com; s=arc-20160816; b=Wu2oUKu10eSLpAHe55l1rqpRxSYpqftJe19bo+qqtUFJxMqfilfaWqiHNlA3sHKfWg a8N7SdYaJ37QiWmrEn0CUPUag4zos/znurVGf9xejFmZH66kf57Aehc/gms+kijCawni LMOA81BTqegMsf6GHspLlwzaBI9KCjeJ3WeeVLd8AIdLjQ3ct4nO3jt3/sFc505TgWFD uxQgN2fbO1890T9sw44BiNZTNMhmYIRvlLftUXzC4Zrb1sZLcCFXayeDvnD4SUxWXWtX 11TXQ3+Fp81BkSxd/ahmFHdLI8hEgyP1x7L38FNIC+Bbc5O1OO5kcj5LRFn3DD8hU9jd mZOQ== 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:references:in-reply-to:message-id :date:to:from:delivered-to; bh=pDsU7VMBSgEldruIO6x2sTcbrmdTJTwkBK70JQq8WaM=; b=0XERqJk/XwaQEppU9qnsM5NQNG+l4/bzLVFdlgh6fE17ClQDbDD2AFaUVJlA/wwxRn RzcdQXmyJVT+2oHRND7LOE3vqGFTNOoFJKBO65dO+MTnVVf+ZaYdMCdZVH5fPtifufA4 bsawcfoCZrVJdZYsgr6OlLOg+dbQJDLF1wzZo8+awmp2g8YgrLP84SWO1mDozWAvyXAc MTw12a5gremlP15RI+SQV6b55eCuXK7ncrTYdCJRjN4f8iuWa1hO8ImddRNu8vcG+Hfu gMZBsu4BLvDM804zG6a92l75i56JO3JFe9aDGgimPYfpqMH2vtcm2gYfJP5tbMxIvs57 w/gA== 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 ga19si8918844ejc.883.2022.01.02.09.46.43; Sun, 02 Jan 2022 09:46:43 -0800 (PST) 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 9655668B153; Sun, 2 Jan 2022 19:46:39 +0200 (EET) 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 E121068B148 for ; Sun, 2 Jan 2022 19:46:32 +0200 (EET) Received: from localhost (localhost [IPv6:::1]) by mail0.khirnov.net (Postfix) with ESMTP id 7DB3224017E for ; Sun, 2 Jan 2022 18:46:32 +0100 (CET) Received: from mail0.khirnov.net ([IPv6:::1]) by localhost (mail0.khirnov.net [IPv6:::1]) (amavisd-new, port 10024) with ESMTP id OXZwBB6iAmQZ for ; Sun, 2 Jan 2022 18:46:31 +0100 (CET) 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 3EDC124017C for ; Sun, 2 Jan 2022 18:46:31 +0100 (CET) Received: by libav.khirnov.net (Postfix, from userid 1000) id 2FD523A00EA; Sun, 2 Jan 2022 18:46:31 +0100 (CET) From: Anton Khirnov To: ffmpeg-devel@ffmpeg.org Date: Sun, 2 Jan 2022 18:46:05 +0100 Message-Id: <20220102174605.2438-2-anton@khirnov.net> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20220102174605.2438-1-anton@khirnov.net> References: <20220102174605.2438-1-anton@khirnov.net> MIME-Version: 1.0 Subject: [FFmpeg-devel] [RFC/PATCH 2/2] lavf/imfdec: mark as experimental 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: LsGomAqYsZE7 People have expressed concerns about its safety, so prevent it from being auto-selected without explicit user indication. --- libavformat/imfdec.c | 1 + 1 file changed, 1 insertion(+) diff --git a/libavformat/imfdec.c b/libavformat/imfdec.c index f17064cfcd..228ba494ae 100644 --- a/libavformat/imfdec.c +++ b/libavformat/imfdec.c @@ -889,6 +889,7 @@ static const AVClass imf_class = { const AVInputFormat ff_imf_demuxer = { .name = "imf", .long_name = NULL_IF_CONFIG_SMALL("IMF (Interoperable Master Format)"), + .flags = AVFMT_EXPERIMENTAL, .flags_internal = FF_FMT_INIT_CLEANUP, .priv_class = &imf_class, .priv_data_size = sizeof(IMFContext),