From patchwork Wed Dec 13 13:12:09 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Niklas Haas X-Patchwork-Id: 45111 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:1225:b0:181:818d:5e7f with SMTP id v37csp4264606pzf; Wed, 13 Dec 2023 05:18:03 -0800 (PST) X-Google-Smtp-Source: AGHT+IHnKRZ/V/EkB5miJRsi3uNx4jrTLLwF85aMDKZssF9wcC6OHhoqvY4qnXPSMJSAt8VTU816 X-Received: by 2002:a19:a404:0:b0:50b:f9bf:66de with SMTP id q4-20020a19a404000000b0050bf9bf66demr3594448lfc.36.1702473482881; Wed, 13 Dec 2023 05:18:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702473482; cv=none; d=google.com; s=arc-20160816; b=JIp8AmyKF44UclTIazPODpSSzb91hejmI02K2q+DmFIyzIwcBQIuSra7NM4B9UhYS6 HdpUcloQ4ZUSd79DBgE7bLJxDovb3OwlFIZkfNzpKs65W/p63T7U/QIIm2/Sc/JuI6ah hx5NzZBHLe1bNlYOmDj+y6blpUiql7kQIdruGIMTup3ryF+vx/qeYnOCKEw3f4Cyf1Xl PED3eEilzL/Fd44kaExhAG41pO8Hb5HbmGP5N0j8SmpWmZnsclgGU4tXB26czyJnrCY8 1NkHIfR7nlLT67+WEIG6E0QLPERpEhgU//tMHw9AkFBrrHylX3Nb13X1jXi82q1Rzu+7 S01A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:cc: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:dkim-signature:delivered-to; bh=WSi09+yeEY0k2cGpZMBGaPF8Bdzd1s2fkrYgsnJoPrE=; fh=xmAeKtysnShNOmkhiJmYkS30uw4Fu2hvBJ7qlIwukxQ=; b=iP+1Wyqyv2pTJL64VUxeY9fQWujj9t2kB0SoA7ngpyFd8vcgFaw/OOSW5LteiKOyQs S7YVaEMXHbDvVFh/waild7EGIqviCQ8mqidf34AVXRddhdg/DO1w2ByVvZ+KnMHS8Yip PI5fxCmJpIfdcpzbwZW2p6MD2S1lNeKXcOoAIWgiBaw+kVU8tVy/hPXDR2poo3/+TRZt m21GF2R4DDDi9Z83M+MdvLnaepxErCV9QUtVnK1rnCBycmXyhP/V8lPIf9D3DzdToel3 rSZ8jSKXPIOYKWTbgnOJRtRnB/wD4nLSJ5hhodg9hsojM7hB2komHndOGzGywf/CoN09 YgFQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@haasn.xyz header.s=mail header.b=Y2Z7w+Kj; 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 z11-20020a1709067e4b00b00a1b7769f832si5625996ejr.614.2023.12.13.05.18.02; Wed, 13 Dec 2023 05:18:02 -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; dkim=neutral (body hash did not verify) header.i=@haasn.xyz header.s=mail header.b=Y2Z7w+Kj; 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 06F9468D032; Wed, 13 Dec 2023 15:16:01 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from haasn.dev (haasn.dev [78.46.187.166]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 0DA0068D1F3 for ; Wed, 13 Dec 2023 15:15:45 +0200 (EET) Received: from haasn.dev (unknown [10.30.0.2]) by haasn.dev (Postfix) with ESMTP id 7C7514BD47; Wed, 13 Dec 2023 14:15:42 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=haasn.xyz; s=mail; t=1702473342; bh=O4YG7kRTn7L6E4rHeK7afoWuwMrv40EuRsuAv/4L4lI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Y2Z7w+Kj4ERIZitek+Fqkq2nCmD0OhVa//wwa5cs1h6XmRacKAEnUoKjIFoloiUw4 NOY2rzDl7jwP0RoUGIO9WoxITgczfE/51ZnVituikmeDHbFDaZpI4btaqWkS0+RHJU PFid948i+Zj/3vBlAYRtzJyJQ8zuks6pi25DedPE= From: Niklas Haas To: ffmpeg-devel@ffmpeg.org Date: Wed, 13 Dec 2023 14:12:09 +0100 Message-ID: <20231213131536.10242-13-ffmpeg@haasn.xyz> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231213131536.10242-1-ffmpeg@haasn.xyz> References: <20231213131536.10242-1-ffmpeg@haasn.xyz> MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH v2 12/15] avfilter/buffersink: add color space/range accessors 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 Cc: Niklas Haas Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: /Zsgsa29Ii24 From: Niklas Haas Needed for fftools. --- doc/APIchanges | 3 +++ libavfilter/buffersink.c | 2 ++ libavfilter/buffersink.h | 2 ++ libavfilter/version.h | 2 +- 4 files changed, 8 insertions(+), 1 deletion(-) diff --git a/doc/APIchanges b/doc/APIchanges index 2f6ea50f63..578c2c4641 100644 --- a/doc/APIchanges +++ b/doc/APIchanges @@ -2,6 +2,9 @@ The last version increases of all libraries were on 2023-02-09 API changes, most recent first: +2023-11-xx - xxxxxxxxxx - lavf 58.15.100 - buffersink.h + Add av_buffersink_get_colorspace and av_buffersink_get_color_range. + 2023-11-xx - xxxxxxxxxx - lavf 58.14.100 - avfilter.h Add AVFilterLink.colorspace, AVFilterLink.color_range diff --git a/libavfilter/buffersink.c b/libavfilter/buffersink.c index 3da3331159..6ba2970dd5 100644 --- a/libavfilter/buffersink.c +++ b/libavfilter/buffersink.c @@ -209,6 +209,8 @@ MAKE_AVFILTERLINK_ACCESSOR(AVRational , frame_rate ) MAKE_AVFILTERLINK_ACCESSOR(int , w ) MAKE_AVFILTERLINK_ACCESSOR(int , h ) MAKE_AVFILTERLINK_ACCESSOR(AVRational , sample_aspect_ratio) +MAKE_AVFILTERLINK_ACCESSOR(enum AVColorSpace, colorspace) +MAKE_AVFILTERLINK_ACCESSOR(enum AVColorRange, color_range) #if FF_API_OLD_CHANNEL_LAYOUT FF_DISABLE_DEPRECATION_WARNINGS diff --git a/libavfilter/buffersink.h b/libavfilter/buffersink.h index 64e08de53e..a9374b8b4f 100644 --- a/libavfilter/buffersink.h +++ b/libavfilter/buffersink.h @@ -117,6 +117,8 @@ AVRational av_buffersink_get_frame_rate (const AVFilterContext *c int av_buffersink_get_w (const AVFilterContext *ctx); int av_buffersink_get_h (const AVFilterContext *ctx); AVRational av_buffersink_get_sample_aspect_ratio (const AVFilterContext *ctx); +enum AVColorSpace av_buffersink_get_colorspace (const AVFilterContext *ctx); +enum AVColorRange av_buffersink_get_color_range (const AVFilterContext *ctx); int av_buffersink_get_channels (const AVFilterContext *ctx); #if FF_API_OLD_CHANNEL_LAYOUT diff --git a/libavfilter/version.h b/libavfilter/version.h index 7642b670d1..59330858bd 100644 --- a/libavfilter/version.h +++ b/libavfilter/version.h @@ -31,7 +31,7 @@ #include "version_major.h" -#define LIBAVFILTER_VERSION_MINOR 14 +#define LIBAVFILTER_VERSION_MINOR 15 #define LIBAVFILTER_VERSION_MICRO 100