From patchwork Tue Jun 27 17:23:42 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dominik 'Rathann' Mierzejewski X-Patchwork-Id: 42307 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:3b1e:b0:12b:9ae3:586d with SMTP id c30csp429430pzh; Tue, 27 Jun 2023 10:23:55 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6r5Z7bEyQMmyOwf0HSpMiC3ZsUNzuvbOsg7j+awP4C5OVJTk1a1iDYnT6hb54M35+NuQHs X-Received: by 2002:a05:6402:50d4:b0:51d:a5c6:37c1 with SMTP id h20-20020a05640250d400b0051da5c637c1mr3636810edb.1.1687886635271; Tue, 27 Jun 2023 10:23:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1687886635; cv=none; d=google.com; s=arc-20160816; b=fQqjRt5aSDQiT7T3UCNVPlryLRY0yOVWLK6Tuwz2ZVinWqDt9F5xWOifYRbUo0gas9 QtSGxFvZKxpL6AQE8OBCdRqgeE2l7waRcCJQP2/rO3h7FG0+Hf3pi6btYbuOXhGFpCjw B7ZDvSGaPVA1oNHuOKjDRG4tMrXUhzzf5/FhiiC8dOf8m5g2XJv2Z4YYkTWzbnx9HPHV km1eh5S6XcZJgCQtR6dJ+OdJ5S2HvU8UFkwQtZK8wkdSJcTmt0BjIKG2smNeLeQSI0b6 Lh61hpZGHoM4AB48A2B/XPFFupmDdLCdFgzIC8r4pAQ8gKUaj8SdLUDUP1nLbUrctM+X 8PQQ== 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:content-disposition:mime-version:message-id:to :from:date:dkim-signature:dkim-filter:delivered-to; bh=KUZrN3lWIa6EoQPBad1Sm4kPnxfeHxhkzsguSlXrOaE=; fh=YOA8vD9MJZuwZ71F/05pj6KdCjf6jQRmzLS+CATXUQk=; b=IitVGnRaFS5ajJG+ksxmXcH5yAqKfhYueodHM9qoaDMJ29u8b4LfexupUk/PVNSel/ eQ5W4Nb22QwPOiwIG/f5PXFjpnqnZLmduwPLlydAtP7qAft4p2+u4ZZAsKncJApgBe73 W/d3wJORlwBe9TFdBOIBDZI2uvlK8/Sc4VbgiNFBxTiCB4H+4AZhf+MNSuJR7DG+/RJG JkZZO1025/ssAMaiLDdBLpgKV2l9HTKIdtC4QyRw2YysMTJnklTC0rgFI9zaaffcMDJr xt5XW6Z1HyxetvNejIjj3zaMgXxksANlWF1LPrdFAR0glDhDG4AncoAFi+U5fItCKhVR BG8A== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@greysector.net header.s=default header.b=A8iF9BHF; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=greysector.net Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id x16-20020aa7d390000000b0051d97fd68basi2781639edq.466.2023.06.27.10.23.54; Tue, 27 Jun 2023 10:23:55 -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; dkim=neutral (body hash did not verify) header.i=@greysector.net header.s=default header.b=A8iF9BHF; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=greysector.net Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id A28C068C38A; Tue, 27 Jun 2023 20:23:51 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from arashi.greysector.net (arashi.greysector.net [51.68.141.79]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id E7F6468BFE8 for ; Tue, 27 Jun 2023 20:23:44 +0300 (EEST) Received: from sakura.greysector.net (unknown [212.180.189.198]) (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) (No client certificate requested) by arashi.greysector.net (Postfix) with ESMTPSA id 05B0E5AFD for ; Tue, 27 Jun 2023 19:23:44 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 arashi.greysector.net 05B0E5AFD DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=greysector.net; s=default; t=1687886624; bh=Mow/R5w31vlNrY5f3nIx7G4oKakgfBdsakg+5H01ndo=; h=Date:From:To:Subject:From; b=A8iF9BHFLvG7jCpt9gp5CIIr/1x/q2D4n5zrKRXQD4ve7naPeDBao++IUmnXI98HS 4U6R/Zj+TmbgticSPAph2NkwaWA3YNN/v8GwdbzY9hwd5uzyVNs1BnD4qEitKGiE80 g5QVpA+WtRuqw8UlHyevlTNtuA7hbE1Fsz1Ze4Ao= Date: Tue, 27 Jun 2023 19:23:42 +0200 From: Dominik 'Rathann' Mierzejewski To: ffmpeg-devel@ffmpeg.org Message-ID: MIME-Version: 1.0 Content-Disposition: inline Subject: [FFmpeg-devel] [PATCH] enable 'dvh1' FourCC in MP4 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: Isp1T5eTahJf Hi! I'm forwarding this patch from HandBrake. Original author is Damiano Galassi (galad87@github). Apparently, this is required to pass through Dolby Vision metadata to x265. Author's comment says: 'Profile 5 seems to require the "dvh1" fourcc.' See https://github.com/HandBrake/HandBrake/pull/4838 for more details. Regards, Dominik diff --git a/libavformat/movenc.c b/libavformat/movenc.c index 5608afd..f46df18 100644 --- a/libavformat/movenc.c +++ b/libavformat/movenc.c @@ -7689,6 +7689,7 @@ static const AVCodecTag codec_mp4_tags[] = { { AV_CODEC_ID_H264, MKTAG('a', 'v', 'c', '3') }, { AV_CODEC_ID_HEVC, MKTAG('h', 'e', 'v', '1') }, { AV_CODEC_ID_HEVC, MKTAG('h', 'v', 'c', '1') }, + { AV_CODEC_ID_HEVC, MKTAG('d', 'v', 'h', '1') }, { AV_CODEC_ID_MPEG2VIDEO, MKTAG('m', 'p', '4', 'v') }, { AV_CODEC_ID_MPEG1VIDEO, MKTAG('m', 'p', '4', 'v') }, { AV_CODEC_ID_MJPEG, MKTAG('m', 'p', '4', 'v') },