Opium poppy. Coloured X-ray of the seed capsule (seed head) of an opium poppy, Papaver somniferum. The capsule is borne on a stalk (at bottom), with the stigma of the old flower seen at top. Seeds are visible within the capsule. This is the structure from which opium is collected: the circumference of the capsule is slit, allowing a milky latex to ooze out. The latex hardens to form a plastic gummy substance on exposure to air, which is scraped off and formed into balls. Crude opium contains numerous alkaloids including morphine, heroin and codeine. Opium is used medicinally as a sedative and to relieve pain. It is also used extensively as a narcotic drug.