Igneous rocks are one of the three basic types of rocks on the earth, the other two types being metamorphic rocks and sedimentary rocks. The igneous rocks are formed by the hardening and crystallization of molten material called magma, that exists deep under the crust of the earth.
The igneous rocks are further divided i two types - extrusive and intrusive - depending on when an how the magma solidifies to form the rocks. Extrusive rocks are formed by molten lava erupting out of the earth's crust that flows on land or ocean floor and then cools down and hardens to form rocks. Intrusive rocks are formed when the magma under the crust of the earth cools down and solidifies, adding rocks to the lower layer of the earth's crust.
Igneous rocks are volcanic rocks formed by solidification by cooling of magma derived from upper mantle of the Earth.
There are rocks that are formed from magma at high depths, called plutonic rocks (named after Pluto) with a slow cooling time,with a phaneritic rock texture, with larger crystals.
Here we can remember granite, diorite, etc.
Colors of these rocks is directly dependent on the content of major minerals and impurities.If the cooling time is shorter, igneous rock crystals will form smaller (micro-) dimensions. In case of sudden cooling, crystals are completely absent (cryptocrystalline structure) and the rock has the appearance of a glass (eg obsidian).
Rocks formed by consolidation of magma at the surface (lava) are called volcanic rocks, depending on water content they being more or less explosive. In this case the cooling time is short, rocks of this class having fine grains.
The most important are volcanic: basalt, andesite and trachyte, that arise through the eruption activity of a volcano.