Added -main function to imaje.core