Automatic sprite generation