Skip to content

Commit

Permalink
Fix VRAM leak in compositor effect demo (#1115)
Browse files Browse the repository at this point in the history
  • Loading branch information
RGDTAB authored Sep 16, 2024
1 parent fdae025 commit a87fded
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion compute/post_shader/post_process_grayscale.gd
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ func _notification(what: int) -> void:
if what == NOTIFICATION_PREDELETE:
if shader.is_valid():
# Freeing our shader will also free any dependents such as the pipeline!
RenderingServer.free_rid(shader)
rd.free_rid(shader)


#region Code in this region runs on the rendering thread.
Expand Down
2 changes: 1 addition & 1 deletion compute/post_shader/post_process_shader.gd
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ func _notification(what: int) -> void:
if what == NOTIFICATION_PREDELETE:
if shader.is_valid():
# Freeing our shader will also free any dependents such as the pipeline!
RenderingServer.free_rid(shader)
rd.free_rid(shader)


#region Code in this region runs on the rendering thread.
Expand Down

0 comments on commit a87fded

Please sign in to comment.