Skip to content

Commit

Permalink
fix incorrect errors when using an integer format ImageData
Browse files Browse the repository at this point in the history
  • Loading branch information
slime73 committed Apr 18, 2024
1 parent 3a67238 commit 58f05eb
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/modules/image/wrap_ImageData.lua
Original file line number Diff line number Diff line change
Expand Up @@ -342,9 +342,9 @@ local objectcache = setmetatable({}, {
width = width,
height = height,
format = format,
pointer = conv == nil and nil or ffi.cast(conv.pointer, imagedata:getFFIPointer()),
tolua = conv == nil and nil or conv.tolua,
fromlua = conv == nil and nil or conv.fromlua,
pointer = conv ~= nil and ffi.cast(conv.pointer, imagedata:getFFIPointer()) or nil,
tolua = conv ~= nil and conv.tolua or nil,
fromlua = conv ~= nil and conv.fromlua or nil,
}

self[imagedata] = p
Expand Down

0 comments on commit 58f05eb

Please sign in to comment.