-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Enhancement]Improve AudioSession management (#639)
- Loading branch information
1 parent
0fd1452
commit 0e7b406
Showing
48 changed files
with
2,260 additions
and
1,239 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
27 changes: 27 additions & 0 deletions
27
Sources/StreamVideo/Utils/AudioSession/AudioSessionConfiguration.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
// | ||
// Copyright © 2025 Stream.io Inc. All rights reserved. | ||
// | ||
|
||
import AVFoundation | ||
|
||
/// Represents the audio session configuration. | ||
public struct AudioSessionConfiguration: ReflectiveStringConvertible, | ||
Equatable { | ||
/// The audio session category. | ||
var category: AVAudioSession.Category | ||
/// The audio session mode. | ||
var mode: AVAudioSession.Mode | ||
/// The audio session options. | ||
var options: AVAudioSession.CategoryOptions | ||
/// The audio session port override. | ||
var overrideOutputAudioPort: AVAudioSession.PortOverride? | ||
|
||
/// Compares two `AudioSessionConfiguration` instances for equality. | ||
public static func == (lhs: Self, rhs: Self) -> Bool { | ||
lhs.category == rhs.category && | ||
lhs.mode == rhs.mode && | ||
lhs.options.rawValue == rhs.options.rawValue && | ||
lhs.overrideOutputAudioPort?.rawValue == | ||
rhs.overrideOutputAudioPort?.rawValue | ||
} | ||
} |
Oops, something went wrong.