Quote Originally Posted by dorff View Post
The highest contrast is achieved with a slightly larger aperture than the aperture for highest resolution.
Me bad, it is actually the other way round, and the f-stops are not quite constant.

The formula (based on contrast) is:

d = 1.56 * sqrt (f * L)

where f = focal length in mm, L = wavelength in mm, d = pinhole diameter in mm. For normal purposes, L is taken to be 555 nm, or 0.000555 mm.

The "ideal" f-stop increases with focal length.

In your case, with a focal length of 21 mm, the diameter should be 0.17 mm. This corresponds to an f-stop of 125, i.e. very close to f/128. For such a small aperture, the best would be to have it laser cut. If that isn't an option, consider a thin but sturdy metal foil. I have used copper tape with success. It can be found in craft shops, under stained glass consumables. Dent it with a ballpoint pen or other neatly round object, then pierce with a fine needle, against a slightly yielding backing such as hard rubber or wood.

"Way Beyond Monochrome II" has a chapter on pinhole photography. If you do not have the book yet, it is an excellent resource and worth every dollar.