fixed all(?) ip functions (except crop)

stopped doing something stupid in resize. crop still broken, sadly.
commented out nasty code because at least the old crop tried.