1. A method comprising: receiving a virtual image to be presented by display optics; receiving lighting information from an optical sensor system; receiving an eye-position parameter; generating a blocking image in an opacity layer based on the lighting information and the virtual image, the blocking image preventing a portion of real-world light from reaching the display optics; adjusting a location of the blocking image in the opacity layer based on the eye- position parameter; and adjusting an opacity of the blocking image at an adjusting rate that corresponds to a pupillary response rate.