If the object that is being photographed moves noticeably during the exposure, the image is going to be blurred. As Mach was trying to get a photograph of a supersonic bullet, moving at more than 600 m/s, the exposure needed to be very brief:
$$t_{exposure} < \frac{2\,\mathrm{mm}}{600\,\mathrm{m\cdot s^{-1}}}\approx 3\,\mathrm{\mu s}$$
It's very difficult to get very short exposures using mechanical shutters, so Mach used a spark discharge to get a very short light pulse that was bright enough to expose the film (the film "only cares" about the time-integrated exposure, not about brightness).
The photograph was a shadowgraph, with the bullet casting a shadow over the film, because Mach was interested in seeing photographical evidence of the shockwaves he had predicted.
This post imported from StackExchange Physics at 2014-03-30 15:53 (UCT), posted by SE-user mmc