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

Add WCG color spaces. #566

Merged
merged 1 commit into from
Oct 19, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 48 additions & 12 deletions index.src.html
Original file line number Diff line number Diff line change
Expand Up @@ -4461,9 +4461,11 @@

<xmp class='idl'>
enum VideoColorPrimaries {
"bt709", // BT.709, sRGB
"bt470bg", // BT.601 PAL
"smpte170m", // BT.601 NTSC
"bt709",
"bt470bg",
"smpte170m",
"bt2020",
"smpte432",
};
</xmp>

Expand All @@ -4483,6 +4485,16 @@
Color primaries used by BT.601 NTSC, as described by [[H.273]]
section 8.1 table 2 value 6.
</dd>
<dt><dfn enum-value for=VideoColorPrimaries>bt2020</dfn></dt>
<dd>
Color primaries used by BT.2020 and BT.2100, as described by [[H.273]]
section 8.1 table 2 value 9.
</dd>
<dt><dfn enum-value for=VideoColorPrimaries>smpte432</dfn></dt>
<dd>
Color primaries used by P3 D65, as described by [[H.273]]
section 8.1 table 2 value 12.
</dd>
</dl>

Video Transfer Characteristics {#videotransfercharacteristics}
Expand All @@ -4492,9 +4504,12 @@

<xmp class='idl'>
enum VideoTransferCharacteristics {
"bt709", // BT.709
"smpte170m", // BT.601 (functionally the same as bt709)
"iec61966-2-1", // sRGB
"bt709",
"smpte170m",
"iec61966-2-1",
"linear",
"pq",
"hlg",
Copy link
Contributor Author

Choose a reason for hiding this comment

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

The alternative names here are "smpte2084" and "arib-std-b67", which would align with FFmpeg naming.

Copy link
Member

Choose a reason for hiding this comment

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

Looks OK as is, but if you're considering changing, I'd suggest referencing BT2100, so something like bt2100-2-pq and bt2100-2-hlg.

Copy link
Contributor

Choose a reason for hiding this comment

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

Is that more legible? Even Wikipedia just calls it PQ/HLG.

Copy link
Member

@chrisn chrisn Oct 19, 2022

Choose a reason for hiding this comment

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

To clarify, my preference is for pq and hlg

Copy link
Contributor

Choose a reason for hiding this comment

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

Ah great :) I think Dan was just playing devils advocate above.

Copy link
Member

Choose a reason for hiding this comment

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

I see! My comment was really: if you're going in that direction, prefer BT.2100 rather than the SMPTE and ARIB standards.

};
</xmp>

Expand All @@ -4507,13 +4522,28 @@
<dt><dfn enum-value for=VideoTransferCharacteristics>smpte170m</dfn></dt>
<dd>
Transfer characteristics used by BT.601, as described by [[H.273]]
section 8.2 table 3 value 6.
section 8.2 table 3 value 6. (Functionally the same as "bt709".)
</dd>
<dt><dfn enum-value for=VideoTransferCharacteristics>iec61966-2-1</dfn></dt>
<dd>
Transfer characteristics used by sRGB, as described by [[H.273]]
section 8.2 table 3 value 13.
</dd>
<dt><dfn enum-value for=VideoTransferCharacteristics>linear</dfn></dt>
<dd>
Transfer characteristics used by linear RGB, as described by [[H.273]]
section 8.2 table 3 value 8.
</dd>
<dt><dfn enum-value for=VideoTransferCharacteristics>pq</dfn></dt>
<dd>
Transfer characteristics used by BT.2100 PQ, as described by [[H.273]]
section 8.2 table 3 value 16.
</dd>
<dt><dfn enum-value for=VideoTransferCharacteristics>hlg</dfn></dt>
<dd>
Transfer characteristics used by BT.2100 HLG, as described by [[H.273]]
section 8.2 table 3 value 18.
</dd>
</dl>

Video Matrix Coefficients {#videomatrixcoefficients}
Expand All @@ -4523,10 +4553,11 @@

<xmp class='idl'>
enum VideoMatrixCoefficients {
"rgb", // sRGB
"bt709", // BT.709
"bt470bg", // BT.601 PAL
"smpte170m", // BT.601 NTSC (functionally the same as bt470bg)
"rgb",
"bt709",
"bt470bg",
"smpte170m",
"bt2020-ncl",
};
</xmp>

Expand All @@ -4549,7 +4580,12 @@
<dt><dfn enum-value for=VideoMatrixCoefficients>smpte170m</dfn></dt>
<dd>
Matrix coefficients used by BT.601 NTSC, as described by [[H.273]]
section 8.3 table 4 value 6.
section 8.3 table 4 value 6. (Functionally the same as "bt470bg".)
</dd>
<dt><dfn enum-value for=VideoMatrixCoefficients>bt2020-ncl</dfn></dt>
<dd>
Matrix coefficients used by BT.2020 NCL, as described by [[H.273]]
section 8.3 table 4 value 9.
</dd>
</dl>

Expand Down