Describe the problem
When E2EE is enabled in the JS SDK, Opus RED is forced off:
|
const req = new AddTrackRequest({ |
|
// get local track id for use during publishing |
|
cid: track.mediaStreamTrack.id, |
|
name: opts.name, |
|
type: Track.kindToProto(track.kind), |
|
muted: track.isMuted, |
|
source: Track.sourceToProto(track.source), |
|
disableDtx, |
|
encryption: this.encryptionType, |
|
stereo: isStereo, |
|
disableRed: this.isE2EEEnabled || !(opts.red ?? true), |
|
stream: opts?.stream, |
|
backupCodecPolicy: opts?.backupCodecPolicy as BackupCodecPolicy, |
|
audioFeatures, |
|
}); |
|
|
Android/iOS do not seem to force RED off for E2EE:
Android: https://github.com/livekit/client-sdk-android/blob/8f7a8a6d129ab1dc23f2e22d998b7498f58d8955/livekit-android-sdk/src/main/java/io/livekit/android/room/participant/LocalParticipant.kt#L459-L470
iOS: https://github.com/livekit/client-sdk-swift/blob/d1114653257df97122b565f795888db360dffbc5/Sources/LiveKit/Participant/LocalParticipant.swift#L620-L643
This inconsistency is confusing for cross-platform apps.
Describe the proposed solution
Please either:
- allow RED with E2EE in JS (if feasible), or
- document why RED must be disabled with E2EE and apply the same behavior across SDKs.
Alternatives considered
Keep current behavior but clearly document per-SDK differences.
Importance
nice to have
Additional Information
Related PR: #858
Describe the problem
When E2EE is enabled in the JS SDK, Opus RED is forced off:
client-sdk-js/src/room/participant/LocalParticipant.ts
Lines 1096 to 1111 in 6b1d69c
Android/iOS do not seem to force RED off for E2EE:
Android: https://github.com/livekit/client-sdk-android/blob/8f7a8a6d129ab1dc23f2e22d998b7498f58d8955/livekit-android-sdk/src/main/java/io/livekit/android/room/participant/LocalParticipant.kt#L459-L470
iOS: https://github.com/livekit/client-sdk-swift/blob/d1114653257df97122b565f795888db360dffbc5/Sources/LiveKit/Participant/LocalParticipant.swift#L620-L643
This inconsistency is confusing for cross-platform apps.
Describe the proposed solution
Please either:
Alternatives considered
Keep current behavior but clearly document per-SDK differences.
Importance
nice to have
Additional Information
Related PR: #858