Optical properties of lead halide perovskites for optoelectronics