add load_image, apply_surface functions
update main to use new functions