add pass encoding