<div dir="auto"><div>Hi Don,</div><div dir="auto"><br></div><div dir="auto">Here is the relevant glTF reference:</div><div dir="auto"><br></div><div dir="auto"><a href="https://registry.khronos.org/glTF/specs/2.0/glTF-2.0.html#images">https://registry.khronos.org/glTF/specs/2.0/glTF-2.0.html#images</a></div><div dir="auto"><br></div><div dir="auto">"<span style="color:rgb(34,34,34);font-size:16px;background-color:rgb(255,255,255)">Any colorspace information (such as ICC profiles, intents, gamma values, etc.) from PNG or JPEG images </span><strong style="line-height:inherit;color:rgb(34,34,34);font-size:16px;background-color:rgb(255,255,255)">MUST</strong><span style="color:rgb(34,34,34);font-size:16px;background-color:rgb(255,255,255)"> be ignored. Effective transfer function (encoding) is defined by a glTF object that refers to the image (in most cases it’s a texture that is used by a material)."</span></div><div dir="auto"><font color="#222222"><span style="font-size:16px"><br></span></font></div><div dir="auto"><font color="#222222"><span style="font-size:16px">There may be an github issue discussing this decision as well.</span></font></div><div dir="auto"><font color="#222222"><span style="font-size:16px"><br></span></font></div><div dir="auto"><font color="#222222"><span style="font-size:16px">Best regards, </span></font></div><div dir="auto"><font color="#222222"><span style="font-size:16px"><br></span></font></div><div dir="auto"><font color="#222222"><span style="font-size:16px">Andreas<br></span></font><br><div class="gmail_quote" dir="auto"><div dir="ltr" class="gmail_attr">On Thu, Sep 21, 2023, 6:54 AM Brutzman, Donald (Don) (CIV) <<a href="mailto:brutzman@nps.edu">brutzman@nps.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div lang="EN-US" link="#0563C1" vlink="#954F72" style="word-wrap:break-word"><div class="m_-1000685623174348905WordSection1"><p class="MsoNormal">Thanks for an interesting candidate capability.  Some references:<u></u><u></u></p><p class="MsoNormal"><u></u> <u></u></p><ul style="margin-top:0in" type="disc"><li class="m_-1000685623174348905MsoListParagraph" style="margin-left:0in">Wikipedia: Color space<u></u><u></u></li><li class="m_-1000685623174348905MsoListParagraph" style="margin-left:0in"><a href="https://en.wikipedia.org/wiki/Color_space" target="_blank" rel="noreferrer">https://en.wikipedia.org/wiki/Color_space</a><u></u><u></u></li></ul><p class="MsoNormal"><u></u> <u></u></p><ul style="margin-top:0in" type="disc"><li class="m_-1000685623174348905MsoListParagraph" style="margin-left:0in">Wikipedia: List of color spaces and their uses<u></u><u></u></li><li class="m_-1000685623174348905MsoListParagraph" style="margin-left:0in"><a href="https://en.wikipedia.org/wiki/List_of_color_spaces_and_their_uses" target="_blank" rel="noreferrer">https://en.wikipedia.org/wiki/List_of_color_spaces_and_their_uses</a><u></u><u></u></li></ul><p class="MsoNormal"><u></u> <u></u></p><p class="MsoNormal">From glTF 2.0<u></u><u></u></p><p class="MsoNormal"><u></u> <u></u></p><ul style="margin-top:0in" type="disc"><li class="m_-1000685623174348905MsoListParagraph" style="margin-left:0in">3.9.3. Additional Textures<u></u><u></u></li><li class="m_-1000685623174348905MsoListParagraph" style="margin-left:0in">emissive : The emissive texture and factor control the color and intensity of the light being emitted by the material. The texture MUST contain 8-bit values encoded with the sRGB opto-electronic transfer function so RGB values MUST be decoded to real linear values before they are used for any computations. To achieve correct filtering, the transfer function SHOULD be decoded before performing linear interpolation.<u></u><u></u></li><li class="m_-1000685623174348905MsoListParagraph" style="margin-left:0in"><a href="https://registry.khronos.org/glTF/specs/2.0/glTF-2.0.html#additional-textures" target="_blank" rel="noreferrer">https://registry.khronos.org/glTF/specs/2.0/glTF-2.0.html#additional-textures</a><u></u><u></u></li><li class="m_-1000685623174348905MsoListParagraph" style="margin-left:0in">References<u></u><u></u></li><li style="color:#222222;margin-top:0in;margin-bottom:4.5pt;background:white"><span style="font-size:10.0pt;font-family:"Arial",sans-serif">IEC 61966-2-1 <em><span style="font-family:"Arial",sans-serif">Default RGB colour space - sRGB</span></em> <a href="https://webstore.iec.ch/publication/6169" target="_blank" rel="noreferrer"><span style="color:#0068b0;text-decoration:none">https://webstore.iec.ch/publication/6169</span></a><u></u><u></u></span></li></ul><table border="0" cellpadding="0" width="622" style="width:466.5pt;box-sizing:border-box;border-spacing:0px"><tbody><tr style="box-sizing:border-box"><td width="80" style="width:60.0pt;padding:6.75pt 7.5pt 6.75pt 7.5pt;box-sizing:border-box;font-size:inherit;display:table-cell"></td><td style="border:none;border-left:solid #dddddd 1.0pt;padding:6.75pt 15.0pt 6.75pt 13.5pt;box-sizing:border-box;font-size:inherit;display:table-cell"><p class="MsoNormal"><span style="font-size:9.0pt;color:black">Note<u></u><u></u></span></p><p style="margin:0in;box-sizing:border-box"><span style="font-size:9.0pt;color:#365e7a">The encoding characteristics of sRGB are freely available from ICC: <a href="https://www.color.org/chardata/rgb/srgb.xalter" target="_blank" rel="noreferrer"><span style="color:#0068b0;text-decoration:none">https://www.color.org/chardata/rgb/srgb.xalter</span></a><u></u><u></u></span></p></td></tr></tbody></table><ul style="margin-top:0in" type="disc"><li class="m_-1000685623174348905MsoListParagraph" style="margin-left:0in">(which is at International Color Consortium)<u></u><u></u></li></ul><p class="MsoNormal"><u></u> <u></u></p><p class="MsoNormal">Additional references welcome<u></u><u></u></p><p class="MsoNormal"><u></u> <u></u></p><p class="MsoNormal">Each mention of color profile that I found in glTF indicated that SRGB profile usage was required.  Didn’t see any other options.  Wondering if there is further work in glTF extensions on this topic.<u></u><u></u></p><p class="MsoNormal"><u></u> <u></u></p><p class="MsoNormal">Prior attempts to permit gamma definition in X3D did not converge on an acceptable solution.<u></u><u></u></p><p class="MsoNormal"><u></u> <u></u></p><p class="MsoNormal">I did not find relevant mention of “color space” or “SRGB” in X3D 4.0 specification.<u></u><u></u></p><p class="MsoNormal"><u></u> <u></u></p><p class="MsoNormal">If we can align with other standards, particularly glTF evolution, then this field certainly seems like a candidate to become a Web3D Consortium Recommended Practice in anticipation of future X3D 4.1 Architecture.  No doubt we would want to look carefully across the specification to ensure that color was handled consistently and interoperably.<u></u><u></u></p><p class="MsoNormal"><u></u> <u></u></p><p class="MsoNormal">Continued scrutiny and development welcome.  Have fun with X3D color control!  8)<u></u><u></u></p><div><p class="MsoNormal"><span style="font-size:9.0pt;font-family:"Courier New""><u></u> <u></u></span></p><p class="MsoNormal"><span style="font-size:9.0pt;font-family:"Courier New"">all the best, Don<u></u><u></u></span></p><p class="MsoNormal"><span style="font-size:9.0pt;font-family:"Courier New"">-- <u></u><u></u></span></p><p class="MsoNormal"><span style="font-size:9.0pt;font-family:"Courier New"">Don Brutzman  Naval Postgraduate School, Code USW/Br        <a href="mailto:brutzman@nps.edu" target="_blank" rel="noreferrer">brutzman@nps.edu</a><u></u><u></u></span></p><p class="MsoNormal"><span style="font-size:9.0pt;font-family:"Courier New"">Watkins 270,  MOVES Institute, Monterey CA 93943-5000 USA    +1.831.656.2149<u></u><u></u></span></p><p class="MsoNormal"><span style="font-size:9.0pt;font-family:"Courier New"">X3D graphics, virtual worlds, navy robotics <a href="https://faculty.nps.edu/brutzman" target="_blank" rel="noreferrer">https://faculty.nps.edu/brutzman</a><u></u><u></u></span></p></div><p class="MsoNormal"><u></u> <u></u></p><div><div style="border:none;border-top:solid #e1e1e1 1.0pt;padding:3.0pt 0in 0in 0in"><p class="MsoNormal"><b>From:</b> x3d-public <<a href="mailto:x3d-public-bounces@web3d.org" target="_blank" rel="noreferrer">x3d-public-bounces@web3d.org</a>> <b>On Behalf Of </b>Holger Seelig<br><b>Sent:</b> Thursday, September 21, 2023 3:06 AM<br><b>To:</b> Andreas Plesch <<a href="mailto:andreasplesch@gmail.com" target="_blank" rel="noreferrer">andreasplesch@gmail.com</a>><br><b>Cc:</b> X3D <<a href="mailto:x3d-public@web3d.org" target="_blank" rel="noreferrer">x3d-public@web3d.org</a>><br><b>Subject:</b> Re: [x3d-public] Need for colorspaceConversion field in ImageTexture, glTF compatibility<u></u><u></u></p></div></div><p class="MsoNormal"><u></u> <u></u></p><div><p class="MsoNormal">I have now also added the field `colorSpaceConversion` in X_ITE to the ImageTexture node, also in the same notation. Everything was already prepared for it.<u></u><u></u></p></div><div><p class="MsoNormal"><u></u> <u></u></p></div><div><p class="MsoNormal">I can't show an example yet, because everything is still in the dev branch.<u></u><u></u></p></div><div><p class="MsoNormal"><u></u> <u></u></p></div><div><p class="MsoNormal">The signature of the new field looks like this:<u></u><u></u></p></div><div><p class="MsoNormal"><span style="font-size:8.5pt;color:black;background:white"><br><br></span><u></u><u></u></p></div><div><p class="MsoNormal"><span style="font-size:8.5pt;color:black;background:white">SFBool [] colorSpaceConversion TRUE</span><u></u><u></u></p></div><div><p class="MsoNormal"><u></u> <u></u></p></div><div><p class="MsoNormal">Best regards,<u></u><u></u></p></div><div><p class="MsoNormal">Holger<u></u><u></u></p></div><div><p class="MsoNormal"><u></u> <u></u></p></div><div><div><div><div><div><div><div><div><p class="MsoNormal"><span style="color:black">--<u></u><u></u></span></p></div><div><p class="MsoNormal"><span style="color:black">Holger Seelig<u></u><u></u></span></p></div><div><p class="MsoNormal"><span style="color:black">Leipzig, Germany<u></u><u></u></span></p></div><div><p class="MsoNormal"><span style="color:black"><u></u> <u></u></span></p></div><div><p class="MsoNormal"><span style="color:black"><a href="mailto:holger.seelig@yahoo.de" target="_blank" rel="noreferrer">holger.seelig@yahoo.de</a><u></u><u></u></span></p></div><div><p class="MsoNormal"><span style="color:black"><a href="https://create3000.github.io/x_ite/" target="_blank" rel="noreferrer">https://create3000.github.io/x_ite/</a><u></u><u></u></span></p></div></div></div></div></div></div></div></div><div><p class="MsoNormal"><br><br><u></u><u></u></p><blockquote style="margin-top:5.0pt;margin-bottom:5.0pt"><div><p class="MsoNormal">Am 21.09.2023 um 08:26 schrieb Andreas Plesch <<a href="mailto:andreasplesch@gmail.com" target="_blank" rel="noreferrer">andreasplesch@gmail.com</a>>:<u></u><u></u></p></div><p class="MsoNormal"><u></u> <u></u></p><div><div><p class="MsoNormal">Coming back to color profiles potentially embedded in some important<br>image formats, I added a colorSpaceConversion field to ImageTexture in<br>x3dom:<br><br><a href="https://andreasplesch.github.io/x3dom/dist/doc/author/Texturing/ImageTexture.html" target="_blank" rel="noreferrer">https://andreasplesch.github.io/x3dom/dist/doc/author/Texturing/ImageTexture.html</a><br><br>It is by default true for normal X3D use and can be false for loading<br>glTF textures correctly:<br><br><a href="https://andreasplesch.github.io/Library/Viewer/index.html?url=https://gist.githubusercontent.com/andreasplesch/817bc44089a7b7545149cf12acdd7c86/raw/75242ebfea03048d0f4939e1656c5063c9544d11/TextureEncodingTest.x3d" target="_blank" rel="noreferrer">https://andreasplesch.github.io/Library/Viewer/index.html?url=https://gist.githubusercontent.com/andreasplesch/817bc44089a7b7545149cf12acdd7c86/raw/75242ebfea03048d0f4939e1656c5063c9544d11/TextureEncodingTest.x3d</a><br><br>It is trivial to change the field name if there are other suggestions.<br><br>-Andreas<br><br>On Tue, Aug 29, 2023 at 1:53 PM Andreas Plesch <<a href="mailto:andreasplesch@gmail.com" target="_blank" rel="noreferrer">andreasplesch@gmail.com</a>> wrote:<br><br><u></u><u></u></p><blockquote style="margin-top:5.0pt;margin-bottom:5.0pt"><p class="MsoNormal"><br>Following up after some work:<br><br>On Thu, Aug 24, 2023 at 11:15 PM Andreas Plesch <<a href="mailto:andreasplesch@gmail.com" target="_blank" rel="noreferrer">andreasplesch@gmail.com</a>> wrote:<br><br><u></u><u></u></p><blockquote style="margin-top:5.0pt;margin-bottom:5.0pt"><p class="MsoNormal"><br>On Thu, Aug 24, 2023 at 9:14 AM Michalis Kamburelis<br><<a href="mailto:michalis.kambi@gmail.com" target="_blank" rel="noreferrer">michalis.kambi@gmail.com</a>> wrote:<br><br><u></u><u></u></p><blockquote style="margin-top:5.0pt;margin-bottom:5.0pt"><p class="MsoNormal"><br>1. As for colorspaceConversion:<br><br>I don't think we want to avoid adding X3D field for this :)<u></u><u></u></p></blockquote><p class="MsoNormal"><br>Well, it is worth thinking through options if it means smarter<br>solutions can be discovered.<br><br><br><u></u><u></u></p><blockquote style="margin-top:5.0pt;margin-bottom:5.0pt"><p class="MsoNormal">I'm all after adding X3D field to account for this -- that is, say<br>explicitly whether ICC profile should be honored or not, so that all<br>cases are satisfied. I'm cool with colorspaceConversion name.<u></u><u></u></p></blockquote><p class="MsoNormal"><u></u> <u></u></p></blockquote><p class="MsoNormal" style="margin-bottom:12.0pt">...snip<br><br>After some thought I do think that a new field is needed for<br>ImageTexture (and MovieTexture, and Background ?).<br>"colorspaceConversion" or "colorSpaceConversion" or perhaps something<br>shorter like "colorProfile"  ?<br><br>x3dom will probably use the webgl texture unpacking parameter.<u></u><u></u></p></blockquote></div></div></blockquote></div><p class="MsoNormal"><u></u> <u></u></p></div></div></blockquote></div></div></div>