A process by which an organism uses energy from light and an (usually) inorganic electron source to reduce organic compounds. There are three major groups of photosynthetic bacteria: cyanobacteria, purple bacteria, and green bacteria. The cyanobacteria carry out oxygenic photosynthesis, that is, they use water as an electron donor and generate oxygen during photosynthesis.The photosynthetic system is located in an extensive thylakoid membrane system that is lined with particles called phycobilisomes. The green and purple bacteria carry out anoxygenic photosynthesis. They use reduced molecules such as H2, H2S, S, and organic molecules as an electron source and generate NADH and NADPH. In green bacteria, the photosynthetic system is located in ellipoidal vesicles called chlorosomes that are independent of the cytoplasmic membrane. In purple bacteria, the photosynthetic system is located in spherical or lamellar membrane systems that are continuous with the cytoplasmic membrane.