[x3d-public] New description fields

Michalis Kamburelis michalis.kambi at gmail.com
Thu Feb 9 14:47:35 PST 2023


1.

> Just reuse the last set on the list to fill out the list.
> What is so bad about that?
> Do you fail if not enough colors?

Reusing the last value of a per-vertex attribute (like texture
coordinate) would be a bit useless, at least in most cases.

Yes, we also throw a warning when there are not enough colors.

This is also following X3D specification, see e.g. IndexedFaceSet:
https://www.web3d.org/specifications/X3Dv4Draft/ISO-IEC19775-1v4-CD/Part01/components/geometry3D.html#IndexedFaceSet

"""
If the greatest index in the coordIndex field is N, the Coordinate
node shall contain N+1 coordinates (indexed as 0 to N).
...
If the greatest index in the colorIndex field is N, then there shall
be N+1 colours in the X3DColorNode node.
...
If the greatest index in the texCoordIndex field is N, then there
shall be N+1 texture coordinates in the X3DTextureCoordinateNode.
...
If the texCoordIndex field is empty, then the coordIndex array is used
to choose texture coordinates from the X3DTextureCoordinateNode node.
If the greatest index in the coordIndex field is N, then there shall
be N+1 texture coordinates in the X3DTextureCoordinateNode node.
"""

All these sentences say a similar thing: if you provide a per-vertex
data, we expect you to provide as much data as you want to index.
Adding a processing on browser side to "reuse the last data" would be
extra work, not necessary in many cases, and it is actually better in
many cases to throw an error in this case. It is better to consider
this "not valid file".

Note that view3dscene still displays the mesh, this is just a warning.

It's not an X3D invention either. glTF, Collada follow this too.

If you want to just reuse the last coordinate, then I guess duplicate
it in TextureCoordinate. But is this really what you want? You want to
have 3 vertexes with texture coordinates like this:

- 0 0
- 0.5 0.5
- 0.5 0

... and then 300+ vertexes with equal texture coordinate 0 0.5 ? This
seems a bit weird texture mapping. If most of vertexes have the same
texture coordinate then most faces will just display a single color
from the texture. This would be valid but rather non-standard use of
textures.

2. HAnimDisplacer is indeed simply not implemented in
view3dscene/Castle Game Engine for now.

3. As for routes, you mention """Also, the item about the route
statements being in a place you don’t like did not get fixed in
4.3.0.""" -- sorry, I do not recall the issue. But I have too many
TODO lists, maybe something slipped my mind. Please refresh my memory,
point me to the thread or bugreport about it.

Regards,
Michalis

czw., 9 lut 2023 o 19:44 Joseph D Williams <joedwil at earthlink.net> napisał(a):
>
> Otherwise X3D browser doesn't know what do you mean --
>
> what texture coordinate is supposed to be associated with vertex with
>
> index 9.
>
>
>
> Yes it does, or it should. Just reuse the last set on the list to fill out the list.
>
> What is so bad about that?
>
>  Do you fail if not enough colors?
>
>
>
> Anyway, the Displacer is not working in 4.3.0 with no errors on that.
>
>
>
> https://www.web3d.org/x3d/content/examples/HumanoidAnimation/Skin/JoeKickIndex.html
>
>
>
> Also, the item about the route statements being in a place you don’t like did not get fixed in 4.3.0.
>
>
>
> Can you or someone please help me with <TextureCoordinate point='0 0 0.5 0.5 0.5 0 0 0.5'/> since I an’t seem to get the right number for happiness even when it seems right and works elsewhere.
>
>
>
> X3D: Invalid number of items in a normal or texture coordinate array for shape "Joe_Humanoid:Joe_Kick:Joe_Shape:IndexedFaceSet(Joe_skin_IndexedFaceSet)": Invalid index: 141, but we have 139 items
>
>
>
>
>
> Even when the numbers match at the correct numver ofverts it fails.
>
> Is this finding something in the texture transform?
>
>
>
> Sure would like to see Displacer working.
>
> Thanks,
>
> Joe
>
>
>
>
>
>
>
> From: Michalis Kamburelis
> Sent: Thursday, February 9, 2023 7:30 AM
> To: Joseph D Williams
> Cc: John Carlson; Don Brutzman; GPU Group; X3D Graphics public mailing list
> Subject: Re: New description fields
>
>
>
> Yes :) I know we had a few communications about this already, so maybe
>
> you already fixed it in some version of the file and it is just not
>
> updated on that page.
>
>
>
> I just report that
>
>
>
>   http://www.web3d.org/x3d/content/examples/HumanoidAnimation/Skin/JoeKick.x3d
>
>
>
> still has this error. Specifically, it contains geometry like this:
>
>
>
>           <IndexedFaceSet DEF='Joe_skin_IndexedFaceSet' coordIndex='0
>
> 9 5 -1 0 7 9 ...' creaseAngle='3.14'>
>
>             <Coordinate DEF='Joe_SkinCoord' point='0.0 1.77 ..../>
>
>             <TextureCoordinate point='0 0 0.5 0.5 0.5 0 0 0.5'/>
>
>           </IndexedFaceSet>
>
>
>
> So you use coordinate index "9" (and larger, later, like 386) ... but
>
> your "TextureCoordinate.point" has only 4 items. So you can only use
>
> indexes 0..3. Otherwise X3D browser doesn't know what do you mean --
>
> what texture coordinate is supposed to be associated with vertex with
>
> index 9.
>
>
>
> Regards,
>
> Michalis
>
>
>
> czw., 9 lut 2023 o 14:48 Joseph D Williams <joedwil at earthlink.net> napisał(a):
>
> >
>
> > > X3D: Invalid number of items in an attribute array for shape
>
> >
>
> > > "Joe_Humanoid/Joe_Kick/Joe_Shape/IndexedFaceSet(Joe_skin_IndexedFaceSet)":
>
> >
>
> > > Invalid index: 9, but we have 4 items in 2D texture coordinates
>
> >
>
> > >
>
> >
>
> > > ... and the error is valid from what I can see. TextureCoordinate has
>
> >
>
> > > too few points.
>
> >
>
> >
>
> >
>
> >
>
> >
>
> > Is this back to telling me I have to have all texcoords for all points?
>
> >
>
> >
>
> >
>
> > Thanks,
>
> >
>
> > Joe
>
> >
>
> >
>
> >
>
> >
>
> >
>
> > From: Michalis Kamburelis
>
> > Sent: Thursday, February 9, 2023 5:23 AM
>
> > To: John Carlson
>
> > Cc: Don Brutzman; GPU Group; Joe D Williams; X3D Graphics public mailing list
>
> > Subject: Re: New description fields
>
> >
>
> >
>
> >
>
> > To other X3D browser implementors adding "description":
>
> >
>
> >
>
> >
>
> > If you also have been implementing RenderedTexture node (not in X3D
>
> >
>
> > spec, but common extension, at least in InstantReality, Xj3d, and
>
> >
>
> > CGE/view3dscene), note that you should remove the
>
> >
>
> > "RenderedTexture.description" field. It can (and should) now inherit
>
> >
>
> > "X3DSingleTextureNode.description".
>
> >
>
> >
>
> >
>
> > Sometimes automatic tests catch real errors :) (This nuance was caught
>
> >
>
> > by CGE automatic tests.)
>
> >
>
> >
>
> >
>
> > Regards,
>
> >
>
> > Michalis
>
> >
>
> >
>
> >
>
> > czw., 9 lut 2023 o 14:04 Michalis Kamburelis
>
> >
>
> > <michalis.kambi at gmail.com> napisał(a):
>
> >
>
> > >
>
> >
>
> > > I added to view3dscene/Castle Game Engine handling of "description" field on
>
> >
>
> > >
>
> >
>
> > > - X3DSingleTextureNode
>
> >
>
> > > - HAnimDisplacer
>
> >
>
> > > - HAnimHumanoid
>
> >
>
> > > - HAnimJoint
>
> >
>
> > > - HAnimSegment
>
> >
>
> > > - HAnimSite
>
> >
>
> > >
>
> >
>
> > > I also added HAnimHumanoid.loa .
>
> >
>
> > >
>
> >
>
> > > As usual, the fix will be available in snapshot view3dscene versions
>
> >
>
> > > on https://castle-engine.io/view3dscene.php (also part of larger CGE
>
> >
>
> > > download, https://castle-engine.io/download ). Please give Jenkins a
>
> >
>
> > > 6-8 hours to process it and run all automated tests.
>
> >
>
> > >
>
> >
>
> > > Note that these "description" fields seem unrelated to
>
> >
>
> > > http://www.web3d.org/x3d/content/examples/HumanoidAnimation/Skin/JoeKick.x3d
>
> >
>
> > > . That file only used "description" on Viewpoint, which we already
>
> >
>
> > > handled.
>
> >
>
> > >
>
> >
>
> > > After adding "HAnimHumanoid.loa", this file reports just this error
>
> >
>
> > > (many times) in view3dscene:
>
> >
>
> > >
>
> >
>
> > > X3D: Invalid number of items in an attribute array for shape
>
> >
>
> > > "Joe_Humanoid/Joe_Kick/Joe_Shape/IndexedFaceSet(Joe_skin_IndexedFaceSet)":
>
> >
>
> > > Invalid index: 9, but we have 4 items in 2D texture coordinates
>
> >
>
> > >
>
> >
>
> > > ... and the error is valid from what I can see. TextureCoordinate has
>
> >
>
> > > too few points.
>
> >
>
> > >
>
> >
>
> > > Regards,
>
> >
>
> > > Michalis
>
> >
>
> > >
>
> >
>
> > >
>
> >
>
> > > śr., 8 lut 2023 o 03:45 John Carlson <yottzumm at gmail.com> napisał(a):
>
> >
>
> > > >
>
> >
>
> > > > I'm trying to collect information into one message.  Michalis, please check view3dscene 4.3, I believe ImageTexture and HAnimDisplacer were missing description field in view3dscene 4.2 and 4.3. See links below for X3D4 tooltips specifics.  The issue with view3dscene stems from adding a description fields in X3D4 using X3D-Edit (for the most part).  There are also schema issues with the file in question (JohnJoint18.x3d).
>
> >
>
> > > >
>
> >
>
> > > >
>
> >
>
> > > > I’ll double check the tooltips while I am at it.
>
> >
>
> > > >
>
> >
>
> > > > https://www.web3d.org/x3d/content/X3dTooltips.html#ImageTexture.description
>
> >
>
> > > >
>
> >
>
> > > > (Yellow)
>
> >
>
> > > >
>
> >
>
> > > > https://www.web3d.org/x3d/content/X3dTooltips.html#HAnimDisplacer.description
>
> >
>
> > > >
>
> >
>
> > > > (Yellow)
>
> >
>
> > > >
>
> >
>
> > > > If there are examples of HAnimDisplacer in the community, consider donating them to our testing effort.
>
> >
>
> > > >
>
> >
>
> > > > The good news is we have one good HAnimDisplacer node from www.web3d.org/x3d/content/examples/HumanoidAnimation/Skin/JoeKick.x3d (in the file system on the x3d project our sourceforge).   Michalis, Joe, the issue is that view3dscene throws all kinds of issues with the file.
>
> >
>
> > > >
>
> >
>
> > > > I was able to add the HAnimDisplacer in JoeKick to my JohnJoint18.x3d and not increase the number of errors reported by view3dscene (HAnimDisplacer without description seems to be working).
>
> >
>
> > > >
>
> >
>
> > > > Thanks!
>
> >
>
> > > >
>
> >
>
> > > > John
>
> >
>
> > > >
>
> >
>
> > > >
>
> >
>
> > > > On Tue, Feb 7, 2023 at 2:18 PM GPU Group <gpugroup at gmail.com> wrote:
>
> >
>
> > > >>
>
> >
>
> > > >> No. I'm finished with that project, its somewhere in web3d. I think I referred to tooltips, which has v4 added fields in yellow.
>
> >
>
> > > >> -Doug
>
> >
>
> > > >>
>
> >
>
> > > >>
>
> >
>
> > > >> On Tue, Feb 7, 2023 at 12:40 PM John Carlson <yottzumm at gmail.com> wrote:
>
> >
>
> > > >>>
>
> >
>
> > > >>> Doug,
>
> >
>
> > > >>>
>
> >
>
> > > >>> could you add nodes which have a new description field to your browser builder guide?
>
> >
>
> > > >>>
>
> >
>
> > > >>> Thanks!
>
> >
>
> > > >>>
>
> >
>
> > > >>> John and Don
>
> >
>
> >
>
>



More information about the x3d-public mailing list