Work around firefox's silent resampling failures

Resample in JS from now on in all APIs. Do not use firefox's internal
resampling.