Igneous rocks — those which originate from magma — fall into two categories: extrusive and intrusive. Extrusive rocks erupt from volcanoes or seafloor fissures, or they freeze at shallow depths. This means that they cool relatively quickly and under low pressures. Therefore, they are typically fine-grained and gassy. The other category is intrusive rocks, which solidify slowly at depth and do not release gases.
Some of these rocks are clastic, meaning they are composed of rock and mineral fragments rather than solidified melt. Technically, that makes them sedimentary rocks. However, these volcaniclastic rocks have many differences from other sedimentary rocks — in their chemistry and the role of heat, especially. Geologists tend to lump them with the igneous rocks.
This basalt from a former lava flow is fine-grained (aphanitic) and massive (without layers or structure).
This basalt cobble has gas bubbles (vesicles) and large grains (phenocrysts) of olivine that formed early in the lava’s history.
Pahoehoe is a texture found in highly fluid, gas-charged lava due to the deformation of flow. Pahoehoe is typical in basaltic lava, low in silica.
Andesite is more siliceous and less fluid than basalt. The large, light phenocrysts are potassium feldspar. Andesite can also be red.
Andesite from La Soufrière
La Soufrière volcano, on St. Vincent island in the Caribbean, erupts porphyritic andesite lava with phenocrysts largely of plagioclase feldspar.
Rhyolite is a high-silica rock, the extrusive counterpart of granite. It is typically banded and, unlike this specimen, full of large crystals (phenocrysts). Red volcanic rocks are usually altered from their original black by superheated steam.
Rhyolite with Quartz Phenocrysts
Rhyolite displays flow banding and large grains of quartz in the almost-glassy groundmass. Rhyolite can also be black, gray, or red.
Obsidian is a volcanic glass, high in silica and so viscous that crystals do not form as it cools.
Obsidian or rhyolite flows that are rich in water often produce perlite, a lightweight, hydrated lava glass.
Peperite is a rock formed where magma meets water-saturated sediments at relatively shallow depths, such as in a maar (a broad, shallow volcanic crater). The lava tends to shatter, producing a breccia, and the sediment is vigorously disrupted.
This bit of basaltic lava was puffed up by escaping gases to create scoria.