Here are very handy tools online to create application icons, nine-patches and more :
This tool is handy for buttons’s nine-patch backgrounds (stretching of the internal part), but it may not be suitable to create Android Splash screen (stretching of external parts). For nine-patch Splash screen, use the below template.
Open your image and change the outer most pixel the same as this example image :
The four black pixels on the left and top sides define what is stretchable. The right and down sides does not matter (they define padding if there is some content/text) but it is better to make them all black except the bottom right pixel.