From patchwork Thu Jan 13 01:50:11 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: James Almer X-Patchwork-Id: 33334 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a6b:cd86:0:0:0:0:0 with SMTP id d128csp18255iog; Wed, 12 Jan 2022 18:02:24 -0800 (PST) X-Google-Smtp-Source: ABdhPJwWIuRObvAbMa0HoRAzzCyjXvR7j68esxhKm712o5is3VlSAtd0g6pcuxgK/wNlVIeBLs5Q X-Received: by 2002:a17:907:9805:: with SMTP id ji5mr699064ejc.271.1642039344299; Wed, 12 Jan 2022 18:02:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1642039344; cv=none; d=google.com; s=arc-20160816; b=j0quJhFXDohLKj4PhCjfbbvyclWNoiTAlNmy12EzC2spMgJ4Xg+JG8ZoGbd8Wo6M9M u5iHAKC2c0spHp6H4Wh/KLzaDjpGVGddW1s/JqQatgECHzgnaa5DAaZLE88FbaY7T9/B kJj6wz5ZM78Lw6QG1H5K2jtK4PpihvsFClSWGgIEy1qMNHc01k8UKwlzUceHHXlRs5Wx +m6UphWv0WPf4TtQlWvH8pxgVdhJnDJwt7Rpg+Oo+uDFvTBySTHoTDd29Z7g5athVq4a 73Pe0Oz/iN2vnGhLqQFakwkyuqPCb7mh77nZlriOZYVW8EoL1a2Wr+beFveenTTfVGks 4adA== 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=ni3qoILmytZuPhuiRcPKt8i9N3y8pyFNrgc1j6aJePQ=; b=QIZMTghr10kFVTF9Y8T8BMw6MsdcQ6E3Ui9YLPSqHtnDRJFppvxKyIjneIW2FN5Yt5 RBvQApeLBsFKYs1KLXXm1tyl1hTB4vWaj4GTK9lSs849WyhU1ns9+y7L68PWpkt/a9W2 TU8m34vbT3HIRsfguuFVnfpLKxT8+yisO2ChGRGSCZxkgecQv6x0NCiUovO2OC610cMg 9U6W2ojgmM9ZajIgOQ1Nwa4yuV/qoujObbqFFHk+OgiFe5itFkAwm/MqL9jFMbVH0Ab6 Hu1vUTv9zKIPq2Bhl5wRJMWx+9jO7zna8wczlslVEgVuIc9jkhVMeEW6MdaOCt2zymS2 ZcsA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20210112 header.b=Akgk3Hk5; 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 cs21si738424ejc.506.2022.01.12.18.02.23; Wed, 12 Jan 2022 18:02:24 -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=Akgk3Hk5; 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 D643868B0D6; Thu, 13 Jan 2022 03:53:03 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mail-qt1-f171.google.com (mail-qt1-f171.google.com [209.85.160.171]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id AB1E268B0B8 for ; Thu, 13 Jan 2022 03:53:00 +0200 (EET) Received: by mail-qt1-f171.google.com with SMTP id q14so5300606qtx.10 for ; Wed, 12 Jan 2022 17:53:00 -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=veXABjlFttR/9y66ufp6cpinTaGC+F09pLeaqYh+6/Q=; b=Akgk3Hk5kPeNrIYodeocbN5keRmazIo9d6bA7AHVKT3CNSeGIpf5MsBC1PjghscU+e 44Cm0rqm52vi5O78DBy8WU/0zd6IK+LBWKVKMI5rSQP6EiBqID2ti/WzjOWWQbIGrjFv zsyceNIzzsP0yhiidWOsOyuPVX/fo51cYG49eTOh4Uo56lgiYg1cJGPtw58Tyutvnknk myAHO7jXvZ8ePhgjzyEeGWvHa5L6CK5PGJ2A+kI74J8S3ksfWF+s6BvHKvdrHqVHc1hO U2I3PLMxYKq62dTo2yy4LRmTTwRDu9VHvQVoDWRNz77PNHM13ZUldsv/4rciFFYdOogX 7xPg== 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=veXABjlFttR/9y66ufp6cpinTaGC+F09pLeaqYh+6/Q=; b=yZpNahqfnleFATcErZbAxzS/Z6yHxpONFGL3A5Fr4nGE0aYO48OFjtB9ZTZ2G0UJZD ZTloJioOwKMWF1GpxoDhaPuTrNKO+03+5GXPLJbjf8Vqs+ECHJVvIOE8wWKc7Qwz+LSF E6cb2wOH7zNSllz3AvBP7gSsEvkG8gYHNTDfsdYJLwPGatPI9FaQucH7rW0OOfn80rMf CAzVK1HIvPYN+ITAFfJEKSTm+Fbvu98ptvXsXZQxs0raLlRYK58TbN2344C4ikzgzOLl xfsVFsLWjhAXbBq96N75ENNGIQV2ew2vyvpHeWIELsbqdE6X6IT4xHbS4il6sPzmNsKr 9Gww== X-Gm-Message-State: AOAM531kx2sykzRINYNAjiQTnY50nyIiGYm5eUaGf7UXagJnrOLJew0W zd+rnePVdOgP27faUTkIQHJJr2HxFtI= X-Received: by 2002:a05:622a:2ca:: with SMTP id a10mr1991726qtx.483.1642038779015; Wed, 12 Jan 2022 17:52:59 -0800 (PST) Received: from localhost.localdomain ([186.136.131.95]) by smtp.gmail.com with ESMTPSA id i21sm1204710qti.31.2022.01.12.17.52.58 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 12 Jan 2022 17:52:58 -0800 (PST) From: James Almer To: ffmpeg-devel@ffmpeg.org Date: Wed, 12 Jan 2022 22:50:11 -0300 Message-Id: <20220113015101.4-50-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 049/281] dtshddec: convert to new channel layout API 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: yi055qu3YjFI From: Anton Khirnov Signed-off-by: James Almer --- libavformat/dtshddec.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libavformat/dtshddec.c b/libavformat/dtshddec.c index b84588af7c..a3b3b92055 100644 --- a/libavformat/dtshddec.c +++ b/libavformat/dtshddec.c @@ -104,7 +104,8 @@ static int dtshd_read_header(AVFormatContext *s) duration *= avio_rb16(pb); // samples_per_frames st->duration = duration; avio_skip(pb, 5); - st->codecpar->channels = ff_dca_count_chs_for_mask(avio_rb16(pb)); + st->codecpar->ch_layout.order = AV_CHANNEL_ORDER_UNSPEC; + st->codecpar->ch_layout.nb_channels = ff_dca_count_chs_for_mask(avio_rb16(pb)); st->codecpar->initial_padding = avio_rb16(pb); avio_skip(pb, chunk_size - 21); break;