#111703 – VSE and ffmpeg: Banding and color shift – blender
System Information
Operating system: Linux-6.1.38.12.realtime1-4-rt-lts-x86_64-with-glibc2.38 64 Bits, X11 UI
Graphics card: AMD Radeon R9 M370X (verde, LLVM 15.0.7, DRM 3.49, 6.1.38.12.realtime1-4-rt-lts)
Blender Version
version: 3.6.0, branch: makepkg (modified), commit date: 2023-06-27 08:08, hash: c7fc78b81ecb
Short description of error
Blender’s viewport and renders to PNG present a different image to the original video file, introducing ‘banding’ (aka. pixel regions) and a slight color shift.
Strange enough, the same results when transcoding the video to PNG directly, using the following command: ffmpeg -i C0441.MP4 -vf fps=1 C0441.png
However, the video file is shown correctly by ffplay! Other softwares, some of them explicitly ffmpeg based, also show the video correctly. Please compare banding in the samples below (sorry for the amount of pictures and mentions to softwares). This is the 1st frame of a clip I made intentionally in conditions that produce heavy banding.
CORRECT
Kdenlive export to PNG, ffmpeg v6 (Linux)
Shotcut export to PNG, ffmpeg v6 (Linux)
Adobe Premiere export to PNG (OSX)
Davinci Resolve export to PNG (OSX)
ffplay screenshot, ffmpeg v4.3 (OSX)
ffplay screenshot, ffmpeg v6 (Linux)
INCORRECT
Blender export to PNG, ffmpeg6 (OSX)
Blender export to PNG, ffmpeg4.3 (OSX)
As you can see, gradients on the background are much more patchy in the second group.
Original h.264 video file (6sec, 40MB).
C0441.MP4
This is footage from a Sony A7s2 camera. But I just tried with AVCHD files from an old Panny and the same happens. In brighter footage a color shift can be appreciated on simple sight.
I’m very puzzled with this and wonder what an explanation would be. I hope others can confirm the effect.
Exact steps for others to reproduce the error
- Download the video file and run it in ffplay. If you press space and then the back-arrow ffplay will stick to the 1st frame.
- Import the file to blender and compare the banding of the first frame to the one shown in ffplay.
**System Information**
Operating system: Linux-6.1.38.12.realtime1-4-rt-lts-x86_64-with-glibc2.38 64 Bits, X11 UI
Graphics card: AMD Radeon R9 M370X (verde, LLVM 15.0.7, DRM 3.49, 6.1.38.12.realtime1-4-rt-lts)
**Blender Version**
version: 3.6.0, branch: makepkg (modified), commit date: 2023-06-27 08:08, hash: `c7fc78b81ecb`
**Short description of error**
Blender’s viewport and renders to PNG present a different image to the original video file, introducing ‘banding’ (aka. pixel regions) and a slight color shift.
Strange enough, the same results when transcoding the video to PNG directly, using the following command: ffmpeg -i C0441.MP4 -vf fps=1 C0441.png
However, the video file is shown correctly by ffplay! Other softwares, some of them explicitly ffmpeg based, also show the video correctly. Please compare banding in the samples below (sorry for the amount of pictures and mentions to softwares). This is the 1st frame of a clip I made intentionally in conditions that produce heavy banding.
**CORRECT**

_Kdenlive export to PNG, ffmpeg v6 (Linux)_

_Shotcut export to PNG, ffmpeg v6 (Linux)_

_Adobe Premiere export to PNG (OSX)_

_Davinci Resolve export to PNG (OSX)_

_ffplay screenshot, ffmpeg v4.3 (OSX)_

_ffplay screenshot, ffmpeg v6 (Linux)_
**INCORRECT**

_ffmpeg cli 4.3 to png (OSX)_

_ffmpeg cli 6 to png (Linux)_

_Blender export to PNG, ffmpeg6 (OSX)_

_Blender export to PNG, ffmpeg4.3 (OSX)_
As you can see, gradients on the background are much more patchy in the second group.
Original h.264 video file (6sec, 40MB).
<video src=”/attachments/316cd50a-4adc-4ae8-8ba7-08945a79183a” title=”C0441.MP4″ controls></video>
[C0441.MP4](/attachments/316cd50a-4adc-4ae8-8ba7-08945a79183a)
This is footage from a Sony A7s2 camera. But I just tried with AVCHD files from an old Panny and the same happens. In brighter footage a color shift can be appreciated on simple sight.
I’m very puzzled with this and wonder what an explanation would be. I hope others can confirm the effect.
**Exact steps for others to reproduce the error**
1. Download the video file and run it in ffplay. If you press space and then the back-arrow ffplay will stick to the 1st frame.
2. Import the file to blender and compare the banding of the first frame to the one shown in ffplay.
Read more here: Source link
