Skip to content

COM-14536 - videocodectestsink errors in Y42B with GStreamer=1.20.x#343

Open
rsanchez87 wants to merge 1 commit intomasterfrom
COM-14536
Open

COM-14536 - videocodectestsink errors in Y42B with GStreamer=1.20.x#343
rsanchez87 wants to merge 1 commit intomasterfrom
COM-14536

Conversation

@rsanchez87
Copy link
Contributor

@rsanchez87 rsanchez87 commented Mar 24, 2026

Issue

Test vectors with YUV422 output format (yuv422p, yuv422p10le, yuv422p12le) fail on GStreamer 1.20.x:

could not link videoconvert0 to videocodectestsink0,
videocodectestsink0 can't handle caps video/x-raw, format=(string)Y42B

videocodectestsink only gained YUV422 support in GStreamer 1.22.0
(MR !3331).

Verification

Suite GStreamer Result
JVT-FR-EXT — YUV422 vectors (21) 1.20.3 21/21 ✅ (filesink fallback)
JVT-FR-EXT — all vectors (69) 1.20.3 62/69 ✅ (7 pre-existing decoder failures, all YUV420)
JVT-FR-EXT — all vectors (69) 1.24.2 69/69 ✅ (videocodectestsink, no regression)

@rsanchez87 rsanchez87 marked this pull request as ready for review March 24, 2026 14:27
@rsanchez87 rsanchez87 changed the title COM-14536 - videocodectestsink results in errors when pixel format is Y42B with GStreamer 1.20.3 COM-14536 - videocodectestsink errors in Y42B with GStreamer 1.20.3 Mar 24, 2026
@rsanchez87 rsanchez87 changed the title COM-14536 - videocodectestsink errors in Y42B with GStreamer 1.20.3 COM-14536 - videocodectestsink errors in Y42B with GStreamer < 1.22 Mar 24, 2026
@rsanchez87 rsanchez87 changed the title COM-14536 - videocodectestsink errors in Y42B with GStreamer < 1.22 COM-14536 - videocodectestsink errors in Y42B with GStreamer=1.20.x Mar 24, 2026
self.decoder_bin,
caps,
self.sink,
self._get_sink_for_format(output_format),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You are replacing the sink inside gen_pipeline and inside decode.

IMHO Doing it in just one place is enough.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

More above something like?:

    def _get_sink_for_format(self, output_format: OutputFormat) -> str:  # pylint: disable=unused-argument
        return self.sink

and...

if self._get_sink_for_format(output_format) == "videocodectestsink": ?

removing decode

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested ✔️

"""Decode the test vector and do the checksum."""
original_sink = self.sink
self.sink = self._get_sink_for_format(output_format)
try:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this try needed?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, with previous changes

…ith GStreamer 1.20.3

- videocodectestsink did not support YUV422 formats (Y42B, I422_10LE,
I422_12LE) until GStreamer 1.22.0 (MR !3331). On GStreamer 1.20.x
- Detect the installed GStreamer version at runtime and fall back to
filesink for those formats when the version is older than 1.22.0.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants