Screensharing permission denied on Android 13

(#3292) Bug Closed: Fixed mobile video

Reproduction steps

  1. Have a device on Android 13
  2. Try and screenshare
  3. Notice it will fail with permission denied

Observed behaviour

Screensharing does not work.

Build information

Version 1.0.0, Beta 56, Channel Beta, Build 2359, Android 13 (arm64), Device AYN Odin2 Portal, Locale en-US, Push fcm, Flutter 3.47.1, Dart 3.13.1

Platform

Android

Evidence

'[error] | 21:19:10 36ms | [Voice] setScreenShareEnabled failed (enable=true): Unable to getDisplayMedia: Media projections require a foreground service of type ServiceInfo.FOREGROUND_SERVICE_TYPE_MEDIA_PROJECTION Unable to getDisplayMedia: Media projections require a foreground service of type ServiceInfo.FOREGROUND_SERVICE_TYPE_MEDIA_PROJECTION StackTrace: #0 MediaDeviceNative.getDisplayMedia (package:flutter_webrtc/src/native/mediadevices_impl.dart:68) <asynchronous suspension> #1 LocalTrack.createStream (package:livekit_client/src/track/local/local.dart:273) <asynchronous suspension> #2 LocalVideoTrack.createScreenShareTracksWithAudio (package:livekit_client/src/track/local/video.dart:252) <asynchronous suspension> #3 LocalParticipant.setSourceEnabled.<anonymous closure> (package:livekit_client/src/participant/local.dart:841) <asynchronous suspension> #4 SerialRunner.run (package:livekit_client/src/support/serial_runner.dart:45) <asynchronous suspension> #5 VoiceSettingsApplicator.setScreenShareEnabled (package:fluxer_app/features/voice/services/voice_settings_applicator.dart:133) <asynchronous suspension> #6 VoiceSession.toggleSelfStream (package:fluxer_app/features/voice/providers/voice_session_provider.dart:1671) <asynchronous suspension>'

Details

Expected behaviour Screensharing to work on android 13.

Merged posts

These posts were merged into this one. Their comments are now part of the conversation below, marked with where they came from.

Report details

Reproduction steps

  1. Have a device on Android 13
  2. Try and screenshare
  3. Notice it will fail with permission denied

Observed behaviour

Screensharing does not work.

Build information

Version 1.0.0, Beta 56, Channel Beta, Build 2359, Android 13 (arm64), Device AYN Odin2 Portal, Locale en-US, Push fcm, Flutter 3.47.1, Dart 3.13.1

Platform

Android

Evidence

`[error] | 21:19:10 36ms | [Voice] setScreenShareEnabled failed (enable=true): Unable to getDisplayMedia: Media projections require a foreground service of type ServiceInfo.FOREGROUND_SERVICE_TYPE_MEDIA_PROJECTION Unable to getDisplayMedia: Media projections require a foreground service of type ServiceInfo.FOREGROUND_SERVICE_TYPE_MEDIA_PROJECTION StackTrace: #0 MediaDeviceNative.getDisplayMedia (package:flutter_webrtc/src/native/mediadevices_impl.dart:68) <asynchronous suspension> #1 LocalTrack.createStream (package:livekit_client/src/track/local/local.dart:273) <asynchronous suspension> #2 LocalVideoTrack.createScreenShareTracksWithAudio (package:livekit_client/src/track/local/video.dart:252) <asynchronous suspension> #3 LocalParticipant.setSourceEnabled.<anonymous closure> (package:livekit_client/src/participant/local.dart:841) <asynchronous suspension> #4 SerialRunner.run (package:livekit_client/src/support/serial_runner.dart:45) <asynchronous suspension> #5 VoiceSettingsApplicator.setScreenShareEnabled (package:fluxer_app/features/voice/services/voice_settings_applicator.dart:133) <asynchronous suspension> #6 VoiceSession.toggleSelfStream (package:fluxer_app/features/voice/providers/voice_session_provider.dart:1671) <asynchronous suspension>`

Details

Expected behaviour Screensharing to work on android 13.

1 comment

Sign in with Fluxer to comment and vote.
Comment by Fullest
FullestReviewer 1 vote
Status changed from Needs triage to Fixed
This appears to have been fixed at some point since this was initially reported. Cannot reproduce on Version 2026.10.100, Beta 8, Channel Beta, Build 2721, Android 16 (arm64), Device Google Pixel 9a, Locale en-US, Push fcm, Flutter 3.47.7, Dart 3.13.5