Luminescence control in hybrid perovskites and their applications