Bugfix solved when scaling images