Fixed a bug recently introduced in pixel convert