Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
 help / color / mirror / Atom feed
* [FFmpeg-devel] Native jpeg2000 encoder produces random color artifacts with 12-bit YUV422P12 HDR content
@ 2026-02-23 11:03 Domenico Del Monaco via ffmpeg-devel
  0 siblings, 0 replies; only message in thread
From: Domenico Del Monaco via ffmpeg-devel @ 2026-02-23 11:03 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Domenico Del Monaco

[-- Attachment #1: Type: text/plain, Size: 1438 bytes --]

## Description
The native `jpeg2000` encoder produces random green/red pixel artifacts 
when encoding 12-bit YUV422P12 HDR content via AviSynth input.

The issue is reproducible regardless of:
- dithering settings (error_diffusion, ordered, none)
- q:v parameter (with or without)
- FFmpeg limiter filter

The same pipeline using `libopenjpeg` produces correct output with no 
artifacts.

## Command that produces artifacts
ffmpeg -i input.avs -c:v jpeg2000 -q:v 1 -pix_fmt yuv422p12le 
-colorspace bt2020nc -color_trc smpte2084 -color_primaries bt2020 
-color_range limited -y -f mxf output.mxf

## Command that works correctly
ffmpeg -i input.avs -c:v libopenjpeg -compression_level 6 -pix_fmt 
yuv422p12le -colorspace bt2020nc -color_trc smpte2084 -color_primaries 
bt2020 -color_range limited -y -f mxf output.mxf

## Input pipeline
AviSynth script with Dolby Vision FEL content processed via DoViBaker 
plugin.
Output is RGB converted to YUV422P12 via z_ConvertFormat:
colorspace_op="rgb:st2084:2020:full=>2020ncl:st2084:2020:limited"
dither_type="error_diffusion"

## Expected behavior
Clean 12-bit output identical to libopenjpeg output.

## Actual behavior
Random green/red pixel artifacts scattered randomly across frames.
Artifacts are visible in DaVinci Resolve and media players.
Artifacts change position randomly between frames.

## FFmpeg version 8.01

I am attaching an image of the bug detected.

Thank you

Domenico





[-- Attachment #2: Artifacts ffmpeg jpeg2000.png --]
[-- Type: image/png, Size: 756765 bytes --]

[-- Attachment #3: Type: text/plain, Size: 163 bytes --]

_______________________________________________
ffmpeg-devel mailing list -- ffmpeg-devel@ffmpeg.org
To unsubscribe send an email to ffmpeg-devel-leave@ffmpeg.org

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2026-02-24 22:08 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-02-23 11:03 [FFmpeg-devel] Native jpeg2000 encoder produces random color artifacts with 12-bit YUV422P12 HDR content Domenico Del Monaco via ffmpeg-devel

Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
		ffmpegdev@gitmailbox.com
	public-inbox-index ffmpegdev

Example config snippet for mirrors.


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git