More encoding tweaks