[x3d-public] TextureCoordinate point range…should be reduced?

John Carlson yottzumm at gmail.com
Tue Nov 28 10:08:34 PST 2023


Thanks, Michalis, helpful!

John

On Tue, Nov 28, 2023 at 11:07 AM Michalis Kamburelis <
michalis.kambi at gmail.com> wrote:

> Any texture coordinate value is valid, even negative, even -9999, and
> you can find 3D models indeed using them. That's true for any 3D
> software, format and API (Blender, X3D, glTF, OpenGL..).
>
> The interpretation of values outside of 0..1 range indeed depends on
> the "repeatS" / "repeatT" / "repeatR" (for 3D textures) values. The
> specification already explains this, see
>
> https://www.web3d.org/specifications/X3Dv4Draft/ISO-IEC19775-1v4-CD/Part01/components/texturing.html#TextureCoordinates
> , "18.2.3 Texture coordinates".
>
> Note that TextureProperties node, if present, overrides the
> "repeat..." fields, with a bit more capable "boundaryMode...", see
>
> https://www.web3d.org/specifications/X3Dv4Draft/ISO-IEC19775-1v4-CD/Part01/components/texturing.html#TextureProperties
> . See also CGE / view3dscene docs,
> https://castle-engine.io/x3d_implementation_texturing.php , where we
> explain what we support (and why we do not plan to support "clamp to
> border", but we support all else).
>
> Regards,
> Michalis
>
> sob., 25 lis 2023 o 06:15 John Carlson via x3d-public
> <x3d-public at web3d.org> napisał(a):
> >
> > Can someone explain what a negative point value in a TextCoordinate
> means when the texture is an ImageTexture?  Does it have something to do
> with repeatS and repeatT?
> >
> > A section in the spec is ok.
> >
> > Thanks,
> >
> > John
> >
> > On Fri, Nov 24, 2023 at 10:32 PM John Carlson <yottzumm at gmail.com>
> wrote:
> >>
> >> 18.4.7 TextureCoordinate
> >>
> >> TextureCoordinate : X3DSingleTextureCoordinateNode {
> >>   SFString [in,out] mapping  ""
> >>   SFNode   [in,out] metadata NULL [X3DMetadataObject]
> >>   MFVec2f  [in,out] point    []   (-∞,∞)
> >> }
> >>
> >>
> >> I ran into a case where I was expecting texture coordinate point values
> from [0,1] in a texture mapping file, and I got values like -99999 an other
> negative values, which cause me to ignore the triangles and totally foul up
> the texture.  At this point, I don’t know what negative values mean in a
> texture coordinate point value and what I should accept for an IFS.  It
> seems like -99999 is dreadfully wrong, but per the spec above, any float
> value is acceptable.  I will check the IFS spec, but if no one has a use
> case, I recommend reducing the range of the texture coordinate point values.
> >
> > _______________________________________________
> > x3d-public mailing list
> > x3d-public at web3d.org
> > http://web3d.org/mailman/listinfo/x3d-public_web3d.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20231128/4390b888/attachment-0001.html>


More information about the x3d-public mailing list