Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Get IDs for vertices being used in a SkinAttachmentTarget #7

Open
pauldrummond opened this issue Mar 27, 2023 · 2 comments
Open

Get IDs for vertices being used in a SkinAttachmentTarget #7

pauldrummond opened this issue Mar 27, 2023 · 2 comments

Comments

@pauldrummond
Copy link

pauldrummond commented Mar 27, 2023

How would I get the Vertex ID for all vertices being used in a SkinAttachmentTarget? If I toggle 'Show Resolved' in the Editor I can see which parts of the mesh are being used to bind attachments. What I'd like to do is get the Vertex IDs for these and use them in my custom shader. This would allow me to hide the parts of the SkinAttachmentTarget mesh that are occluded by the attachment mesh.

@mikko-alaluusua-unity
Copy link
Collaborator

In SkinAttachmentData, the SkinAttachmentItem contains all the poses used by that attachment item (vertex if the attachment is a mesh), and these poses contains the vertex ids of the target mesh that it uses. So if you would gather all the vertex indices used by the poses, you would have all the vertices that are used by the attachments.

@pauldrummond
Copy link
Author

Thanks for the info. I'll look into this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants