postproc: use FFMIN/FFMAX where appropriate