protocols: advertise tearing-control + fractional-scale
Add wp_tearing_control_manager_v1 and wp_fractional_scale_manager_v1 as pass-through advertisements for client convenience (games, HiDPI). kick drives a vsynced scene at scale 1.0, so nothing is honoured: a new tearing object is only logged at DEBUG. Bundle the output-power XML locally too (needed by a later commit) and generate the server headers the wlroots headers' quoted includes require.
This commit is contained in:
parent
044c7543bb
commit
c64a10e8d9
4 changed files with 250 additions and 0 deletions
|
|
@ -3365,3 +3365,26 @@ def test_standalone_headless_screencopy_frame(tmp_path):
|
|||
finally:
|
||||
s.close()
|
||||
|
||||
|
||||
def test_standalone_headless_tearing_and_fractional_globals(tmp_path):
|
||||
"""The compositor advertises wp_tearing_control_manager_v1 (games request
|
||||
unthrottled presentation) and wp_fractional_scale_manager_v1 (clients
|
||||
learn a non-integer scale). kick drives a vsynced scene at scale 1.0,
|
||||
so both are pass-through: advertised but nothing honoured."""
|
||||
out = tmp_path / "globals.txt"
|
||||
s = _spawn_standalone({}, "%s --globals-out '%s' '#112233'" % (WL, out))
|
||||
try:
|
||||
deadline = time.monotonic() + 15.0
|
||||
while time.monotonic() < deadline:
|
||||
if out.exists():
|
||||
break
|
||||
time.sleep(0.1)
|
||||
assert out.exists(), "wltest --globals-out never wrote its file"
|
||||
names = {line.split()[0] for line in out.read_text().splitlines()}
|
||||
for want in ("wp_tearing_control_manager_v1",
|
||||
"wp_fractional_scale_manager_v1"):
|
||||
assert want in names, \
|
||||
f"missing global {want}; advertised: {sorted(names)}"
|
||||
finally:
|
||||
s.close()
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue