Image scaling fix