change internal format buffer handling (centralize)