How did the cotton gin change the textile industry?

How did the cotton gin change the textile industry?