Nine Patch Image Optimiser
I have the little python script to make the nine patch image from original one:
Github link: https://github.com/Insality/nine-patch-optimizer
Usage
You can pass the single image or folder (see README at github) and you will get next output for each processed image:
Image: button_purple.png
Output: button_purple.png
Origin Size: 368x128
New Size: 122x128
9Patch side: [60, 0, 60, 0]
Saved: 66.85%
To use image in Defold as before, set in the editor nine patch settings:
60 (from left) 0 (from top) 60 (from right) 0 (from bottom)
and set node size to origin size:
Origin Size: 368x128
Hope it can be useful for you