adding encoding