Hi all, I use my mobile camera from my application and sometimes I want to take a screenshot. To start camera I use WebCamTexture and a RawImage, all good and now I have a Texture2D where I read pixels and encode texture image to png, this will store that in a byte array.
Each time when I take a screenshot memory grows up but after encode I clear bytes array, I call
GC.Collect(); GC.WaitForPendingFinalizers();
to free memory but no chance .
Does anyone have any ideea what can cause that? That happen in windows phone universal 10, I use unity 5.4
Thanks, any advice is appreciated