3MFConsortium / spec_core

3MF's Core specification
BSD 2-Clause "Simplified" License
55 stars 16 forks source link

Vertex color spec is unclear. #41

Closed JC3 closed 3 years ago

JC3 commented 3 years ago

Section 1.3 of the Materials Extension spec reads:

The 3MF core specification (4.1.4 Triangles) describes properties e.g. color to be specified for each vertex of a triangle. Specifically, an sRGB triplet can be assigned to each vertex of a triangle.

Section 4.1.4 of the core spec reads:

The property group is specified by the pid attribute, if different than the property group defined at the object-level. ... The properties applied to each vertex (p1, p2, p3) allow property gradients to be defined across the triangle, where interpolation of the property is defined as the linear convex combination. ... If the properties defined on the triangle are from a group (see Chapter 5), they MUST NOT form gradients, as interpolation of base materials is not defined in this core specification. Therefore p1, p2 and p3 MUST be equal or unspecified.


I can't make any sense of this because:

What am I missing? Where does the Core spec define sRGB triplets that can be assigned to each vertex of a triangle?

Also, if p1, p2, and p3 must always be identical (since they must refer to a "property group", of which there is only one: base materials -- for which they must be identical), why are there three separate p's and what is it referring to when it mentions interpolation?

jordig100 commented 3 years ago

The core spec only defines the BaseMaterials as property group. Since that is a material property, it can't be interpolated, since it defines the material. This is just for using the core spec alone. However when extended with the materials spec, other property groups could be define. For example the ColorGroup, which defines the surface color as being "painted". In this case interpolation between vertex properties is allowed. The core spec just set the based for a behaviour that is defined in the materials spec.

JC3 commented 3 years ago

Understood. Thank you.

J

On Fri, May 14, 2021, 12:02 PM Jordi Gonzalez @.***> wrote:

The core spec only defines the BaseMaterials as property group. Since that is a material property, it can't be interpolated, since it defines the material. This is just for using the core spec alone. However when extended with the materials spec, other property groups could be define. For example the ColorGroup, which defines the surface color as being "painted". In this case interpolation between vertex properties is allowed. The core spec just set the based for a behaviour that is defined in the materials spec.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/3MFConsortium/spec_core/issues/41#issuecomment-841336484, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABLDV4CFAXVRMKJ24UGJUILTNVCPRANCNFSM43WCNNDQ .