What are the factors that affect buffer capacity?