An image of star HD 44179, surrounded by an extraordinary structure known as the Red Rectangle. This image was captured by the Hubble Space Telescope.

A striking new image captured by the Hubble Space Telescope delivers a deep look into a mysterious cosmic object called the Red Rectangle Nebula.

The Red Rectangle, so named because of its bizarre shape and striking color, is a nebula — a cosmic cloud of gas and particles. In this case, the nebula is formed by the central star, HD 44179, which is reaching the end of its life and shedding most of its mass into space.

The source of the red light emitted by the Red Rectangle baffled scientists for more than 30 years. The same kind of red emission was seen throughout the Milky Way and in other galaxies, but scientists weren't sure what created it. The mystery was finally solved in 2007: The glow comes from strange activity at the molecular level inside clusters of dust.

This new image gives scientists the best understanding yet of the structure of the Red Rectangle, according to a statement from NASA. Instead of a rectangle, it appears that the nebula around the star is shaped like an "X," with ladder-like rungs of glowing gas connecting the four arms.

The star at the center of the Red Rectangle is similar to Earth's sun and is responsible for those evenly spaced lines as it releases gas and other material to create the nebula and its distinctive shape. NASA experts now believe the star is also a close binary (meaning it has a stellar partner), and is surrounded by a dense area of dust, according to the statement.

The star at the center of the Red Rectangle will eventually leave behind a hot white dwarf that will give off brilliant ultraviolet radiation that will cause the surrounding gas to glow.

Follow Kasandra Brabaw on Twitter @KassieBrabaw. Follow us @Spacedotcom, Facebook and Google+. Original article on Space.com.