@@ -94,6 +94,36 @@ interface AVAudio3DVectorOrientation {
94
94
}
95
95
declare var AVAudio3DVectorOrientation : interop . StructType < AVAudio3DVectorOrientation > ;
96
96
97
+ declare class AVAudioApplication extends NSObject {
98
+
99
+ static alloc ( ) : AVAudioApplication ; // inherited from NSObject
100
+
101
+ static new ( ) : AVAudioApplication ; // inherited from NSObject
102
+
103
+ static requestRecordPermissionWithCompletionHandler ( response : ( p1 : boolean ) => void ) : void ;
104
+
105
+ readonly inputMuted : boolean ;
106
+
107
+ readonly recordPermission : AVAudioApplicationRecordPermission ;
108
+
109
+ static readonly sharedInstance : AVAudioApplication ;
110
+
111
+ setInputMutedError ( muted : boolean ) : boolean ;
112
+ }
113
+
114
+ declare var AVAudioApplicationInputMuteStateChangeNotification : string ;
115
+
116
+ declare var AVAudioApplicationMuteStateKey : string ;
117
+
118
+ declare const enum AVAudioApplicationRecordPermission {
119
+
120
+ Undetermined = 1970168948 ,
121
+
122
+ Denied = 1684369017 ,
123
+
124
+ Granted = 1735552628
125
+ }
126
+
97
127
declare var AVAudioBitRateStrategy_Constant : string ;
98
128
99
129
declare var AVAudioBitRateStrategy_LongTermAverage : string ;
@@ -679,6 +709,8 @@ declare class AVAudioInputNode extends AVAudioIONode implements AVAudioMixing {
679
709
680
710
voiceProcessingInputMuted : boolean ;
681
711
712
+ voiceProcessingOtherAudioDuckingConfiguration : AVAudioVoiceProcessingOtherAudioDuckingConfiguration ;
713
+
682
714
readonly debugDescription : string ; // inherited from NSObjectProtocol
683
715
684
716
readonly description : string ; // inherited from NSObjectProtocol
@@ -736,6 +768,8 @@ declare class AVAudioInputNode extends AVAudioIONode implements AVAudioMixing {
736
768
self ( ) : this;
737
769
738
770
setManualRenderingInputPCMFormatInputBlock ( format : AVAudioFormat , block : ( p1 : number ) => interop . Pointer | interop . Reference < AudioBufferList > ) : boolean ;
771
+
772
+ setMutedSpeechActivityEventListener ( listenerBlock : ( p1 : AVAudioVoiceProcessingSpeechActivityEvent ) => void ) : boolean ;
739
773
}
740
774
741
775
declare class AVAudioMixerNode extends AVAudioNode implements AVAudioMixing {
@@ -1434,6 +1468,8 @@ declare class AVAudioSession extends NSObject {
1434
1468
1435
1469
readonly preferredSampleRate : number ;
1436
1470
1471
+ readonly prefersInterruptionOnRouteDisconnect : boolean ;
1472
+
1437
1473
readonly prefersNoInterruptionsFromSystemAlerts : boolean ;
1438
1474
1439
1475
readonly promptStyle : AVAudioSessionPromptStyle ;
@@ -1494,6 +1530,8 @@ declare class AVAudioSession extends NSObject {
1494
1530
1495
1531
setPreferredSampleRateError ( sampleRate : number ) : boolean ;
1496
1532
1533
+ setPrefersInterruptionOnRouteDisconnectError ( inValue : boolean ) : boolean ;
1534
+
1497
1535
setPrefersNoInterruptionsFromSystemAlertsError ( inValue : boolean ) : boolean ;
1498
1536
1499
1537
setSupportsMultichannelContentError ( inValue : boolean ) : boolean ;
@@ -1614,7 +1652,9 @@ declare const enum AVAudioSessionInterruptionReason {
1614
1652
1615
1653
AppWasSuspended = 1 ,
1616
1654
1617
- BuiltInMicMuted = 2
1655
+ BuiltInMicMuted = 2 ,
1656
+
1657
+ RouteDisconnected = 4
1618
1658
}
1619
1659
1620
1660
declare var AVAudioSessionInterruptionReasonKey : string ;
@@ -1694,6 +1734,8 @@ declare var AVAudioSessionPortBuiltInSpeaker: string;
1694
1734
1695
1735
declare var AVAudioSessionPortCarAudio : string ;
1696
1736
1737
+ declare var AVAudioSessionPortContinuityMicrophone : string ;
1738
+
1697
1739
declare class AVAudioSessionPortDescription extends NSObject {
1698
1740
1699
1741
static alloc ( ) : AVAudioSessionPortDescription ; // inherited from NSObject
@@ -2287,72 +2329,16 @@ declare class AVAudioUnitGenerator extends AVAudioUnit implements AVAudioMixing
2287
2329
self ( ) : this;
2288
2330
}
2289
2331
2290
- declare class AVAudioUnitMIDIInstrument extends AVAudioUnit implements AVAudioMixing {
2332
+ declare class AVAudioUnitMIDIInstrument extends AVAudioUnit {
2291
2333
2292
2334
static alloc ( ) : AVAudioUnitMIDIInstrument ; // inherited from NSObject
2293
2335
2294
2336
static new ( ) : AVAudioUnitMIDIInstrument ; // inherited from NSObject
2295
2337
2296
- readonly debugDescription : string ; // inherited from NSObjectProtocol
2297
-
2298
- readonly description : string ; // inherited from NSObjectProtocol
2299
-
2300
- readonly hash : number ; // inherited from NSObjectProtocol
2301
-
2302
- readonly isProxy : boolean ; // inherited from NSObjectProtocol
2303
-
2304
- obstruction : number ; // inherited from AVAudio3DMixing
2305
-
2306
- occlusion : number ; // inherited from AVAudio3DMixing
2307
-
2308
- pan : number ; // inherited from AVAudioStereoMixing
2309
-
2310
- pointSourceInHeadMode : AVAudio3DMixingPointSourceInHeadMode ; // inherited from AVAudio3DMixing
2311
-
2312
- position : AVAudio3DPoint ; // inherited from AVAudio3DMixing
2313
-
2314
- rate : number ; // inherited from AVAudio3DMixing
2315
-
2316
- renderingAlgorithm : AVAudio3DMixingRenderingAlgorithm ; // inherited from AVAudio3DMixing
2317
-
2318
- reverbBlend : number ; // inherited from AVAudio3DMixing
2319
-
2320
- sourceMode : AVAudio3DMixingSourceMode ; // inherited from AVAudio3DMixing
2321
-
2322
- readonly superclass : typeof NSObject ; // inherited from NSObjectProtocol
2323
-
2324
- volume : number ; // inherited from AVAudioMixing
2325
-
2326
- readonly // inherited from NSObjectProtocol
2327
-
2328
2338
constructor ( o : { audioComponentDescription : AudioComponentDescription ; } ) ;
2329
2339
2330
- class ( ) : typeof NSObject ;
2331
-
2332
- conformsToProtocol ( aProtocol : any /* Protocol */ ) : boolean ;
2333
-
2334
- destinationForMixerBus ( mixer : AVAudioNode , bus : number ) : AVAudioMixingDestination ;
2335
-
2336
2340
initWithAudioComponentDescription ( description : AudioComponentDescription ) : this;
2337
2341
2338
- isEqual ( object : any ) : boolean ;
2339
-
2340
- isKindOfClass ( aClass : typeof NSObject ) : boolean ;
2341
-
2342
- isMemberOfClass ( aClass : typeof NSObject ) : boolean ;
2343
-
2344
- performSelector ( aSelector : string ) : any ;
2345
-
2346
- performSelectorWithObject ( aSelector : string , object : any ) : any ;
2347
-
2348
- performSelectorWithObjectWithObject ( aSelector : string , object1 : any , object2 : any ) : any ;
2349
-
2350
- respondsToSelector ( aSelector : string ) : boolean ;
2351
-
2352
- retainCount ( ) : number ;
2353
-
2354
- self ( ) : this;
2355
-
2356
2342
sendControllerWithValueOnChannel ( controller : number , value : number , channel : number ) : void ;
2357
2343
2358
2344
sendMIDIEventData1 ( midiStatus : number , data1 : number ) : void ;
@@ -2496,6 +2482,30 @@ declare class AVAudioUnitVarispeed extends AVAudioUnitTimeEffect {
2496
2482
rate : number ;
2497
2483
}
2498
2484
2485
+ interface AVAudioVoiceProcessingOtherAudioDuckingConfiguration {
2486
+ enableAdvancedDucking : boolean ;
2487
+ duckingLevel : AVAudioVoiceProcessingOtherAudioDuckingLevel ;
2488
+ }
2489
+ declare var AVAudioVoiceProcessingOtherAudioDuckingConfiguration : interop . StructType < AVAudioVoiceProcessingOtherAudioDuckingConfiguration > ;
2490
+
2491
+ declare const enum AVAudioVoiceProcessingOtherAudioDuckingLevel {
2492
+
2493
+ Default = 0 ,
2494
+
2495
+ Min = 10 ,
2496
+
2497
+ Mid = 20 ,
2498
+
2499
+ Max = 30
2500
+ }
2501
+
2502
+ declare const enum AVAudioVoiceProcessingSpeechActivityEvent {
2503
+
2504
+ Started = 0 ,
2505
+
2506
+ Ended = 1
2507
+ }
2508
+
2499
2509
interface AVBeatRange {
2500
2510
start : number ;
2501
2511
length : number ;
@@ -2943,6 +2953,8 @@ declare const enum AVSpeechBoundary {
2943
2953
Word = 1
2944
2954
}
2945
2955
2956
+ declare var AVSpeechSynthesisAvailableVoicesDidChangeNotification : string ;
2957
+
2946
2958
declare var AVSpeechSynthesisIPANotationAttribute : string ;
2947
2959
2948
2960
declare class AVSpeechSynthesisMarker extends NSObject implements NSCopying , NSSecureCoding {
@@ -2951,25 +2963,49 @@ declare class AVSpeechSynthesisMarker extends NSObject implements NSCopying, NSS
2951
2963
2952
2964
static new ( ) : AVSpeechSynthesisMarker ; // inherited from NSObject
2953
2965
2966
+ bookmarkName : string ;
2967
+
2954
2968
byteSampleOffset : number ;
2955
2969
2956
2970
mark : AVSpeechSynthesisMarkerMark ;
2957
2971
2972
+ phoneme : string ;
2973
+
2958
2974
textRange : NSRange ;
2959
2975
2960
2976
static readonly supportsSecureCoding : boolean ; // inherited from NSSecureCoding
2961
2977
2978
+ constructor ( o : { bookmarkName : string ; atByteSampleOffset : number ; } ) ;
2979
+
2962
2980
constructor ( o : { coder : NSCoder ; } ) ; // inherited from NSCoding
2963
2981
2964
2982
constructor ( o : { markerType : AVSpeechSynthesisMarkerMark ; forTextRange : NSRange ; atByteSampleOffset : number ; } ) ;
2965
2983
2984
+ constructor ( o : { paragraphRange : NSRange ; atByteSampleOffset : number ; } ) ;
2985
+
2986
+ constructor ( o : { phonemeString : string ; atByteSampleOffset : number ; } ) ;
2987
+
2988
+ constructor ( o : { sentenceRange : NSRange ; atByteSampleOffset : number ; } ) ;
2989
+
2990
+ constructor ( o : { wordRange : NSRange ; atByteSampleOffset : number ; } ) ;
2991
+
2966
2992
copyWithZone ( zone : interop . Pointer | interop . Reference < any > ) : any ;
2967
2993
2968
2994
encodeWithCoder ( coder : NSCoder ) : void ;
2969
2995
2996
+ initWithBookmarkNameAtByteSampleOffset ( mark : string , byteSampleOffset : number ) : this;
2997
+
2970
2998
initWithCoder ( coder : NSCoder ) : this;
2971
2999
2972
3000
initWithMarkerTypeForTextRangeAtByteSampleOffset ( type : AVSpeechSynthesisMarkerMark , range : NSRange , byteSampleOffset : number ) : this;
3001
+
3002
+ initWithParagraphRangeAtByteSampleOffset ( range : NSRange , byteSampleOffset : number ) : this;
3003
+
3004
+ initWithPhonemeStringAtByteSampleOffset ( phoneme : string , byteSampleOffset : number ) : this;
3005
+
3006
+ initWithSentenceRangeAtByteSampleOffset ( range : NSRange , byteSampleOffset : number ) : this;
3007
+
3008
+ initWithWordRangeAtByteSampleOffset ( range : NSRange , byteSampleOffset : number ) : this;
2973
3009
}
2974
3010
2975
3011
declare const enum AVSpeechSynthesisMarkerMark {
@@ -2980,7 +3016,20 @@ declare const enum AVSpeechSynthesisMarkerMark {
2980
3016
2981
3017
Sentence = 2 ,
2982
3018
2983
- Paragraph = 3
3019
+ Paragraph = 3 ,
3020
+
3021
+ Bookmark = 4
3022
+ }
3023
+
3024
+ declare const enum AVSpeechSynthesisPersonalVoiceAuthorizationStatus {
3025
+
3026
+ NotDetermined = 0 ,
3027
+
3028
+ Denied = 1 ,
3029
+
3030
+ Unsupported = 2 ,
3031
+
3032
+ Authorized = 3
2984
3033
}
2985
3034
2986
3035
declare class AVSpeechSynthesisProviderAudioUnit extends AUAudioUnit {
@@ -3088,6 +3137,8 @@ declare class AVSpeechSynthesisVoice extends NSObject implements NSSecureCoding
3088
3137
3089
3138
readonly quality : AVSpeechSynthesisVoiceQuality ;
3090
3139
3140
+ readonly voiceTraits : AVSpeechSynthesisVoiceTraits ;
3141
+
3091
3142
static readonly supportsSecureCoding : boolean ; // inherited from NSSecureCoding
3092
3143
3093
3144
constructor ( o : { coder : NSCoder ; } ) ; // inherited from NSCoding
@@ -3117,12 +3168,23 @@ declare const enum AVSpeechSynthesisVoiceQuality {
3117
3168
Premium = 3
3118
3169
}
3119
3170
3171
+ declare const enum AVSpeechSynthesisVoiceTraits {
3172
+
3173
+ None = 0 ,
3174
+
3175
+ IsNoveltyVoice = 1 ,
3176
+
3177
+ IsPersonalVoice = 2
3178
+ }
3179
+
3120
3180
declare class AVSpeechSynthesizer extends NSObject {
3121
3181
3122
3182
static alloc ( ) : AVSpeechSynthesizer ; // inherited from NSObject
3123
3183
3124
3184
static new ( ) : AVSpeechSynthesizer ; // inherited from NSObject
3125
3185
3186
+ static requestPersonalVoiceAuthorizationWithCompletionHandler ( handler : ( p1 : AVSpeechSynthesisPersonalVoiceAuthorizationStatus ) => void ) : void ;
3187
+
3126
3188
delegate : AVSpeechSynthesizerDelegate ;
3127
3189
3128
3190
mixToTelephonyUplink : boolean ;
@@ -3135,6 +3197,8 @@ declare class AVSpeechSynthesizer extends NSObject {
3135
3197
3136
3198
usesApplicationAudioSession : boolean ;
3137
3199
3200
+ static readonly personalVoiceAuthorizationStatus : AVSpeechSynthesisPersonalVoiceAuthorizationStatus ;
3201
+
3138
3202
continueSpeaking ( ) : boolean ;
3139
3203
3140
3204
pauseSpeakingAtBoundary ( boundary : AVSpeechBoundary ) : boolean ;
@@ -3160,6 +3224,8 @@ interface AVSpeechSynthesizerDelegate extends NSObjectProtocol {
3160
3224
3161
3225
speechSynthesizerDidStartSpeechUtterance ?( synthesizer : AVSpeechSynthesizer , utterance : AVSpeechUtterance ) : void ;
3162
3226
3227
+ speechSynthesizerWillSpeakMarkerUtterance ?( synthesizer : AVSpeechSynthesizer , marker : AVSpeechSynthesisMarker , utterance : AVSpeechUtterance ) : void ;
3228
+
3163
3229
speechSynthesizerWillSpeakRangeOfSpeechStringUtterance ?( synthesizer : AVSpeechSynthesizer , characterRange : NSRange , utterance : AVSpeechUtterance ) : void ;
3164
3230
}
3165
3231
declare var AVSpeechSynthesizerDelegate : {
0 commit comments