From patchwork Thu Jan 13 02:09:05 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: James Almer X-Patchwork-Id: 33534 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a6b:cd86:0:0:0:0:0 with SMTP id d128csp46980iog; Wed, 12 Jan 2022 18:52:28 -0800 (PST) X-Google-Smtp-Source: ABdhPJwxerGQbvRm2E9ShfE8oG4DW8HLsqTC+mdleVyiSyKIEdXSCRdfFX+zidS6NY1UREraLkBK X-Received: by 2002:a17:906:3942:: with SMTP id g2mr2017356eje.160.1642042348476; Wed, 12 Jan 2022 18:52:28 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1642042348; cv=none; d=google.com; s=arc-20160816; b=PTe6abhV8I8NPzpf8vGcCQkZVJmxwlenhiC/FQ3CB18th6Jl8mf8npNgsxUPL1bu0K S+EqqXE5VOHzfsqw4a89HdYaKZ+DuE77x6DmxtX+ITMMUDwnDxXQYhfyXNimadR/tfQ0 dDm8qcp5dDBW2lYrXhufdjzZKYvVYyb0L50MiyZjHvdQZEuyu4uA/EvGTm6X/JsBnGuH TDOatFHB5bWwtIMnQ//HcK5n/VKhG6iJtOSAV6W+xBgww4sAOH1Mt7T0B2IAldUiOxA+ jermO/5zQa6wW14pxSlyTzAMcmvKUy/yVjDJbImw/eM5FMv1xcu6JCtI5IGfQVD/2H/Z R33Q== 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:dkim-signature:delivered-to; bh=fAIha3t9ZCokoXOC468Eisqo/yI7s8cg1DPtisUn/mY=; b=Y6hGcZ/y8Kjo08n+K5/51t1UPtg2UfQ1lMIoxpd0T1VIRuvETJd1w5pIGSnhmBca3/ WRElhQpt/iNOa7M62ts4c1DJfRKbHs6KeM4LrZsb9hqPxXRRC62H75b2dkHqpUhv/JlX Vi8Jz76KBNoQAPt2q/L5zNRNhLYOYJ9tFr/wZ7hqklE4vyh8eJgFndS9BOHP2f7nN0oA cuFyfJLR1v3A0DIh1w+4Nda1DmGvCfA5k2ViVOEchM+eC2hgHVtFmrkjGm9+2HgjaZnG yx5ndnlKcLHQB58ZguBSSQcX3d8/FouOfhjNIKRLekEBLrUtG8Q+5Q8xGESjI4RCejkL KbJw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20210112 header.b=ZmqK6xis; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id ec13si805126ejb.168.2022.01.12.18.52.28; Wed, 12 Jan 2022 18:52:28 -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=@gmail.com header.s=20210112 header.b=ZmqK6xis; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id B03D268BA83; Thu, 13 Jan 2022 04:09:40 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mail-qk1-f178.google.com (mail-qk1-f178.google.com [209.85.222.178]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id B011C68BA54 for ; Thu, 13 Jan 2022 04:09:32 +0200 (EET) Received: by mail-qk1-f178.google.com with SMTP id t24so5564148qkg.11 for ; Wed, 12 Jan 2022 18:09:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding; bh=5GHvh/eCAtiVVOuCh0GTWOBdu7aGZEeFoU+zD6OImeg=; b=ZmqK6xisdndmL0Uq8p84uXyjBg72PEihJex89X2F2GOmUFg8WxnTEr55hSsoNo3CFa TVcnKHmeLxLDPXW31+G+75PnWgnJNuDLxwCd0fNle4ME4qHIf3yaAqtBhabvjM5oIj2T LPo/+ds1YS9B0gsExsSa3FsVHx/bN2u/CX1v+0s3U+QQvoOm6bjw2JLZ5V1EBlBmBqgl ulER29E89h7aBqtjSWPoEB5XJch+T5Prp29bp2eG7iW3MjUmzbQNYk9judFg7vHOzHaH D/oHkPPeoPMEjB1/5wqVdWlH71brt+/F6wcTo77W1ToyZfCTF/L+OjfT5IgP4w1Pvk7u vyZw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=5GHvh/eCAtiVVOuCh0GTWOBdu7aGZEeFoU+zD6OImeg=; b=hW34M2m4ixX1nBSl+xb6mSzulQ05fWZclTgw7CxddV5ZQhAACL/R93leJen8aUdCiX DATot80ZYX4+GSwajZy8U7S//9TIHQpRlJDzs6igx9q21aH30VHofu6cnAa3TSW5g2uT ynj7CzQzdWZ9aS5r+ClkLzx0RC33ZtigpGwNhc264rlSyzxh63b1VIhaAH2B2f59eOfz 3J8fb8jYqFbKGUunAcK/axChEL7NzHpZ2u3TA6ar7Ltk1VbLTc4yN/EqRrMlnceWi3lq kRMq4E1kxf3Ey0mHZ62iQI81aXXtsy8rz/kUyy/Cvj/JaSL+Gs7RZVo8U0VDxCHXfJhs jkOA== X-Gm-Message-State: AOAM532zNYMgXtSd4/CEi75zzqX0bEyvzXLZZ3yGR5cHxqn1uESUq3F2 VApkf/ZTB0aJdCu51sPP1S61QsUR96Y= X-Received: by 2002:a05:620a:10ac:: with SMTP id h12mr1788109qkk.467.1642039771322; Wed, 12 Jan 2022 18:09:31 -0800 (PST) Received: from localhost.localdomain ([186.136.131.95]) by smtp.gmail.com with ESMTPSA id u6sm1068031qko.83.2022.01.12.18.09.30 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 12 Jan 2022 18:09:30 -0800 (PST) From: James Almer To: ffmpeg-devel@ffmpeg.org Date: Wed, 12 Jan 2022 23:09:05 -0300 Message-Id: <20220113020913.870-4-jamrial@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220113015101.4-1-jamrial@gmail.com> References: <20220113015101.4-1-jamrial@gmail.com> MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH 273/281] lavf: Add non diegetic stream disposition flag 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: m5YdZFSp+l0q From: Vittorio Giovara Signed-off-by: Vittorio Giovara Signed-off-by: Anton Khirnov Signed-off-by: James Almer --- libavformat/avformat.h | 7 +++++++ libavformat/dump.c | 2 ++ 2 files changed, 9 insertions(+) diff --git a/libavformat/avformat.h b/libavformat/avformat.h index 6ce367e854..182545e607 100644 --- a/libavformat/avformat.h +++ b/libavformat/avformat.h @@ -879,6 +879,13 @@ typedef struct AVIndexEntry { */ #define AV_DISPOSITION_TIMED_THUMBNAILS (1 << 11) +/** + * The stream is intended to be mixed with a spatial audio track. For example, + * it could be used for narration or stereo music, and may remain unchanged by + * listener head rotation. + */ +#define AV_DISPOSITION_NON_DIEGETIC (1 << 12) + /** * The subtitle stream contains captions, providing a transcription and possibly * a translation of audio. Typically intended for hearing-impaired audiences. diff --git a/libavformat/dump.c b/libavformat/dump.c index 69b838fbc7..e3f0056c20 100644 --- a/libavformat/dump.c +++ b/libavformat/dump.c @@ -618,6 +618,8 @@ static void dump_stream_format(const AVFormatContext *ic, int i, av_log(NULL, AV_LOG_INFO, " (dependent)"); if (st->disposition & AV_DISPOSITION_STILL_IMAGE) av_log(NULL, AV_LOG_INFO, " (still image)"); + if (st->disposition & AV_DISPOSITION_NON_DIEGETIC) + av_log(NULL, AV_LOG_INFO, " (non-diegetic)"); av_log(NULL, AV_LOG_INFO, "\n"); dump_metadata(NULL, st->metadata, " ");