Schermspiegeling
Controleer app.capabilities voor functieondersteuning en app.access plus hostrechten voor autorisatie. Voorbeelden gebruiken synthetische waarden; vervang paden, ID’s, invoer en filters vóór aanroepen.
Typedefinities
type Subscription {
screenMirrorState: MirrorState!
screenMirrorVideoCodec: MirrorCodecConfiguration
screenMirrorAudioGranted: Boolean!
}
type Mutation {
openAccessibilitySettings: Boolean!
requestScreenMirrorAudio: Boolean!
requestScreenMirrorKeyFrame: Boolean!
startScreenMirror(audio: Boolean!): Boolean!
stopScreenMirror: Boolean!
updateScreenMirrorQuality(mode: ScreenMirrorMode!): Boolean!
}
type Query {
isScreenMirroring: Boolean!
screenMirrorControlEnabled: Boolean!
screenMirrorQuality: ScreenMirrorQuality!
screenMirrorVideoCodec: ScreenMirrorVideoCodec
}
type MirrorCodecConfiguration {
annexB: String!
}
type MirrorState {
running: Boolean!
}
enum ScreenMirrorMode {
HD
SMOOTH
}
type ScreenMirrorQuality {
mode: ScreenMirrorMode!
resolution: Int!
}
type ScreenMirrorVideoCodec {
annexB: String!
keyFrame: String
}Bewerkingen
screenMirrorState
De huidige schermspiegelingsstatus lezen.
subscription screenMirrorState {
screenMirrorState { running }
}screenMirrorVideoCodec
Ontvang updates van de videocodecconfiguratie van de schermspiegelingssessie.
subscription screenMirrorVideoCodec {
screenMirrorVideoCodec { annexB }
}screenMirrorAudioGranted
Een melding ontvangen dat audiomachtiging voor schermspiegeling is verleend.
subscription screenMirrorAudioGranted {
screenMirrorAudioGranted
}openAccessibilitySettings
Het scherm met Android-toegankelijkheidsinstellingen op het apparaat openen. Vereist voordat sendScreenMirrorControl gebaren kan versturen.
mutation openAccessibilitySettings {
openAccessibilitySettings
}requestScreenMirrorAudio
Microfoonmachtiging voor schermspiegelingsaudio aanvragen. Geeft true terug als deze al is verleend, anders false en opent een machtigingsdialoog.
# Returns false when the device has not granted RECORD_AUDIO yet; the
# platform asks for it and the caller retries.
mutation requestScreenMirrorAudio {
requestScreenMirrorAudio
}requestScreenMirrorKeyFrame
Een nieuw sleutelframe van de actieve schermspiegelingsvideo-encoder aanvragen.
mutation requestScreenMirrorKeyFrame {
requestScreenMirrorKeyFrame
}startScreenMirror
Een schermspiegelingssessie starten. Geef audio=true op om ook apparaataudio te streamen (vereist de machtiging RECORD_AUDIO).
mutation startScreenMirror($audio: Boolean!) {
startScreenMirror(audio: $audio)
}stopScreenMirror
De actieve schermspiegelingssessie stoppen.
mutation stopScreenMirror {
stopScreenMirror
}updateScreenMirrorQuality
De kwaliteitsvoorinstelling voor schermspiegeling instellen.
mutation updateScreenMirrorQuality($mode: ScreenMirrorMode!) {
updateScreenMirrorQuality(mode: $mode)
}isScreenMirroring
Controleren of er een actieve schermspiegelingssessie is.
query isScreenMirroring {
isScreenMirroring
}screenMirrorControlEnabled
Geeft true terug als de toegankelijkheidsservice van PlainApp is ingeschakeld en gebaren kan versturen.
query screenMirrorControlEnabled {
screenMirrorControlEnabled
}screenMirrorQuality
De huidige kwaliteitsvoorinstelling van de spiegeling ophalen.
query screenMirrorQuality {
screenMirrorQuality { mode resolution }
}screenMirrorVideoCodec
De videocodec van de huidige/laatste spiegelingssessie ophalen.
# Null while the pipeline has not published its codec configuration.
query screenMirrorVideoCodec {
screenMirrorVideoCodec { annexB keyFrame }
}