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

Can I only change vertex‘s color without cooking coliision #32

Closed
zfyu222 opened this issue Mar 1, 2017 · 3 comments
Closed

Can I only change vertex‘s color without cooking coliision #32

zfyu222 opened this issue Mar 1, 2017 · 3 comments

Comments

@zfyu222
Copy link

zfyu222 commented Mar 1, 2017

I am using this plugin in my project,and Often need to update the vertex color without other data.Now I have to recreate MeshSection(Or updateMeshSection) ,Which can lead to unnecessary performance overhead with physice recook,but I did not actually change the mesh shape.Can I only change vertex‘s color without cooking coliision.

@indyfree
Copy link

indyfree commented Mar 2, 2017

@zfyu222 How do you display the vertex colors in the engine?
Just setting the Vertex colors like this:
RuntimeMesh->CreateMeshSection(0, Vertices, Triangles, Normals, TextureCoordinates, VertexColors, Tangents); does not do the trick for me.
The mesh keeps showing with the standard texture. Do I need to create a material from the vertex colors?

@Koderz
Copy link
Member

Koderz commented Mar 7, 2017

Well.. honestly no you can't really change it directly without recooking the collision... That's something I'll keep in mind for the new version.

The way you can get around this is use the separate collision. CreateMeshCollisionSection() or something like that, I don't remember the exact name. You could use that to handle the collision and then just disable collision on the normal section you want to change frequently.

@zfyu222
Copy link
Author

zfyu222 commented Mar 9, 2017

Thank you reply.Separating collision and rendering is indeed a feasible solution

@zfyu222 zfyu222 closed this as completed Mar 9, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

3 participants