GetPixels() returns array that is filled with zero Colors
I'm using GetPixels(0,0,texture.width,texture.height)
to get the entire pixel content of a simple 50x50 texture.
It seems to work fine, but the Color[]
I get is populated by purely RGBA(0.000, 0.000, 0.000, 0.000)
.
For debugging purposes I'm printing the content of GetPixels on every update and they don't seem to change. For context, My Texture2D starts as blank, and on update pixels are added to it with SetPixel()
. Any reason why every color would be a 0?
Answer by nullgarden · Dec 03, 2017 at 11:46 AM
Nevermind it's working, there is just so much to print that they didn't show in the console. I'm leaving this question up for other foolz like me.
Your answer
Follow this Question
Related Questions
WebCamTexture to circular sprite 1 Answer
Change Texture2D readable flag at runtime (or at least a workaround to do that) 0 Answers
RenderTexture to Texture2D very slowly 0 Answers
Turning every color in an image to many GameObjects ? 0 Answers
How to check the Completion scenario for my drawing? 1 Answer