mirror of
https://github.com/tangerineturtle1/NX2navi.git
synced 2026-11-17 02:49:57 -04:00
Hand an overwritten render target's image on after 8 presents while the card is past its pressure share, and free the ones no texture took after 32.
At 3840x2160 the targets moved in 16 presents hold 3.1 GiB, which a 16 GiB card does not have beside the 10 GiB of a town. A mark reaches its entry within three frames of the draw (four read-back copies, one every four submissions), so eight presents without a stamp are enough there. The early drop waits four times that: at ten presents it took the images the reuse was about to hand on (7,301 dropped, 7,672 made, 5,226 reused in one run); at 32 the same run made 3,338 and reused 8,004. The walk from the bug capture at 3840x2160 with the budget taken as 13.2 GiB, a 16 GiB card's: 10.9 to 11.4 GiB in use, at most 1.6 GiB of released targets, no image that could not be made and none in system memory. A player's log from such a card at that size had 12.2 GiB of released targets and 22.2 GiB in use at 2 frames a second. Without the budget, at 3416x1440: 10.0 to 10.7 GiB, as before this change. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This commit is contained in:
@@ -1,15 +1,16 @@
|
||||
## Fixed
|
||||
|
||||
- **Video memory no longer fills up while the camera moves** (by epicmeme546). The game lays its render targets out
|
||||
anew in every frame, one behind the other in one block of memory. One of them, a shadow map, changes its size with
|
||||
the view (1141x1141 to 1917x1917 in Kokiri Forest, a texel or two a frame), and every target behind it then lies at
|
||||
a new address in each frame. A moved target should take over the image of the one it replaces, but that image
|
||||
counted as in use for as long as the game had not recycled the old target's texture object, so every frame got about
|
||||
a dozen new images and each old one stayed for 120 frames or more: 6.7 GiB of them at 3416x1440 and 12.2 GiB at
|
||||
3840x2160, on top of the 10 GiB the area needs. A 20 GiB card ran full twice in five minutes of Kokiri Forest and a
|
||||
16 GiB card in Castle Town (images that could not be made or went to system memory, 2 to 4 frames a second, then
|
||||
the game ended). An image that another target was drawn over now goes to the next target of its size once nothing
|
||||
has drawn with it or sampled it for 16 frames, and past 80 % of the card's memory such images are freed at once
|
||||
instead of ten seconds later. Walking 28 metres from a save in Kokiri Forest and then around it at 3416x1440: 15.9 GiB
|
||||
of video memory in use before, 14 GiB again on each lap; 9.7 to 10.6 GiB now, with at most 2.2 GiB of released
|
||||
targets where there were 6.9 GiB, and 3,609 images made in the run where there were 6,970.
|
||||
- **Video memory no longer fills up while the camera moves** (by epicmeme546). The game lays its render targets out anew
|
||||
in every frame, one behind the other in one block of memory. One of them, a shadow map, changes its size with the view
|
||||
(1141x1141 to 1917x1917 in Kokiri Forest, a texel or two a frame), and every target behind it then lies at a new
|
||||
address in each frame. A moved target should take over the image of the one it replaces, but that image counted as in
|
||||
use for as long as the game had not recycled the old target's texture object, so every frame got about a dozen new
|
||||
images and each old one stayed for 120 frames or more: 6.7 GiB of them at 3416x1440 and 12.2 GiB at 3840x2160, on top
|
||||
of the 10 GiB the area needs. A 20 GiB card ran full twice in five minutes of Kokiri Forest (images that could not be
|
||||
made, 4 frames a second, then the game ended) and a 16 GiB card in Castle Town (images in system memory, 2 frames a
|
||||
second). An image that another target was drawn over now goes to the next target of its size once nothing has drawn
|
||||
with it or sampled it for 16 frames, or for 8 once the card is past 80 % of its memory, where such images are also
|
||||
freed after 32 frames instead of ten seconds. Walking 28 metres from a save in Kokiri Forest and then around it at
|
||||
3416x1440: 15.9 GiB of video memory in use before and 14 GiB again on each lap; 9.7 to 10.7 GiB now, with at most 2.2
|
||||
GiB of released targets where there were 6.9 GiB, and 3,609 images made in the run where there were 6,970. The same
|
||||
walk at 3840x2160 with the memory budget of a 16 GiB card: 10.9 to 11.4 GiB, at most 1.6 GiB of them released.
|
||||
|
||||
Reference in New Issue
Block a user