Skip to content

Commit 863c31f

Browse files
authored
[CoreAudioTypes] Implement Xcode 16.0 beta 1-6 changes. (#21019)
The capitalization of these new enum members matches the capitalization of other MPEG* enum members in the same enum. Note: there were no changes in beta 2, beta 4, beta 5 or beta 6.
1 parent 0cd9749 commit 863c31f

File tree

2 files changed

+61
-1
lines changed

2 files changed

+61
-1
lines changed

src/AudioToolbox/AudioType.cs

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@
3535
using System;
3636
using System.Text;
3737
using System.Collections.Generic;
38+
using System.ComponentModel;
3839
using System.Runtime.CompilerServices;
3940
using System.Runtime.InteropServices;
4041
using System.Diagnostics;
@@ -81,7 +82,13 @@ public enum AudioFormatType : uint { // UInt32 in AudioStreamBasicDescription --
8182
DVIIntelIMA = 0x6d730011,
8283
MicrosoftGSM = 0x6d730031,
8384
AES3 = 0x61657333, // 'aes3'
85+
#if !XAMCORE_5_0
86+
[Obsolete ("Use 'EnhancedAC3' instead.")]
87+
[EditorBrowsable (EditorBrowsableState.Never)]
8488
EnhancedAES3 = 0x65632d33, // 'ec-3'
89+
#endif
90+
/// <summary>Enhanced AC-3.</summary>
91+
EnhancedAC3 = 0x65632d33, // 'ec-3'
8592
Flac = 0x666c6163, // 'flac'
8693
#if NET
8794
[SupportedOSPlatform ("ios13.0")]
@@ -95,6 +102,16 @@ public enum AudioFormatType : uint { // UInt32 in AudioStreamBasicDescription --
95102
#endif
96103
LatmInLoas = 0x6c6f6173, // 'loas'
97104
Opus = 0x6f707573, // 'opus'
105+
/// <summary>Apple Positional Audio Codec.</summary>
106+
#if NET
107+
[SupportedOSPlatform ("ios18.0")]
108+
[SupportedOSPlatform ("macos15.0")]
109+
[SupportedOSPlatform ("tvos18.0")]
110+
[SupportedOSPlatform ("maccatalyst18.0")]
111+
#else
112+
[NoWatch, iOS (18, 0), TV (18, 0), MacCatalyst (18, 0), Mac (15, 0)]
113+
#endif
114+
Apac = 0x61706163, // 'apac'
98115
}
99116

100117
[Flags]
@@ -921,6 +938,46 @@ public enum AudioChannelLayoutTag : uint { // UInt32 AudioChannelLayoutTag
921938
#endif
922939
Ogg_7_1 = (215U << 16) | 8,
923940

941+
#if NET
942+
[SupportedOSPlatform ("ios18.0")]
943+
[SupportedOSPlatform ("maccatalyst18.0")]
944+
[SupportedOSPlatform ("macos15.0")]
945+
[SupportedOSPlatform ("tvos18.0")]
946+
#else
947+
[Watch (11, 0), TV (18, 0), Mac (15, 0), iOS (18, 0), MacCatalyst (18, 0)]
948+
#endif
949+
MPEG_5_0_E = (216U << 16) | 5,
950+
951+
#if NET
952+
[SupportedOSPlatform ("ios18.0")]
953+
[SupportedOSPlatform ("maccatalyst18.0")]
954+
[SupportedOSPlatform ("macos15.0")]
955+
[SupportedOSPlatform ("tvos18.0")]
956+
#else
957+
[Watch (11, 0), TV (18, 0), Mac (15, 0), iOS (18, 0), MacCatalyst (18, 0)]
958+
#endif
959+
MPEG_5_1_E = (217U << 16) | 6,
960+
961+
#if NET
962+
[SupportedOSPlatform ("ios18.0")]
963+
[SupportedOSPlatform ("maccatalyst18.0")]
964+
[SupportedOSPlatform ("macos15.0")]
965+
[SupportedOSPlatform ("tvos18.0")]
966+
#else
967+
[Watch (11, 0), TV (18, 0), Mac (15, 0), iOS (18, 0), MacCatalyst (18, 0)]
968+
#endif
969+
MPEG_6_1_B = (218U << 16) | 7,
970+
971+
#if NET
972+
[SupportedOSPlatform ("ios18.0")]
973+
[SupportedOSPlatform ("maccatalyst18.0")]
974+
[SupportedOSPlatform ("macos15.0")]
975+
[SupportedOSPlatform ("tvos18.0")]
976+
#else
977+
[Watch (11, 0), TV (18, 0), Mac (15, 0), iOS (18, 0), MacCatalyst (18, 0)]
978+
#endif
979+
MPEG_7_1_D = (219U << 16) | 8,
980+
924981
Unknown = 0xFFFF0000 // needs to be ORed with the actual number of channels
925982
}
926983

tests/cecil-tests/Documentation.KnownFailures.txt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3458,14 +3458,18 @@ F:AudioToolbox.AudioChannelLayoutTag.MPEG_5_0_A
34583458
F:AudioToolbox.AudioChannelLayoutTag.MPEG_5_0_B
34593459
F:AudioToolbox.AudioChannelLayoutTag.MPEG_5_0_C
34603460
F:AudioToolbox.AudioChannelLayoutTag.MPEG_5_0_D
3461+
F:AudioToolbox.AudioChannelLayoutTag.MPEG_5_0_E
34613462
F:AudioToolbox.AudioChannelLayoutTag.MPEG_5_1_A
34623463
F:AudioToolbox.AudioChannelLayoutTag.MPEG_5_1_B
34633464
F:AudioToolbox.AudioChannelLayoutTag.MPEG_5_1_C
34643465
F:AudioToolbox.AudioChannelLayoutTag.MPEG_5_1_D
3466+
F:AudioToolbox.AudioChannelLayoutTag.MPEG_5_1_E
34653467
F:AudioToolbox.AudioChannelLayoutTag.MPEG_6_1_A
3468+
F:AudioToolbox.AudioChannelLayoutTag.MPEG_6_1_B
34663469
F:AudioToolbox.AudioChannelLayoutTag.MPEG_7_1_A
34673470
F:AudioToolbox.AudioChannelLayoutTag.MPEG_7_1_B
34683471
F:AudioToolbox.AudioChannelLayoutTag.MPEG_7_1_C
3472+
F:AudioToolbox.AudioChannelLayoutTag.MPEG_7_1_D
34693473
F:AudioToolbox.AudioChannelLayoutTag.Octagonal
34703474
F:AudioToolbox.AudioChannelLayoutTag.Ogg_3_0
34713475
F:AudioToolbox.AudioChannelLayoutTag.Ogg_4_0
@@ -3742,7 +3746,6 @@ F:AudioToolbox.AudioFormatType.AppleLossless
37423746
F:AudioToolbox.AudioFormatType.Audible
37433747
F:AudioToolbox.AudioFormatType.CAC3
37443748
F:AudioToolbox.AudioFormatType.DVIIntelIMA
3745-
F:AudioToolbox.AudioFormatType.EnhancedAES3
37463749
F:AudioToolbox.AudioFormatType.Flac
37473750
F:AudioToolbox.AudioFormatType.iLBC
37483751
F:AudioToolbox.AudioFormatType.LatmInLoas

0 commit comments

Comments
 (0)