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 A032242D17 for ; Thu, 13 Jan 2022 02:04:01 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 2A85068B15B; Thu, 13 Jan 2022 03:53:11 +0200 (EET) Received: from mail-qk1-f180.google.com (mail-qk1-f180.google.com [209.85.222.180]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id D37CE68B143 for ; Thu, 13 Jan 2022 03:53:08 +0200 (EET) Received: by mail-qk1-f180.google.com with SMTP id e25so5527404qkl.12 for ; Wed, 12 Jan 2022 17:53:08 -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=q1HwASJgMwjPyPOVaQnlABJl2cjXfvH1aLDekAY3o68=; b=i7DZ4+LauYRjru9INZ9DMX+n0m1FXczeY76fvJaW2gBYqRon4ZoKOkMh6EZYAbKMvM fXHVEJtm5fnCQ5mdGedSLOV+XN26mV5ixnPutSioRe8KZL7RahKoTClqugFENtcOFIPr QyN1zZvZW3NICm7XZGwVaJX0eRSVeDV9WoVk8FAH4yOyrJUGDk6uIi+NFevz+DGl+Yfr ZX0HprRXMTMqemestKLUYycxSCpi9D0H9TPeAT98P2ew9LS58UT66TTfQHxT7FnJODHb rxWdsziLpgEyYpE/4lb2cV1LCtQzK7RURMkDhxHHu29mhI6CYFJiHZPcepnT2blpAKO3 mBGw== 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=q1HwASJgMwjPyPOVaQnlABJl2cjXfvH1aLDekAY3o68=; b=0/NmpyIhJX5wAvX+c9Dba0t60H/ft0qQ9lddp+jTiFUBsiNXtXg6XNLmCeXG7QfQrT wzVqSUuivQ0WS3ymfRNEPQUizmJ5fKX/siQI2PC9y00qJia3DE3Ubqs6x6ZNy+0vDinp skBQU0H6Qtgf/AJ5VQN1I8y9e+iZLo21QIcoUquhlSj7ACJa4ejLMLgcOMD9Oi4MAruf p2Hwl/c51HLC4MzdUCnnNsOMI4trIx3Dpy5Z9vW4ldYr4sZSMj9jHm7agHdnVqRzkbO5 KkkxHpQIthF7PyxFalolhyglSqwOtEyY0HOYO30jDTRkj98v4Y5wsIWU0e4wNNzGnkbT 4KNA== X-Gm-Message-State: AOAM531Th3aAWbwts0dnvCaYXJk9Me47QwAmRapXJsmGhzdvOcECO3qy UQUh/Z9Wfz6fEbuoDG5KpOqYIdzCrYI= X-Google-Smtp-Source: ABdhPJxZT2AvpA8ZhhZ1TET8A4sv4zatMFscIpcGjiNq5YJa23iZq2IYvZaf4FetsK1U4lsWuN9bAw== X-Received: by 2002:a05:620a:2489:: with SMTP id i9mr1774433qkn.601.1642038787491; Wed, 12 Jan 2022 17:53:07 -0800 (PST) Received: from localhost.localdomain ([186.136.131.95]) by smtp.gmail.com with ESMTPSA id i21sm1204710qti.31.2022.01.12.17.53.06 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 12 Jan 2022 17:53:07 -0800 (PST) From: James Almer To: ffmpeg-devel@ffmpeg.org Date: Wed, 12 Jan 2022 22:50:18 -0300 Message-Id: <20220113015101.4-57-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 056/281] electronicarts: 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 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: From: Vittorio Giovara Signed-off-by: Vittorio Giovara Signed-off-by: James Almer --- libavformat/electronicarts.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/libavformat/electronicarts.c b/libavformat/electronicarts.c index 2fb09b34ca..811f8705e5 100644 --- a/libavformat/electronicarts.c +++ b/libavformat/electronicarts.c @@ -551,13 +551,14 @@ static int ea_read_header(AVFormatContext *s) st->codecpar->codec_type = AVMEDIA_TYPE_AUDIO; st->codecpar->codec_id = ea->audio_codec; st->codecpar->codec_tag = 0; /* no tag */ - st->codecpar->channels = ea->num_channels; + st->codecpar->ch_layout.order = AV_CHANNEL_ORDER_UNSPEC; + st->codecpar->ch_layout.nb_channels = ea->num_channels; st->codecpar->sample_rate = ea->sample_rate; st->codecpar->bits_per_coded_sample = ea->bytes * 8; - st->codecpar->bit_rate = (int64_t)st->codecpar->channels * + st->codecpar->bit_rate = (int64_t)ea->num_channels * st->codecpar->sample_rate * st->codecpar->bits_per_coded_sample / 4; - st->codecpar->block_align = st->codecpar->channels * + st->codecpar->block_align = ea->num_channels * st->codecpar->bits_per_coded_sample; ea->audio_stream_index = st->index; st->start_time = 0; -- 2.34.1 _______________________________________________ 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".