Make texture2D readable in runtime/script Unity3D
I have a plugin that allows me to access pictures from an Android phones gallery. This gives me a texture of the Texture2D type. I then want to edit it using the GetPixels function, but it is not set to readable by default. How would I make the texture readable so I can use GetPixels on it?
Basically I am allowing the user to select a picture from the phone and then crop it. In the following example pic the picture would be cropped by the red rectangle. Which works if I make the texture readable beforehand. http://puu.sh/mxR3h/dfa81719b2.jpg
Answer by RoyalCoder · Apr 19, 2016 at 01:02 PM
Hi Waltari,
What plugin did you using for this approach, I need this tool too ? Basically I want to crop the image with specific shape, did you managed make this to work? Thanks!
Your answer
![](https://koobas.hobune.stream/wayback/20220612060434im_/https://answers.unity.com/themes/thub/images/avi.jpg)