Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OCP-5946 Fix H266 output format #198

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

carlosfg-flu
Copy link
Contributor

Fix H266 TS output format gray10le32->gray10le16

The proper output format of the decoder is 16b aligned, instead of 32.

We'll add support for GRAY10_LE16 soon, so we'll need to distinguish
between both GRAY10_LE16 and GRAY10_LE32.
The proper output format of the decoder is 16b aligned, instead of 32.
@rgonzalezfluendo
Copy link
Contributor

can you change the status from draft?

@carlosfg-flu carlosfg-flu marked this pull request as ready for review November 12, 2024 18:08
@@ -51,7 +51,8 @@ class OutputFormat(Enum):
GBRP12LE = "gbrp12le"
GBRP14LE = "gbrp14le"
GRAY = "gray"
GRAY10LE = "gray10le"
GRAY10LE16 = "gray10le16"
GRAY10LE32 = "gray10le32"
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't think introducing GRAY10LE32 make any sense here. Please drop.

fyi, this is 3 pixels per 32bit packing, with 2 bit padding, we should nto do conformance on that.

Copy link
Contributor

Choose a reason for hiding this comment

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

I also think we should keep gray10le to match with ffmpeg name, and is 16bit per pixels.

@@ -60,7 +60,8 @@ def output_format_to_gst(output_format: OutputFormat) -> str:
"""Return GStreamer pixel format"""
mapping = {
OutputFormat.GRAY: "GRAY8",
OutputFormat.GRAY10LE: "GRAY10_LE32",
OutputFormat.GRAY10LE16: "GRAY10_LE16",
OutputFormat.GRAY10LE32: "GRAY10_LE32",
Copy link
Contributor

Choose a reason for hiding this comment

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

GRAY10LE16 does not exist in GStreamer, please submit upstream so we have matching names. Should be a single plane variant of GST_VIDEO_FORMAT_I420_10LE. It is incompatible with GRAY16_LE because GRAY10LE padding is on the opposite side.

@ndufresne
Copy link
Contributor

ndufresne commented Dec 10, 2024

I'm pretty sure this breaks FFMPEG, and cannot work in GStreamer yet, since the format has not been introduce. Support in videocodectestsink is needed too, we should allow I420_10LE to GRAY_10LE conversion too, since many decoder produce I420 even if the codec holds monochrome.

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.

3 participants