had to change scanLine and comparison functions to deal with new enum types ARRGH