add encoder.getBuffer API