I'm no UX expert, but my guess from experience is that most people use their computers in bright environments; and dark backgrounds combined with glossy screens have much more glare in bright environments than light backgrounds on such screens.
The brightness of the UI should match the ambient light in the environment. Light UI in daylight, Dark UI at night. Brightness adjustments applied to both based on the ambient light. Some people may also prefer hue adjustments (blue reduction) for low ambient light along the lines of f.lux, Night Shift, Night Light, etc.