UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
ChannelMap.h
Go to the documentation of this file.
1// Copyright Epic Games, Inc. All Rights Reserved.
2
3#pragma once
4
5#include "Containers/Array.h"
6#include "HAL/Platform.h"
7
8namespace Audio
9{
10 // Maximum number of channels supported by channel maps (Corresponds to 7.1 format)
11 static constexpr uint32 ChannelMapMaxNumChannels = 8;
12 // Number of channels in a vorbis input (Corresponds to 5.1 with vorbis channel ordering).
13 static constexpr uint32 ChannelMapVorbisNumChannels = 6;
14
17 {
18 // The channel map matrix is in output major order, meaning that adjacent
19 // values increment the output channel index.
20 //
21 // G_In_Om is the gain for input channel (n) and output channel (m).
22 // If there are (N) input channels and (M) output channel, then the channel
23 // map will be in the form:
24 // [
25 // G_I0_O0, G_I0_O1, ... G_I0_OM,
26 // G_I1_O0, G_I1_O1, ... G_I0_OM,
27 // ...
28 // G_IN_O0, G_IN_O1, ... G_I0_OM,
29 // ]
31
32
33 // The channel map matrix is in input major order, meaning that adjacent
34 // values increment the input channel index.
35 //
36 // G_In_Om is the gain for input channel (n) and output channel (m).
37 // If there are (N) input channels and (M) output channel, then the channel
38 // map will be in the form:
39 // [
40 // G_I0_O0, G_I1_O0, ... G_IN_O0,
41 // G_I0_O1, G_I1_O1, ... G_IN_O1,
42 // ...
43 // G_I0_OM, G_I1_OM, ... G_IN_OM,
44 // ]
46 };
47
51 {
52 // The mono channel is split 0.5 left/right
53 Linear,
54
55 // The mono channel is split 0.707 left/right
57
58 // The mono channel is split 1.0 left/right
60 };
61
64 {
65 // Number of channels in the input audio.
67 // Number of channels in the output audio.
69 // Order of gain coefficients in the output channel map.
71 // Method for upmixing mono audio (only used if NumInputChannels == 1)
73 // If true and (NumInputChannels == 1) and the output format has a center channel,
74 // then the mono channel will be routed directly to the center channel.
76 };
77
86
96}
FPlatformTypes::int32 int32
A 32-bit signed integer.
Definition Platform.h:1125
UE_FORCEINLINE_HINT TSharedRef< CastToType, Mode > StaticCastSharedRef(TSharedRef< CastFromType, Mode > const &InSharedRef)
Definition SharedPointer.h:127
uint8_t uint8
Definition binka_ue_file_header.h:8
uint32_t uint32
Definition binka_ue_file_header.h:6
Definition Array.h:670
NO_LOGGING.
Definition AudioMixerPlatformAndroid.cpp:53
bool Create2DChannelMap(const FChannelMapParams &InParams, TArray< float > &OutChannelMap)
Definition ChannelMap.cpp:400
bool CreateVorbis2DChannelMap(int32 InNumOutputChannels, EChannelMapOrder InOrder, TArray< float > &OutVorbisChannelMap)
Definition ChannelMap.cpp:435
EChannelMapMonoUpmixMethod
Definition ChannelMap.h:51
EChannelMapOrder
Definition ChannelMap.h:17
Definition ChannelMap.h:64
int32 NumOutputChannels
Definition ChannelMap.h:68
bool bIsCenterChannelOnly
Definition ChannelMap.h:75
EChannelMapMonoUpmixMethod MonoUpmixMethod
Definition ChannelMap.h:72
int32 NumInputChannels
Definition ChannelMap.h:66
EChannelMapOrder Order
Definition ChannelMap.h:70