nexus icon indicating copy to clipboard operation
nexus copied to clipboard

Add vertex id data

Open ascandal opened this issue 5 years ago • 5 comments

I would like to read in a vertex id value int vertId for each vertex and export that value for each vertex in the final nxs and nxs files. I attempted this by following a similar procedure for adding vertex color values.

However I'm finding that this involves many code additions across many files in nexus. Is there an easier way to do this? More generally is there a good way to add generic data members to the vertices and faces that will be tracked and exported in the final nxs and nxz files?

ascandal avatar Jun 18 '19 18:06 ascandal

Unfortunately not an easy task. I will consider this, it looks like a good suggestion.

ponchio avatar Sep 03 '19 17:09 ponchio

Hi.

I think I have exactly the same need.

I guess that when Nxsbuild is launched only color, normal, uv and position attributes are kept.

If we could identify each vertex with an extra attribute (uuid or id) and we think in a nexus object as a merged geometry, we could apply modifications in nexus objects as we actually can apply in standard merged BufferGeometries keeping the benefits of merged geometries and also of individual geometries.

I think it would be a very good enhancement for this format.

In this way we could for example show or hide selective vertex or even change colors or apply a specific transformation matrix.

Best regards

ua4192 avatar Oct 29 '19 14:10 ua4192

One question.

Is it uv attribute supported by nexus?

I am thinking in using this attribute for identifying the vertex id.

Best regards

ua4192 avatar Oct 30 '19 09:10 ua4192

I'm working on adding attributes, it's a bit complicated.

How should simplification deal with attributes? We are merging 2 vertices into one with quadric simplification algorithm, what should be the attribute of the resulting vertex? Average, one of the two (random, closest?)?

You can't really use uv anyway, since Nexus splits the mesh and at the same time the texture, so uv get recomputed again.

On Wed, Oct 30, 2019 at 10:03 AM Alex [email protected] wrote:

One question.

Is it uv attribute supported by nexus?

I am thinking in using this attribute for identifying the vertex id.

Best regards

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/cnr-isti-vclab/nexus/issues/40?email_source=notifications&email_token=AAUDV2Z5WVNYKBR3HMPQKUDQRFEXNA5CNFSM4HZC5U2KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOECTM26Q#issuecomment-547802490, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAUDV2ZQUM4KREFXC2FGXC3QRFEXNANCNFSM4HZC5U2A .

ponchio avatar Oct 30 '19 09:10 ponchio

Hi.

And what about using vertex color attribute for this? I have seen the vertex color is defined a 4 float vector. You can use 2 floats not normalized for defining rgba or rgb and use the third or fourth component for vertex id. The problem is that this attribute is normalized. Could it be kept as non normalized? May be I am saying something stupid.

Best regards

El mié., 30 oct. 2019 10:47, Federico Ponchio [email protected] escribió:

I'm working on adding attributes, it's a bit complicated.

How should simplification deal with attributes? We are merging 2 vertices into one with quadric simplification algorithm, what should be the attribute of the resulting vertex? Average, one of the two (random, closest?)?

You can't really use uv anyway, since Nexus splits the mesh and at the same time the texture, so uv get recomputed again.

On Wed, Oct 30, 2019 at 10:03 AM Alex [email protected] wrote:

One question.

Is it uv attribute supported by nexus?

I am thinking in using this attribute for identifying the vertex id.

Best regards

— You are receiving this because you commented. Reply to this email directly, view it on GitHub < https://github.com/cnr-isti-vclab/nexus/issues/40?email_source=notifications&email_token=AAUDV2Z5WVNYKBR3HMPQKUDQRFEXNA5CNFSM4HZC5U2KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOECTM26Q#issuecomment-547802490 , or unsubscribe < https://github.com/notifications/unsubscribe-auth/AAUDV2ZQUM4KREFXC2FGXC3QRFEXNANCNFSM4HZC5U2A

.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/cnr-isti-vclab/nexus/issues/40?email_source=notifications&email_token=AHEIQ4LL3QA7666MFQCFM5LQRFJ3VA5CNFSM4HZC5U2KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOECTQ5RY#issuecomment-547819207, or unsubscribe https://github.com/notifications/unsubscribe-auth/AHEIQ4MISC2ECOD25WY4YLTQRFJ3VANCNFSM4HZC5U2A .

ua4192 avatar Oct 30 '19 19:10 ua4192