1. Anders Ruud
  2. love

Issues

Issue #590 resolved

Memory leak with canvas:getImageData()

Mark Sanders
created an issue

The following code should not increase Love's memory over time yet it does.

local c

function love.load()
  -- Not using fullscreen canvas because it will leak to quickly.
  c = love.graphics.newCanvas(128,128)
end

function love.draw()
  local t = c:getImageData()
  -- Explicitly set t to nil
  t = nil
  -- Explicitly run the GC.
  collectgarbage("collect")
end

Tested with Love 0.9.0 Boolsheet build rev 1373 x64. Windows 7 64 bit.

Comments (2)

  1. Log in to comment