Exploratour - Evolution of the Solar System
As shown in this picture, while they were forming in the flattened disc of the solar nebula, the nucleii of the planets-to-be (called proto-planets) drew material to themselves from the cloud of gas and dust around them. The bigger protoplanets were able to attract even more gaseous material unto themselves.
This is page 8 of 60