Repository navigation
Batman: Arkham Knight on Android: Turnip road fixes (tile pass one lane, road markings flush, decal blinking) - #657
tapionallanaire wants to merge 11 commits into
Conversation
… in its note - android/app/gradle.properties: 0100ACD0163D0000 in nxGames. - The note: Prepare and the opening on a Galaxy S24 Ultra with Turnip Gen8 V39 at 30 fps; the 1.0.5 update is a whole-game patch over a stub base.
…as one lane Light-grey 16-pixel squares on roads and kerbs (the wet layer missing tile by tile) on a Galaxy S24 Ultra with Turnip Gen8 V39: the tile pass 752e5bf8b7496d94 and its helper da62b52f4641ad83 give wrong per-tile results there. As one-invocation subgroups they draw clean. subgroup_one_lane rows, the DM_VK_ONE_LANE option, recommended on Turnip (driver.id=18).
… fix)
Dark stair-stepped 16-pixel blocks over the road markings on Turnip, changing as
the view moves (S24 Ultra, Turnip Gen8 V39; Odin 2, Turnip v27). The road decals
of the G-buffer pass reconstruct their position from the depth the pass's earlier
draws wrote; painted from inside the decal, that depth held the road only in some
16-pixel tiles, while the lighting pass later read it whole. Ending the pass with
a full barrier before the decals did not change it; TU_DEBUG=flushall did, at the
same 30 fps (syncdraw alone did not).
A game option DM_VK_TU_FLUSHALL ("Road markings fix"), recommended on Turnip:
the launcher passes TU_DEBUG=flushall with it, since Turnip reads TU_DEBUG once at
the first Vulkan device of the process (the readiness check's). Other drivers
ignore it. Replaces the reverted skip_layers rows, which dropped two decals and
left the others' blocks.
…g fix) The game hides road decals while their samples-passed reports read 0; on Turnip about 9 of 11 reports a frame read 0 and the markings switch on and off with the camera still. A DM_VK_NO_OCCLUSION option (DM_VK_OCCLUSION=0) keeps them drawn; recommended on Turnip.
…ce log says what TU_DEBUG Turnip got readiness.tsv (status bring-up) puts the profile in nxGames (test_android_games). docs/env_switches.tsv rows for DM_VK_NO_OCCLUSION and DM_VK_TU_FLUSHALL; the device creation logs 'DM_VK_TU_FLUSHALL: TU_DEBUG=...' on Turnip, so the option can be checked in a game's log.
…ory too (dark squares on an Adreno 740) On an Odin 2 (Adreno 740, Turnip v27.0.0-R1 and Gen8 V39) TU_DEBUG=flushall alone left dark 16-pixel squares on roads that blink between frames; TU_DEBUG=flushall,sysmem clears them. DM_VK_TU_FLUSHALL now sets both.
|
Update: on an Adreno 740 (Odin 2, Turnip v27.0.0-R1 and Gen8 V39), |
…BWC (squares at a crossing on an Adreno 740)
|
Further update: |
…wned recommended The game's 30 is its window's present interval 2 (main+0xb6ce70). Its engine limit, UGameEngine::GetMaxTickRate (main+0x1283dd4), returns GEngine+0x884 while vsync is on; a fpslocker target_f32 row writes the chosen limit there each frame. The time update steps by the measured elapsed time. fps_limit_present offers Game owned and 20 to 60 fps; thermal_cap holds 30 on a hot phone. Game owned is recommended on every phone (the GPU takes 22-25 ms a frame docked), for which a recommend row's fps_cap=own now means Game owned on the frame limit list too (Recommend.cap, build.gradle, recommend.py), as dm/games/README.md already documents. The game's other recommend rows cite README.md.
|
Added experimental frame limits up to 60 fps (f90f93e), with Game owned (the game's own 30) recommended.
|
Decals that test depth without writing it sampled the depth attachment the G-buffer draws before them wrote in the same pass, with no barrier between; on Turnip they read depth its cache had not written back, losing fixed 32x16-pixel blocks (Batman: Arkham Knight's road markings, also blinking and grey squares). The pass now notes its depth writes (R.dwritten) and ends first, so its full barrier makes them visible. Every game; DM_VK_DEPTH_READ_END=0 turns it off. 60 fps, GPU 5-9 ms on an Adreno 840, against 16-18 ms with upstream PR igawa6#657's TU_DEBUG workaround. Also: a cube map left in a 3D slot reads as zeros like a 2D texture there.
…nly (sysmem, nolrz and noubwc drew squares on an Adreno 740)
|
Correction to the Adreno 740 note (86fdb79): the road markings fix sets |
Batman: Arkham Knight 1.0.5 on Android, with fixes for three Turnip rendering problems on roads. Played on a Galaxy S24 Ultra (Adreno 750, Turnip Gen8 V39) in the Peanuts app: Prepare from a
.nupof 1.0.5, the opening, and Gotham's streets with clean road markings at 30 fps.Changes
nxGames, with areadiness.tsvstatus row (bring-up) and an Android section in its README.DM_VK_ONE_LANE, recommended ondriver.id=18). The tile pass (compute752e5bf8b7496d94) and its helper (da62b52f4641ad83) give wrong per-tile results with 64-lane subgroups on Turnip.subgroup_one_lanerows run their subgroup operations as one-invocation subgroups. They apply on Qualcomm's driver by default, and the option enables them on any driver.DM_VK_TU_FLUSHALL, recommended on Turnip).103569496bd29d04and five more) read the depth the G-buffer pass's earlier draws wrote. At that point Turnip had written it only in some 16-pixel tiles.TU_DEBUG=flushalldraws them clean at the same 30 fps. The launcher adds that line for the option (GameActivity), because Turnip readsTU_DEBUGonly once, at the first Vulkan device of the process. An env.txtTU_DEBUGline still wins. Device creation logsDM_VK_TU_FLUSHALL: TU_DEBUG=…so the option can be checked in a game's log.syncdrawalone, LRZ / sysmem / UBWC off, a full barrier before the decals, the depth test off for them, and the decal shaders' NaN guards, kills and mip level. The exact missing flush isn't narrowed down yet; until it is, this option is the workaround.DM_VK_NO_OCCLUSION, recommended on Turnip).DM_VK_OCCLUSION=0) the decals stay drawn, at the same 30 fps. The option is that switch as aKEY=1line;DM_VK_OCCLUSION, when set, still wins.vk_prewarm.binmerges the pipeline keys of a Turnip Gen8 V39 run (1762 keys) and a Turnip v27 run (1369), 1771 in all. Without it, objects and their shadows were skipped for the first minutes in new places while their pipelines were built.docs/env_switches.tsvfor the two new switches.Checks
test_android_games,test_android_profile_options,test_env_switches,test_option_patch,test_android_readinessandpeanuts/tests/test_issue_forms.pypass.games_catalog.pyreports nothing to write.peanuts/testsas a whole: the same failures asmain4ae5c26 (34 failures, 7 errors on this Windows host), none new.test_docsfails the same way onmain.restartoption. They change nothing unless enabled, and are recommended only ondriver.id=18.