Dennis Stock: The man who made Jimmy live forever

The photographer who captured timeless images of Hollywood legends and the great artists of the jazz era has died aged 81. John Walsh pays his respects

The man who helped immortalise James Dean, Louis Armstrong, hippie ecstasy and motorcycle gangland is dead. Dennis Stock, the great photographer and restlessly independent artist, has died in Sarasota, Florida. He had recently been diagnosed with colon and liver cancer.

Sent by the Magnum agency to cover Hollywood early in his career, he liked to capture film stars and musicians in unguarded (even undraped) moments. He snapped Louis Armstrong relaxing in voluminous white underpants and a knotted head-kerchief, Audrey Hepburn looking like a sulky 12-year-old while being directed by Billy Wilder in Sabrina, Marilyn Monroe in a fit of hysterics while making Bus Stop, and John Wayne ambling past a papier mâché horse on the set of The Alamo.

His most famous photograph showed James Dean trudging through Times Square in the rain, his body reflected in a puddle, shoulders hunched, cigarette dangling from lip. Though Stock prosaically titled it On Times Square, it was renamed Boulevard of Broken Dreams and adorned thousands of student walls, from the 1950s onwards, as an enduring image of the lonesome outsider.

Stock met Dean in 1955, even before his first film, East of Eden, had been released. They got on so well that he was asked by Nicholas Ray, director of Rebel Without a Cause, to be Dean's dialogue coach. Stock once explained the reason for Dean's haggard good looks. "He wasn't a drinker. He smoked a lot but everyone did in those days. What he was was an insomniac. He went to parties because he couldn't sleep."

A grouchy curmudgeon with a soft centre and a native New Yorker, born in the south Bronx in 1928 to an English mother and a Swiss father and raised during the Depression years, Stock learned his craft at the hands of two masters, W Eugene Smith and Gjon Mili, an Albanian ballet and jazz photographer who used dramatic lighting and black backgrounds. He inspired Stock to photograph jazz players – Louis Armstrong, Miles Davis, Lester Young, Duke Ellington, Earl Hines, Billie Holliday – capturing their hotel-room solitude and smoky-basement atmospherics. Stock also put together striking portfolios of hippie communes in Colorado, New Mexico and California, and motorcycle gangs at play. He held exhibitions in the world's most prestigious art galleries.

He learned from Henri Cartier-Bresson the concept of "the decisive moment", when a small world is captured in a way that can never be revisited. Though he dabbled in video, he told me in 2004: "Taking a still photograph is more penetrating and more soul-gratifying than video, because video calls for an editing response as well. It's less magical. Good photography, nine times out of 10, is poetic."