NASA photographer Bill Ingalls posted this photo of his melted Canon camera after it was destroyed by a brush fire sparked by a SpaceX Falcon 9 rocket launch at Vandenberg Air Force Base in California on May 22, 2018. The Falcon 9 launched NASA's twin GRACE-FO satellites and five Iridium Next communications satellites.

Veteran NASA photographer Bill Ingalls is no stranger to rocket launches, but even he seemed surprised when one of his remote cameras melted in a fire sparked by a SpaceX Falcon 9 launch Tuesday but — wait for it — still managed to snap photos of the liftoff.

"Well, one remote cam outside the pad perimeter was found to be a bit toast(y)," Ingalls wrote on Facebook after the launch, "and yes – it made pix until [its] demise."

The "toasty" camera was a Canon DSLR that Ingalls placed about a quarter mile (1,320 feet, or 402 meters) from SpaceX's pad, called Space Launch Complex 4E, at Vandenberg Air Force Base in California. It was one of six remote cameras that the photographer set up to chronicle the launch of NASA's twin GRACE-FO satellites on Tuesday (May 22). Five commercial Iridium Next communications satellites also rode the Falcon 9 into orbit. [See more awesome photos of SpaceX's GRACE-FO launch]

The camera melted in a brush fire triggered by the Falcon 9 launch, Ingalls told Space.com today (May 23). Vandenberg's fire department arrived to the launchpad after liftoff (which is typical of Vandenberg launches, to secure the site). A firefighter then found the camera and had it waiting for Ingalls when he arrived to collect his remote cameras.

"The Vandenberg Fire Department put the fire out pretty quickly, but unfortunately my camera got toasted" before they got to it, Ingalls said.

It was the first time that one of Ingalls' cameras has been melted during a launch, and he's been snapping photos for NASA since 1989.

But despite being melted, the camera still managed to do its job. In one photo, the camera snapped a single frame of the SpaceX Falcon 9 as it began to lift off. "At least [it] got a frame before the camera bit the dust," Ingalls wrote.

This photo of SpaceX's Falcon 9 rocket launch was captured by a remote camera set up by NASA photographer Bill Ingalls before a brush fire melted the camera on May 22, 2018, at California's Vandenberg Air Force Base. (Image credit: Bill Ingalls/NASA)

Then came the fire.

The next photo clearly shows flames overtaking the camera. "Reason for the toasty remote camera," Ingalls wrote.

One final photo by Ingalls shows the remains of the camera, its lens a charred mess of bubbled plastic. "Toasty remote camera," Ingalls wrote.

Flames from a brush fire are clearly visible in this final image from a remote camera set up by NASA photographer Bill Ingalls for SpaceX's Falcon 9 rocket launch on May 22, 2018. The brush fire ultimately melted the camera, but its memory card was still accessible. (Image credit: Bill Ingalls/NASA)

The brush fire that scorched Ingalls' camera seems to have just been bad luck. He had four other remote cameras located much closer to the launchpad that made it through unscathed and worked flawlessly.

The biggest worry for a remote camera near the launchpad is usually debris, Ingalls said. A rocket launch can kick up rocks and other bits of debris that can damage or destroy a camera.

Cameras close to launchpads have protective housings, while lens filters can help protect cameras located farther away, he said.

Email Tariq Malik at tmalik@space.com or follow him @tariqjmalik. Follow us @Spacedotcom, Facebook and Google+. Original article on Space.com.