Settings and encoding fixes