Skip to content

Android: window-origin contract — DP slot set_window_screen_rect + Choreographer poll of getLocationOnScreen #1033

Description

@dfattal

Part of #1031 · ADR-036 D6. Common to Architecture A and C.

A compositor instance weaves into its own window, so it needs that window's on-panel origin
every frame. Android's trap (report F9): a pure window move raises no resize — only a
oneway IWindow.moved — and SurfaceFlinger repositions the layer with the old buffer, so the
interlace phase goes stale for the whole drag.

Runtime:

  • New append-only DP vtable slot set_window_screen_rect(x, y, w, h, display_id) under ADR-020
    (struct_size negotiation; old plug-ins unaffected).
  • Client side: sample View.getLocationOnScreen() from a Choreographer callback. Opt out of
    view-bounds sandboxing
    — OEM OVERRIDE_SANDBOX_VIEW_BOUNDS_APIS makes that call
    window-relative; set PROPERTY_COMPAT_ALLOW_SANDBOXING_VIEW_BOUNDS_APIS=false.
  • Architecture A: call the compositor directly. Architecture C: forward over the existing
    window-metrics IPC channel (multi_compositor_get_window_metrics,
    comp_multi_compositor.c:2076-2090).

Vendor mapping is a separate issue: DisplayXR/displayxr-leia-plugin#150.
ADR-033 is unchanged — this reports geometry; the weaver still owns phase.

Metadata

Metadata

Assignees

No one assigned

    Labels

    androidAndroid platformarchitectureArchitectural design and structural changescompositorCompositor subsystemextensionOpenXR extension work

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions