Fix image size before loading it
Merge master
Merge pull request #319 from VitSalis/image_load_size

Fix image size before loading it