The lighting conditions of mobile devices could severely affect the viewing experience of the displayed image, such as loss of details and contrast, especially for high dynamic range (HDR) contents. In this paper, a content independent luminance and detail enhancement method is proposed for HDR images under ambient illumination. The perceptual luminance at the given lighting conditions is first quantified based on the human visual adaption. Combining the quantization curve and the display model, the mapping operator for the luminance channel could then be efficiently constructed. Both psychophysical evaluation and objective measurement indicate that the proposed method significantly improves the perceptual quality of HDR images under ambient illumination.