Osmotic-pressure-controlled concentration of colloidal particles in thin-shelled capsules