Lighting, which is an important side of quality control by artificial vision is often neglected. Scientists ha ve to spend time and make several experiments before finding a good solution. We have chosen to study lighting of metallic objects according to the shape and the roughness of the object for an optimal defect detection. The first step of our study was to find a theoretical model of light scattering. To take into account reflection on smooth as well as rough surfaces, it is necessary to have a physical approach in the way of Beckmann and Spizzichino who based their model on electromagnetic wave theory. The general expression for surface radiance is a fairly complicated function of the angles of incidence and reflection, and the surface roughness parameters. Radiance diagrams of this model give the light intensity reflected by an elementary surface in all the directions. Thanks to this model, we are able to optimize the size and position of the source according to the shape and the roughness of the object and the type of defects to detect. In the field of artificial vision, the conceivable applications are numerous : for instance one can quote defect detection (scratches, knocks...) or dimensional control of object ( swell or undulation measurement...).