aboutsummaryrefslogtreecommitdiffstats
path: root/steamvr/patches.toml
blob: 5a677ab98a8701c6c4fd3decbe2050ee5f45fefc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
# SPDX-FileCopyrightText: 2026 Tomasz Kramkowski <tomasz@kramkow.ski>
# SPDX-License-Identifier: CC0-1.0

target = "Beta 2.19.4, build 26793788"

[[targets]]
path = "bin/linux64/vrcompositor"
sha256 = "2916c9993a27d49cdc693a540eefda3ca1d50a569a53edf1bc3b1ea7e19e688e"
edits = [
    # Fix shader descriptor texture array counts (should be 3, not 1) for
    # bindings 9, 17, and 20. Affected shaders:
    # - distort_none_ps
    # - distort_none_ps_layered
    # - distort_panorama_ps
    # - distort_panorama_solid_color_ps
    # - distort_ps_achromatic_nd
    [0x4098d1, "498b5500b80300000089424ceb02"],
    [0x4098e1, "89828c0000008982a4000000eb02"],
    [0x4098f1, "4c8bbd18feffffe9f2200100"],
    [0x41b9e8, "e9e4defeff9090"],
]

[targets.compiled]
sources = ["vrcompositor/vulkan-wait.c", "vrcompositor/facet-wait.c"]

[targets.compiled.imports]
pthread_mutex_lock = 0x1592a0
pthread_mutex_unlock = 0x159690
facet_wait_hook_end = 0x413a07
vulkan_wait_hook_end = 0x434d72
append_wait = 0x46d470

# Add semaphore waits for things that may be eye textures (among other things,
# but it seems harmless).
# This avoids nasty stutters when the renderers sample eye textures before
# they're actually rendered by the GPU. This affects both renderers, which one
# is chosen when isn't totally clear to me.

[[targets.compiled.hooks]]
address = 0x434d6b
length = 7
target = "vulkan_wait_hook"

[[targets.compiled.hooks]]
address = 0x413a00
length = 7
target = "facet_wait_hook"

[[targets]]
path = "drivers/vrlink/bin/linux64/driver_vrlink.so"
sha256 = "7b6a49016989091e36b1276b949aecdb2bf0365353380b12dc7e9b66fb7d797d"
edits = [
    # Ignore stale tracking IDs
    [0x1177c1, "89d02b47084189c6c1e004"],
    [0x1177cc, "0f88ce050000"],
    # Reset tracking and encoding when starting a new streaming session.
    # The tracking ID rejection code above could otherwise drop some packets
    # after a reconnect (since their IDs will start from 0 again).
    # Resetting the encoder eagerly here avoids the high chance it will end up
    # reset due to errors shortly after.
    [0x10eb51, "57488b7f184885ff740feb04"],
    [0x10eb61, "488b076a015eff50285fe99018feff"],
    [0x116701, "4c89a30804000031c0894308c3"],
    [0x116751, "e8abffffff6690"],
    [0x116764, "e8e883ffff"],
]