Everytime I point a digital camera of some sort (webcam, phone, camcorder...) at my LED desk lamp or its light reflected off an object (only if the object is very reflective and/or near the lamp), I see some scrolling black lines that shift thickness and scrolling speed as I change white balance.

They make it impossible for me to film uboxing and other videos using my desk lamp as light source. What is the cause of this? I also noticed my ceiling-mounted LED light produces a similar pattern as well albeit with thicker lines. Finally, my bedside lamp - also LED - creates no such phenomenon.

A photo of the LED light on my desk

enter image description here


7 Answers 7


Cheap (to make) LED lights will flicker at twice the mains frequency. There are many ways of overcoming this in the design of lights, such as using a larger smoothing capacitor (which makes the light bulky), using a dedicated progressive LED driver IC (which turns off some of the LEDs but not all of them, so the light dims rather than going out every half cycle) or using a switched mode converter at a higher frequency (which is more complex than the more common capacitive dropper, but allows dimming - adjustable LED panels sold for use in photography will have this technology).

Put a different bulb in the lamp, such as the one that's in your bedside lamp. Generally the more expensive and branded ones will have better smoothing circuitry.

  • Upvoting this because it's the only answer so far to mention that only cheap LED lights flicker. Good ones do not.
    – pipe
    Commented May 15, 2018 at 17:11
  • 3
    @pipe - I upvoted the post, but not because of it mentioning only cheap led lights flicker- because it just isn't true. Some expensive ones flicker...
    – Dr Mayhem
    Commented May 16, 2018 at 11:26
  • @alex2003super you was robbed Commented May 22, 2018 at 14:54

The reason is very simple. LED's are not constantly turned on, but flicker at a very high rate, usually due to fluctuations in your powerline. Your video camera records at a fixed framerate and as such, you can see these black lines.

One way to counteract this is by not using an LED light source. But you may be able to work around this by setting a slower shutter speed (thanks to ths in the comments for this suggestion). You will likely need a tripod then though.

  • or by using a slower shutter speed.
    – ths
    Commented May 15, 2018 at 13:29
  • So sorta like tearing?
    – alex2003super
    Commented May 15, 2018 at 13:45
  • 2
    @alex2003super yes, that's exactly the same as tearing: multiple "frames" of reality in the different scanlines of a single image.
    – Ruslan
    Commented May 15, 2018 at 16:33
  • Fluorescent lights have a similar issue. The best way to avoid this problem is to use incandescent sources, but they are disappearing.
    – Jim MacKenzie
    Commented May 15, 2018 at 18:00
  • 4
    Battery-powered LED lamps will work, as will high-quality mains-powered LED bulbs, and (most) transformer-powered LED light strips.
    – Mark
    Commented May 15, 2018 at 20:34

LEDs are a very fast reacting light source, far faster reacting than incandescents or even flouresecents. So if the current through the LED varies rapidly the light output will vary equally rapidly.

Cameras often have a "rolling shutter". Different parts of the frame are captured at different times. So time variation in the lighting becomes spacial variation in the image.

There are several different possible causes of rapid variation in LED drive current and hence light output.

  1. Some very cheap LED lights just rectify the mains and feed is straight to the LEDs.
  2. Some LED drivers use the LEDs themselves as the diodes in a switched-mode converter.
  3. Some LED lights use pulse width modulation to adjust the brightness. Due to implementation even with the brightness control set to it's maximum value the on-time may not be quite 100%.

Personally of the three possible causes I think you are dealing with number 3. The reason I think this is that the lines are very hard edged. With mains-derived flicker I would expect to see a gradual ramp up and down. With switchmode converter derived flicker I would expect to see a sharp transition from black to full brightness followed by a gradual fade out.


As @LPChip said, LEDs flicker at a high rate. This rate is equal to twice the frequency of your powerline (afaik, 50Hz in Europe, 60Hz in USA). If your exposure time is a few times the flicker rate, you'll have no trouble. Also possible is a exposure time of exactly a low multiple of the flicker frequency (so if your power is using 60 Hz, you can safely use 1/120 s or 1/60 s). For video, I'm not sure how to deal with the flicker, but a frame rate of exactly the power frequency might work. (if you use a framerate even slightly different from the net frequency, you'll catch a different phase of the light cycle at each image, so some frames will get full light, some will catch the full dark period, and the others will be somewhere in between.

The differences you noticed between different lamps can have a few causes.

One is the driver needed to transform the incoming alternating current into direct current. More expensive circuits can remove the pulsing that remains after the initial transformation of the alternating current.

Another might be related to the composition of the lamp: white leds are actually (blue?) LEDS within a (fluorescent) material that converts part of the LED light to longer wavelengths (green, yellow, and red light). If that material shows some phosphorescence, the lamp will continue emitting light for a short time (ms or µs) after the LED "switches off". That can diminish the flickering.

  • Shouldn't 1/120 s be 1/30 s?
    – TKK
    Commented May 15, 2018 at 18:57
  • @TKK, most cheap bulbs have their LEDs wired in pairs, so that one of the pair is on during each half-cycle of the mains power, giving 1/120 s.
    – Mark
    Commented May 15, 2018 at 20:36

Yes, this is a shutter speed issue. Or rather it's your camera getting (almost) in sync with the flicker of your lamp. LED and fluorescent lamps (either CFLs or the longer tubes) only produce light for instants within any given second. Good old-fashioned incandescent bulbs also flicker, but the thermal inertia in the wire means that the degree of flicker will be much reduced and will barely be noticeable in many photos.

The solution is easy - either change the bulb in your desk lamp, or choose a smaller aperture & longer exposure for your shots. Do experiment, but something like 1/30th or 1/15th second exposure should mean that the illumination flicker is eliminated. If you need to be hand-held, then consider a high-frequency bulb. That would then allow you to have a shorter exposure time.


Everytime I point a digital camera of some sort (webcam, phone, camcorder...) at my LED desk lamp or its light reflected off an object (only if the object is very reflective and/or near the lamp), I see some scrolling black lines that shift thickness and scrolling speed as I change white balance.

What is the cause of this?

Pulse width modulation. A common way to vary the brightness of LED lights is to turn them on and off rapidly. The duty cycle, or the percentage of time when the light is on, determines the brightness. I assume that when you say you're changing the "white balance," you mean that you're actually adjusting the lamp and not the camera. Decreasing the brightness of the lamp will result in wider black bars because the lamp spends more time off.

Finally, my bedside lamp - also LED - creates no such phenomenon.

The difference may simply be that your bedside lamp isn't dimmable, and so always runs at full brightness and, effectively, 100% duty cycle.

Another difference may be in the way your bedside lamp is powered compared to your desk and ceiling lights. High-power LEDs are typically powered with a constant current driver, which prevents too much current from flowing through the LED modules and causing them to overheat. Lower-power LEDs, like those found in strip lights or lamps that use dozens of small LEDs instead of a few large ones, can be powered with constant voltage drivers instead. In this case, a current-limiting resistor or just the combined internal resistance of a number of LEDs powered in series can limit the amount of current that flows and keep the LEDs from overheating. So, your bedside lamp might use a constant voltage driver (or even just a battery) that doesn't work by turning the light off part of the time.


Creating an answer as I don't have enough rep. to add to another answer...

The issue is that the LEDs are flickering, either at 2x mains frequency, or at a (probably much higher) PWM speed.

The solution is either to use another light source, or to alter the frame rate of your camera – not the shutter speed. I encountered this issue a while ago on a laptop screen which flickered at 60fps. Unfortunately, my main cameras weren't capable of 30fps frame rate, only 24, 25, or 29.97. Another camera offered a true 30fps, and problem solved. Similarly, lots of lights in the UK flicker at 50 or 100Hz; setting the camera to any multiple of 50Hz (25, 50, even 200 for slow-motion) solves this.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.