Sedimentary rocks originate when particles settle out of water or air, or by precipitation of minerals from water. They accumulate in layers. Metamorphic rocks result when existing rocks are changed by heat, pressure, or reactive fluids, such as hot, mineral-laden water.