A system and a method for control-l-ing an intens:-ty of X-rays generated by an X-ray imaging device The present. invention anci the embodiments thereof relate to a system (5) and a method for control-ling an intensity of an Xray imaging device (15). An image brightness value is determined for an image (180) obtained therein and an electrical parameter thereof is determined. The image (180) obtained therein is via nonlinear attenuation of visible light (98) obtained from an X-ray detector (40) comprised in the X-ray imaging device (15). The electrj-ca1 paramet"er is thereafter provided to the x-ray imaging device (15) for 15 controlling the intensity of the generated X-rays (10).