• Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
Question by sunilnair · Jun 08, 2016 at 10:58 AM · meshskinnedmeshrendererbindingskinned-mesh

Unbind a skinned mesh in Unity

Goal: Keeping a correctly skinned mesh after applying blend mesh operation.

I have read documentation on trying to use blend mesh with a model. Blend mesh operation changes the bone weights on a vertex. I have copied the current weights for each vertex and stored it. Now I want to unbind my mesh in unity so that I can resize the joints/bones. I will copy back these weights after I re-position the joints after the blend mesh operation.

Does Unity support unbinding and binding a mesh in real time or do I need to use an external plugin for doing t$$anonymous$$s?

Comment

People who like this

0 Show 1
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image sunilnair · Jun 09, 2016 at 08:15 AM 0
Share

To make things clear, I am trying to unbind a skinned mesh skeleton from mesh vertices in unity

2 Replies

· Add your reply
  • Sort: 
avatar image

Answer by Bunny83 · Jun 09, 2016 at 10:00 AM

No, Unity doesn't support such an operation out of the box. You would have to:

  • Bake the mesh manually

  • Calculate a new bindpose for each bone for the baked mesh

  • Use the baked mesh as new mesh and the current bone positions as new initial pose.

That's just how it theoritically should work. It's not that clear what the end result should look like. The bindposes docutmentation(linked already above) has a simple example how to create a skinned mesh procedurally.

If you only want to reposition the bones in the without affecting the mesh you might do:

  • create an exact copy of the bone $$anonymous$$erarchy including the bones array of the SkinnedMeshRenderer.

  • Change the new bones the way you like.

  • When done recalculate the bindpose for the new bones and replace the bones array of the renderer.

From now on the mesh is using the new bones structure. However keep in mind that bone animations won't work anymore since they just set the bones to certain absolute position / rotation values. If you change the positions of the bones, i.e. you create a new skeleton, bone animations are no longer compatible with the bone structure. You can still play them, but they would deform the mesh most likely in a way you did not intend. Of course if you know what you're doing and you're creating the animation procedurally for t$$anonymous$$s configuration it might work. Best example of procedural animation adaption is the game Spore, but that was created by the most skilled procedural content developers on earth w$$anonymous$$ch where $$anonymous$$red from the demoscene.

Comment

People who like this

0 Show 0 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image

Answer by GXMark · Aug 27, 2016 at 09:52 AM

If you only want to reposition the bones in the without affecting the mesh you might do:

• create an exact copy of the bone $$anonymous$$erarchy including the bones array of the SkinnedMeshRenderer.

DONT DO THIS !

Just parent the skinned mesh renderers root bone to its parent transform. You then don't need to instantiate another set of game objects because the vertex weights are no longer being influenced.

Comment

People who like this

0 Show 0 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Welcome to Unity Answers

If you’re new to Unity Answers, please check our User Guide to help you navigate through our website and refer to our FAQ for more information.

Before posting, make sure to check out our Knowledge Base for commonly asked Unity questions.

Check our Moderator Guidelines if you’re a new moderator and want to work together in an effort to improve Unity Answers and support our users.

Follow this Question

Answers Answers and Comments

5 People are following this question.

avatar image avatar image avatar image avatar image avatar image

Related Questions

SkinnedMeshRenderer: Change Bones at start without changing mesh or blendshape results. 0 Answers

Wrong bindPoses with generated mesh 1 Answer

Modifying SkinnedMeshRenderer.sharedMesh.uv Doesnt Reset after Stopping game. 1 Answer

Character Animation Pose Mesh,Animated Pose Mesh 0 Answers

Finding a Point Relative to a Bone 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges