From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTP id BD648463C0 for ; Sat, 14 Oct 2023 13:40:42 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 3420F68B349; Sat, 14 Oct 2023 16:40:40 +0300 (EEST) Received: from haasn.dev (haasn.dev [78.46.187.166]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id A4FEE68060D for ; Sat, 14 Oct 2023 16:40:33 +0300 (EEST) Received: from haasn.dev (unknown [10.30.0.2]) by haasn.dev (Postfix) with ESMTP id 4A7CC41EC3 for ; Sat, 14 Oct 2023 15:40:33 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=haasn.xyz; s=mail; t=1697290833; bh=MABGhITq0A80AdQ6HHPiPt56tS52c9Ligo/JQZGejUE=; h=Date:From:To:Subject:In-Reply-To:References:From; b=IHt1eEA7RNRkEpc/h7yj8xXFsbBKcstXp30ldLn38jMyclnn8e6c3Y5HPfYh0POj4 c/cwvM2bVT9BrnV3NPN4g0J+3DBXK6WMGPBG6QhFDPKG2SgNWbE7Q2M1fb7XHtxAZ9 8kaEJNVM0Z+hmmQAc1YxnN6EcQ4cExa4iWcaEzes= Date: Sat, 14 Oct 2023 15:40:33 +0200 Message-ID: <20231014154033.GB91591@haasn.xyz> From: Niklas Haas To: ffmpeg-devel@ffmpeg.org In-Reply-To: References: <20231013142706.23971-1-ffmpeg@haasn.xyz> <20231013142706.23971-3-ffmpeg@haasn.xyz> MIME-Version: 1.0 Content-Disposition: inline Subject: Re: [FFmpeg-devel] [PATCH v2 02/13] avcodec: add extended AVCodec color metadata 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 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: On Sat, 14 Oct 2023 09:31:32 -0400 Leo Izen wrote: > On 10/13/23 10:24, Niklas Haas wrote: > > From: Niklas Haas > > > > This is motivated primarily by a desire for YUVJ removal, which will > > require signalling the supported color ranges as part of the codec > > capabilities. But since we're here anyway, we might as well add all of > > the metadata, which I foresee seeing more use in the future (e.g. > > automatic conversion from HDR to SDR when encoding to formats that don't > > support AVCOL_TRC_SMPTE2084, ...) > > --- > > + > > + /* Extended colorspace support metadata */ > > + const enum AVColorSpace *csps; ///< array of supported color spaces, or NULL if unknown, array is terminated by AVCOL_SPC_UNSPECIFIED > > + const enum AVColorRange *color_ranges; ///< array of supported color ranges, or NULL if unknown, array is terminated by 0 > > + const enum AVChromaLocation *chroma_locs; ///< array of supported chroma locations, or NULL if unknown, array is terminated by 0 > > + const enum AVColorPrimaries *primaries; ///< array of supported color primaries, or NULL if unknown, array is terminated by 0 > > + const enum AVColorTransferCharacteristic *trcs; ///< array of supported transfer characteristics, or NULL if known, array is terminated by 0 > > } AVCodec; > > > Any particular reason we're using AVCOL_SPC_UNSPECIFIED to terminate > csps, but not using AVCOL_PRI_UNSPECIFIED for the primaries and the > equivalent for the TRC? It seems a bit more consistent than using RESERVED0 To be clear, we are - AVCOL_PRI/TRC_UNSPECIFIED are equal to 0, unlike the other fields. But I could change the comments here for clarity. _______________________________________________ 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".