render3d: gvk_read_screen reads back into one buffer kept in the state
Every read of the screen made bytes(screen_w * screen_h * 4) and dropped it: the user's manual play left 22,970,368 B unreachable (exactly 3024x1898x4) at gpu_vk_draw.ludic:1673 - one per photograph (shots' ph_grab, through gpu_read_screen_bytes). The read-back is now gvk_read_px, made once and made again (the old one freed) only when the screen's size changes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
28ad6f62ea
commit
87587b00b6
2 changed files with 11 additions and 1 deletions
|
|
@ -166,6 +166,8 @@ export state Render3dState {
|
|||
gvk_family: int = -1
|
||||
gvk_mp: bytes = null # VkPhysicalDeviceMemoryProperties
|
||||
gvk_device_name: string = ""
|
||||
gvk_read_px: bytes = null # gvk_read_screen's read-back, gvk_read_cap bytes, made again only at a new size
|
||||
gvk_read_cap: int = 0
|
||||
gvk_renderer_name: string = "" # "<device> (Vulkan)", made once with the device
|
||||
gvk_why: string = "" # why the device did not come up, for the fallback notice
|
||||
gvk_max_aniso: int = 0x3F800000 # the device's anisotropy limit as float bits; 1.0 when it has none
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue