crude but working resize