prep encoding