Hi,
Does anyone know of a decent run-time JPEG decoder that would work out of the box in Unity? On mobile devices. Doesn’t have to be super fast; I’d use it when loading a scene.
What I need essentially is something that would make a byte → Color32 conversion without extra memory allocations, as I need to merge the Color32 array into another array again. I know about
Texture2D.LoadImage()
and its sister
WWW.LoadImageIntoTexture()
but I’d really like to avoid copying the buffer twice. (As I imagine the Texture2D.GetPixels32() only returns copied data.) The image is relatively large.
Surely there must be a library or a bunch of scripts somewhere. Although I can’t find anything…