When shooting outdoors in bright sunlight, and specially when shooting with the sun visible in the background, lens flare can affect the picture by reducing contrast and introducing artifacts. Are there any special techniques or any equipment that can be used to reduce the problem with flares? Are certain types of lenses better than other?
A lens hood won't do you much good if the light source is in the frame.
In this case, the things to do are (a) use high-quality, well-coated lenses, designed for digital if you're doing that (i.e., the rear element is coated) and (b) minimize extra glass in the optical path - remove UV filters, etc.
I know this is an old question, however one particular answer was left out before. One of the key tools we can use to mitigate flaring, ghosting, and contrast loss when photographing a scene with a bright light source (or just slightly off-axis light source in a corner) is to use miltocoated lenses. Multicoating has been used for decades, and is certainly an effective means of improving transmission and reducing undesirable artifacts like flare. Its given us the ability to achieve nearly 99% transmission per lens element, etc. However it does have its limitations, and flare still occurs, sometimes very badly, with intense light sources like the sun.
Newer, more modern lens designs from the last five years use a new form of lens coating...called a nanocoating. Unlike multicoating, which tries to utilize the nature of reflected light against itself, nanocoating attempts to guide as much light as possible into the lens and avoid reflection in the first place. Some light is still going to be reflected, however transmission improves considerably to 99.95%, and flare, ghosting, and contrast loss is minimized to the point where even if it does occur, it often doesn't matter.
So if you have the funds to invest in new, higher-quality lenses, I would say the best tool to combat flare these days is to get a lens with Nanocoating. Currently, as far as I know, only Nikon and Canon offer lenses with quality nanocoats that really do the job well. Some research might turn up other brands that offer it. Intriguingly, one of the best names in the business, Zeiss, still uses their decades-old T* coating, which is often times inferior to Canon and Nikon multicoating, and vastly inferior to nanocoating.
This is exactly the purpose of a lens hood. The other preventative steps are to minimise the number of filters attached to the front of your lens, as lens flare is the result of some the light reflecting back from one element, before bouncing back from another.
If you use a lens hood or try to keep the front element in shade wherever possible, you shouldn't as much flare as without
Lenses produce different flares depending on aperture setting, so besides trying different lenses and removing filters, you might want to play with that.
There's not much you can do really since it's how light behaves when going through a lens. Always to keep in mind: higher quality means less flare artifacts. If you shoot at the sun you'll get flare anyway.
If you want to reduce it use lenses with fewer optical elements. The more elements the more imperfections you can have.
Shooting directly into the Sun or a pinpoint light source results in a few effects (desirable or undesirable, depending upon your opinion) depending upon a number of factors, most of which can be controlled by a combination of techniques and circumstances.
You usually get contrast reduction, flares, spikes, and artifacts when a bright source of light enters your lens directly.
Contrast reduction can be reduced or eliminated by using a graduated ND Filter, either circular or linear. Use of large square NDs that slide into a holder will allow for a maximum amount of fine adjustment. Here are some tips for their use: https://www.outdoorphotographer.com/tips-techniques/nature-landscapes/master-the-grad-nd/ .
Flares and artifacts are caused by reflections within the lens body either from the lenses themselves or internal components and the lens body's wall - better lenses with better coatings and removal of screw-on Filters will reduce or eliminate these sources.
Next up are spikes which are caused by diffraction from the aperture or leaf shutter blades. Depending upon the number of blades in your aperture you will get a different number of spikes.
An even number of blades produces an equal number of spikes and an odd number of blades produces twice as many spikes as there are blades. Note how a polygon aperture and a round aperture produce a different type of spike despite having the same number of blades.
If you could have an infinite number of blades you would have smooth and spike-free bokeh, but that is impractical to approach with most lenses having between 2 and 22 blades; with 9 being enough for a modern lens design to produce (so-called) good bokeh.
Another means to eliminate the spikes caused by aperture blades, essentially obtaining an infinite number of blades, is to use a bladeless design.
Lenses that use a Waterhouse Aperture Plate such as the Petzval 58 Bokeh Control Art Lens from Lomography use interchangeable plates with various sized holes to control the aperture. Holes of different shapes are also possible, to produce shaped bokeh.
Another means to provide a smooth aperture and eliminate the diffraction pattern caused by aperture blades along with all lens artifacts is to eliminate both the lenses and the aperture by using a pinhole lens.
A pinhole lens is no lens at all, it's simply a hole in front of the imager (film or sensor). It can be made for next to nothing using a pin and a piece of black cardboard.
There are certainly fancier alternatives than that ranging from one that costs over $1000 (for one hole) to one from Thingyfy Pinhole Pro that features over a half dozen holes for under $200.
A smooth aperture and no lenses can produce a photo with very few artifacts while shooting directly into the Sun.
If you like your lenses that you invested so much in and don't want to buy a hole there's another solution, High Speed Sync, which can be used to overpower the Sun.
Note how the Sun is blackened and the subject brightened.
Higher sync speeds are useful as they enable the brightness of the background to be controlled while maintaining normal flash exposure in the foreground.
To gain more power to fight the Sun and operate your flash at longer distances, among other benefits, you can use Hi-Sync.
Unlike High Speed Sync which uses a series of flashes to lengthen the flash unit's duration Hi-Sync times the flash pulse more precisely so a single flash pulse occurs exactly at the bulb's peak of power as the shutter is opened.
Lens hood is a device that is used on the end of lens lens to block the sun or light source in order to prevent lens flare.