Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines
(4 edits)

Until something like this is supported by Pixelbox, you could drop down to the native html canvas and do something like this:
https://www.w3schools.com/tags/canvas_getimagedata.asp
I typically avoid w3schools examples, but this pretty succinctly describes what you're trying to do. You can use document.querySelector('canvas') to find the canvas that Pixelbox is drawing to, and use the getImageData()/putImageData() methods on the context from the canvas.

actually the global $screen Texture stores the canvas as $screen.tilesheet and the context2d as $screen.ctx, so you should be able to use $screen.ctx.getImageData()/putImageData().