Skip to content

Commit 4a3f4b1

Browse files
committed
Add default input standardization static var
1 parent bd14404 commit 4a3f4b1

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

Sources/MuxUploadSDK/PublicAPI/MuxUpload.swift

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -207,9 +207,7 @@ public final class MuxUpload : Hashable, Equatable {
207207
videoFileURL: URL,
208208
chunkSize: Int = 8 * 1024 * 1024, // Google recommends at least 8M
209209
retriesPerChunk: Int = 3,
210-
inputStandardization: UploadOptions.InputStandardization = .init(
211-
maximumResolution: UploadOptions.InputStandardization.MaximumResolution.default
212-
),
210+
inputStandardization: UploadOptions.InputStandardization = UploadOptions.InputStandardization.default,
213211
eventTracking: UploadOptions.EventTracking = UploadOptions.EventTracking(optedOut: false)
214212
) {
215213
self.init(

Sources/MuxUploadSDK/PublicAPI/Options/UploadOptions.swift

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,13 @@ public struct UploadOptions {
3333
/// Settings controlling direct upload input standardization
3434
public struct InputStandardization {
3535

36+
public static var `default`: InputStandardization {
37+
InputStandardization(
38+
isEnabled: true,
39+
maximumResolution: .default
40+
)
41+
}
42+
3643
/// If enabled the SDK will attempt to detect
3744
/// non-standard input formats and if so detected
3845
/// will attempt to standardize to a standard input

0 commit comments

Comments
 (0)