https://bugs.kde.org/show_bug.cgi?id=476186

            Bug ID: 476186
           Summary: Screen recording quality is terrible
    Classification: Frameworks and Libraries
           Product: KPipeWire
           Version: unspecified
          Platform: Other
                OS: Linux
            Status: REPORTED
          Severity: normal
          Priority: NOR
         Component: general
          Assignee: plasma-b...@kde.org
          Reporter: mar...@marcan.st
                CC: aleix...@kde.org
  Target Milestone: ---

Screen recording quality in Spectacle is bad to the point of being unusable for
anything more than casual use.

Selecting quality is a codec, specific issue, but for x264 in particular, the
current code is very questionable:

https://invent.kde.org/plasma/kpipewire/-/blob/master/src/libx264encoder.cpp

This sets `m_avCodecContext->global_quality` from some weird formula, but it's
unclear how that maps to encoder settings in the end within ffmpeg. What I see
in the resulting files is that Average Bitrate mode is being used (rc=abr),
with bitrate somehow varying based on dimensions. This is a very bad choice for
x264.

The correct "just give me a given quality please" mode in x264 is CRF (constant
rate factor) mode, which does not force any given bitrate but rather targets a
specific visual quality. If the quality settings are not configurable (or not
configurable beyond a simple quality slider), then that mode should be the
default to give decent output without more fuss. CRF mode is
resolution-independent, and will automatically scale bitrate depending on the
requirements (video size, motion complexity, etc.). It's the best option to
default to for most users.

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to