Feature Request: Expose missing x265 sao & deblock params in GUI

Started by manfredk, October 08, 2026, 01:39:01 PM

Previous topic - Next topic

manfredk

[Feature Request] Add fine-grained x265 GUI controls for --deblock, --sao, and --sao-non-deblock

Hi team,

I would like to request an enhancement for the x265 video encoder GUI in Avidemux regarding the Deblock and SAO (Sample Adaptive Offset) settings.

Currently, the GUI only provides basic toggle options (checkboxes) to disable these filters, but lacks fine-tuning parameters that are crucial for specific encoding scenarios (such as capturing interlaced analog video sources, tape digitizations, or lower-bitrate DVB streams).

Missing / Limited Settings:

1. Deblock Filter (--deblock)

• Current state: Only available as a binary toggle/checkbox (Disable Deblock).

• Requested feature: Expose the two offset parameters Alpha (tcOffset) and Beta (betaOffset).

• Corresponding FFmpeg / x265 CLI parameters:
-x265-params deblock=<cbOffset>:<crOffset> (e.g. -x265-params deblock=-1:-1)
2. Sample Adaptive Offset (--sao)   

• Current state: Only available as a binary toggle/checkbox (Disable SAO).

• Requested feature: Allow further customization of SAO behavior (e.g. mode selection, limit-sao, or custom thresholds) instead of just a global ON/OFF switch.

• Corresponding FFmpeg / x265 CLI parameters:
-x265-params sao=1 / sao=0 and -x265-params limit-sao=1
3. SAO Non-Deblock Handling (--sao-non-deblock)   

• Current state: Missing completely from the GUI.

• Requested feature: Add a toggle/setting to specify how SAO handles dependency on deblocked edge pixels.

• Corresponding FFmpeg / x265 CLI parameters:   
-x265-params sao-non-deblock=1 / sao-non-deblock=0
Exposing numerical inputs and toggles for these settings in the x265 plugin configuration (and storing them in the plugin JSON config) would give users precise control over fine details and prevent blurring/banding artifacts without relying on external scripts or CLI runs.

Thank you very much for considering this improvement!
And also thanks a lot for your continuous hard work on Avidemux and for keeping this awesome tool alive over all these years!

Best regards,
Manfred

manfredk

Addendum: Specific requirements for archiving analog tape sources (Hi8, S-VHS / Video8, VHS)

To provide further context and technical justification, these requests stem from real-world CLI encoding tests (ffmpeg with libx265) on digitized analog tape media. Analog sources present unique encoding challenges due to tape noise, time-base instability, and chroma bleeding.

To achieve optimal preservation without resorting to external CLI scripts, the following GUI parameters are also needed:

4. Floating-point CRF values (0.1 / 0.5 precision steps)

• Current limitation: The GUI only accepts integer CRF values.

• The issue with analog video: Due to high entropy from analog noise, moving from CRF 18 to 19 causes a massive drop in bitrate and detail. A integer-only scale is too coarse.

• Proposed fix: Change the CRF input field from an integer control to a decimal input (QDoubleSpinBox), allowing values like 18.5 or 19.2. libx265 natively processes double-precision CRF values.

• Corresponding FFmpeg / x265 CLI parameters:
-x265-params crf=18.5 (or -crf 18.5)
5. Chroma QP Offsets (cbqpoffs / crqpoffs) & qcomp

• Current limitation: Not configurable in the Avidemux GUI.

• The issue with analog video: Analog chroma channels contain heavy noise. Being able to fine-tune cbqpoffs and crqpoffs prevents the encoder from wasting bitrate on color bleeding/noise while preserving luminance structure.

• Corresponding FFmpeg / x265 CLI parameters:
-x265-params cbqpoffs=-1:crqpoffs=-1:qcomp=0.60
6. SAO Non-Deblock Handling (`--sao-non-deblock`)

• Current limitation: Completely missing from the Avidemux GUI.

• The issue with analog video: Default SAO interaction with deblocking creates severe haloing and strips away natural tape grain. Being able to explicitly set `sao-non-deblock` prevents smudging fine details on tape captures.

• Corresponding FFmpeg / x265 CLI parameters:
-x265-params sao-non-deblock=1
NB: Tests using native ffmpeg parameters prove that having access to these specific float values and sub-parameters makes a night-and-day difference in visual fidelity for digitized analog media.

Best regards,

Manfred