The size and shape of stromatolites are thought to be influenced by their immediate environment. Large mushroom-shaped stromatolites may form in places where tides and small waves approach from different directions. Loaf-shaped stromatolites are found in protected areas close to the shore. Because cyanobacteria need sunlight to photosynthesise, the stromatolites in Hamelin Pool do not form in water deeper than 4 m, where there is less light.