changed some picture processing