Single-photon detection or photon counting