Skip to content

Commit

Permalink
UNPACK_COLORSPACE_CONVERSION_WEBGL now applies to all inputs, not jus…
Browse files Browse the repository at this point in the history
…t images.

Fixes #3683.
  • Loading branch information
kdashg committed Sep 5, 2024
1 parent eeeb020 commit 7f19b19
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions specs/latest/1.0/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -2769,7 +2769,7 @@ <h4>Texture objects</h4>

First, the source image data is conceptually converted to the color space specified by
the <a href="#DOM-WebGLRenderingContext-unpackColorSpace">unpackColorSpace</a>
attribute, except if the source image data is an <code>HTMLImageElement</code>, and
attribute, except if the
the <code>UNPACK_COLORSPACE_CONVERSION_WEBGL</code> pixel storage parameter is set
to <code>NONE</code>. <br><br>

Expand Down Expand Up @@ -4125,10 +4125,12 @@ <h3><a name="PIXEL_STORAGE_PARAMETERS">Pixel Storage Parameters</a></h3>

<dt><code>UNPACK_COLORSPACE_CONVERSION_WEBGL</code> of type <code>unsigned long</code>
<dd>If set to <code>BROWSER_DEFAULT_WEBGL</code>, then the browser's default colorspace conversion
is applied during subsequent <code>texImage2D</code> and <code>texSubImage2D</code> calls
taking <code>HTMLImageElement</code>. The precise conversions may be specific to both the browser
and file type. If set to <code>NONE</code>, no colorspace conversion is applied. The initial value
is <code>BROWSER_DEFAULT_WEBGL</code>.
is applied during subsequent <code>texImage2D</code> and <code>texSubImage2D</code> calls.
(For example, converting a display-p3 image to srgb)
The precise conversions may be specific to both the browser and file type.
If set to <code>NONE</code>, no colorspace conversion is applied, other than conversion to RGBA.
(For example, a rec709 YUV video is still converted to rec709 RGB data, but not then converted to e.g. srgb RGB data)
The initial value is <code>BROWSER_DEFAULT_WEBGL</code>.

</dl>

Expand Down

0 comments on commit 7f19b19

Please sign in to comment.