Hardware-Aware Coding Function Design for Compressive Single-Photon 3D Cameras