Wave-packet formalism of full counting statistics