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 25EF7491C7 for ; Wed, 6 Mar 2024 15:43:46 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id F403368CC28; Wed, 6 Mar 2024 17:43:44 +0200 (EET) Received: from mail-pl1-f179.google.com (mail-pl1-f179.google.com [209.85.214.179]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 85D9668BBA3 for ; Wed, 6 Mar 2024 17:43:38 +0200 (EET) Received: by mail-pl1-f179.google.com with SMTP id d9443c01a7336-1dcbf3e4598so4354345ad.1 for ; Wed, 06 Mar 2024 07:43:38 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709739817; x=1710344617; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=sZqUGiyPmgjiPve0K1dc8zUmqb1ZayPowtpMV56YRdw=; b=jZtYe6tb1RqmJFCI2xetRAI+jSadWNA7XGL5MEX1mDR/owF//TAiAwkrCMXkcKQwBn RkTBToJ5dZBSQiBK7FfehqAz11RjHQnx5KaPD9F+0Vieb14AJghzfQK9HBC/27HDipGe oSmT+B09z0HwL+iutcqEzydnyPU3r/J5SpWr0xOrOTh0uqjODr25N3fe9mfHe4633S0q 7nlKJKQ7XMCaN9ChCbdeRFylmGINOhIJHkPOLiYgciMTWIcB+bC9QQNPYW//hIQHJHgm 9/CpfPn7np8On5njnP4/53232SHoSPYb9ArzJJgfETd1zA5oeYi/MIhj9HvyKnKpiVq6 3RnA== X-Gm-Message-State: AOJu0YxM16WUzabPlt8ALyJQqiM6uTjb3UuQS5/XvTz7k4QSPWzSknNQ GLY+Eqx7tLTMv+kMyZ7sqkUj46WAbqOnazsYZdzKiT+JjDiY9weETy8RHDZsRVbLR6EourkC6aM H7rrAwKQ6+89gypNveEVub/Acl5xTnxzdnTb/8+R7R/vgWhc41uc= X-Google-Smtp-Source: AGHT+IEn3ahfmRazdAPf/MRXDWUYcKfwupmx383yA1Y04tw80YUleQgNTYy68cms+8eVd3ZwQ8tzD8JqWgjvJCBQaPc= X-Received: by 2002:a17:902:ba88:b0:1dc:96c9:a122 with SMTP id k8-20020a170902ba8800b001dc96c9a122mr3929496pls.5.1709739816728; Wed, 06 Mar 2024 07:43:36 -0800 (PST) MIME-Version: 1.0 References: <20240306071913.2735832-1-marth64@proxyid.net> In-Reply-To: From: Marth64 Date: Wed, 6 Mar 2024 09:43:26 -0600 Message-ID: To: Marth64 X-Content-Filtered-By: Mailman/MimeDel 2.1.29 Subject: Re: [FFmpeg-devel] [PATCH 1/3] avformat/dvdvideodec: add CLUT utilities and subtitle palette support 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: 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: It is true that this is necessary when muxing to Matroska, but it is also the case for MOV - the MOV muxer expects RGB prior to converting to YUV again. So this would be needed for MOV also, despite the awkward conversion circle. I should update the document to reflect this. On Wed, Mar 6, 2024 at 09:36 Marth64 wrote: > Good morning, > > DVD subtitle palettes, which are natively YUV, are currently carried as > a hex string in their respective subtitle streams and have > no concept of colorspace tagging (even predating dvd demuxer). The > convention is to convert > them to RGB prior to storage. Common players will only render > the palettes properly if they are stored as RGB. Even ffmpeg itself > expects this, and already does -in libavformat- the YUV-RGB conversions, > specifically in mov.c and movenc.c. > > The point of this patch is to provide a consolidation of the code > that deals with creating the extradata as well as the RGB conversion. > That can then (1) enable usable palette support for DVD demuxer if it is > merged > and (2) start the process of consolidating the related conversions in > MOV muxer/demuxer and eventually find a way to properly tag > the colorspace. > > Thank you! > > On Wed, Mar 6, 2024 at 09:18 Timo Rothenpieler > wrote: > >> On 06/03/2024 16:09, Stefano Sabatini wrote: >> > On date Wednesday 2024-03-06 01:19:11 -0600, Marth64 wrote: >> >> Since last iteration: removes unused variable in dvdclut.c >> >> >> >> Signed-off-by: Marth64 >> >> --- >> >> doc/demuxers.texi | 5 +++ >> >> libavformat/Makefile | 2 +- >> >> libavformat/dvdclut.c | 75 >> +++++++++++++++++++++++++++++++++++++++ >> >> libavformat/dvdclut.h | 37 +++++++++++++++++++ >> >> libavformat/dvdvideodec.c | 15 ++++++++ >> >> 5 files changed, 133 insertions(+), 1 deletion(-) >> >> create mode 100644 libavformat/dvdclut.c >> >> create mode 100644 libavformat/dvdclut.h >> >> >> >> diff --git a/doc/demuxers.texi b/doc/demuxers.texi >> >> index f4bac8f3b3..1a17c6db16 100644 >> >> --- a/doc/demuxers.texi >> >> +++ b/doc/demuxers.texi >> >> @@ -394,6 +394,11 @@ often with junk data intended for controlling a >> real DVD player's >> >> buffering speed and with no other material data value. >> >> Default is 1, true. >> >> >> > >> >> +@item clut_rgb @var{bool} >> >> +Output subtitle palettes (CLUTs) as RGB, required for Matroska. >> >> +Disable to output the palette in its original YUV colorspace. >> >> +Default is 1, true. >> > >> > Can you expand about this? When is matroska used in a DVD? >> >> Sounds to me like muxing _to_ matroska needs RGB palettes, but DVDs >> bring YUV ones. >> >> > Can we make the setting automatic in case matroska is detected? >> > >> > [...] >> > >> > LGTM otherwise. >> > _______________________________________________ >> > 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". >> _______________________________________________ >> 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". >> > _______________________________________________ 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".