“Any girl can be glamorous,” the actress Hedy Lamarr once said. “All you have to do is stand still and look stupid.” It’s a withering observation, especially for a Hollywood star once known as “the most beautiful woman in the world.” Beauty brought Lamarr fame, at least until everything fell spectacularly apart; as with too many actresses, beauty was also her gilded cage. The new documentary “Bombshell: The Hedy Lamarr Story” shows how hard and how long she struggled to escape it — including through her invention in the 1940s of a groundbreaking communication system that underlies modern encryption.

The story of that invention has been told before though it’s curiously missing from Lamarr’s contribution to a dubious 1966 memoir, “Ecstasy and Me: My Life as a Woman,” which, bizarrely, includes an introduction by a shrink. (She unsuccessfully tried to stop its publication.) The title refers to the 1933 film that set her on the path toward scandal and stardom. Directed by Gustav Machaty, “Ecstasy” involves a young woman’s sexual desire and disappointment, and remains best known for the sight of its teenage Viennese star — then called Hedy Kiesler — frolicking naked and, more notoriously, feigning orgasm. (Machaty apparently jabbed her with a pin to achieve the desired writhing.)

By 1938, Hedy Kiesler had been renamed Hedy Lamarr, and she was under contract to Metro-Goldwyn-Mayer and starring alongside Charles Boyer in the romantic thriller “Algiers.” It was Boyer’s show; Lamarr was a side dish. In his review of the film, the critic Otis Ferguson all but shrugged her off as “the girl,” while movie magazine writers slobbered over her looks. “No more beautiful woman,” one columnist gushed, “has ever stormed the doors of moviedom than Hedy, grey-eyed, raven-haired Viennese known as the ‘Ecstasy Girl.’” Four years later, Lamarr was still battling such typecasting blather, despite having patented a secret communications system called frequency hopping.

Directed by Alexandra Dean, “Bombshell” is a very enjoyable addition to what has become a minor Hedy Lamarr industry that includes documentaries, books and stage productions. Like some of these other accounts, this documentary traces the arcs of Lamarr’s personal and professional lives, which by turns harmoniously converged and wildly veered in opposite directions. Whatever happened, it was rarely dull. The daughter of assimilated Jews, she married a munitions magnate who came with a castle and did business with Mussolini. When she decided to ditch her husband, she staged (or so she claimed) an escape that turned her into the heroine of her own thrilling adventure.