I'm trying to clean up a large project which has a lot of nine patch images (50 or so). One thing I'm finding out is when an android project migrates from Eclipse over to Android Studio, the system looks at the 9 patch images to ensure they comply to a standard. And I'm getting lots of gradle errors.
The best description I've seen for a 9 patch is simple guide to nine patch.
Android Studio includes a 9 patch editor tool. It's the use of that tool that brought me here. The tool has a button that toggles "Show Bad Patches / Hide Bad Patches". I'm struggling trying to understand the concept of "Bad Patches."
Reference: Android document, describing the use of that button.
Show bad patches: Adds a red border around patch areas that may produce artifacts in the graphic when stretched. Visual coherence of your stretched image will be maintained if you eliminate all bad patches.
Reference: Android Developer guide on 2d graphics. That guide says the 'Show Bad Patches' button ...
raises warnings if the region you've defined for the stretchable area is at risk of producing drawing artifacts as a result of the pixel replication.
Here is a screen shot of the file I'm looking at:
So here's the deal. No matter what I do, I always have some bad patches visible on my graphics. How do you 'clean' up an image to avoid bad patches?
Why are those red boxes displayed on my screen? I've been playing with the image and the 1 pixel borders, but not sure where to go from here. Anybody understand what is happening here? What does Nirvana.9.png look like?