Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
2 captures
12 Jun 22 - 14 Jun 22
sparklines
Close Help
  • 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
0
Question by EslamTiffa · Sep 18, 2016 at 07:23 PM · error messageerror-messageerrormessage

How to fix faceplus MoreBlendshapeMeshes error in unity3d v4.6.1

I've been trying to make some facial animation with Mixamo faceplus v1.1.0.4 using this toturial (https://www.youtube.com/watch?v=JtcVl218CBE), but every time i start calibrating my character this error shows up:

ArgumentOutOfRangeException: Argument is out of range. Parameter name: index System.Collections.Generic.List`1[System.String].get_Item (Int32 index) (at /Users/builduser/buildslave/mono-runtime-and-classlibs/build/mcs/class/corlib/System.Collections.Generic/List.cs:633) FacePlusExtras_MoreBlendshapeMeshes.FindCommonPrefix (System.Collections.Generic.List`1 stringList) (at Assets/Mixamo Face Plus/FacePlusExtras_MoreBlendshapeMeshes.cs:25) FacePlusExtras_MoreBlendshapeMeshes.Start () (at Assets/Mixamo Face Plus/FacePlusExtras_MoreBlendshapeMeshes.cs:51)

if !UNITY_4_2

 string FindCommonPrefix(List<string> stringList){
     bool stillValid = true;
     string currentPrefix = "";
     int checkIndex = 0;
     while (stillValid){
         if (checkIndex < stringList[0].Length){
             string testPrefix = currentPrefix + stringList[0].Substring(checkIndex,1);
             for(int i=0; i<stringList.Count; i++){
                 if (testPrefix != stringList[i].Substring (0,checkIndex+1)){
                     stillValid = false;
                 }
             }
             if (stillValid){
                 currentPrefix += stringList[0].Substring(checkIndex,1);
             }
             checkIndex++;
         }
         else{
             stillValid = false;
         }
     }
     return currentPrefix;
 }


 void Start () {
     List<string> BlendshapeNameList = new List<string>();
     indexMap = new List<List<int>>();
     for(int i=0; i<FaceMesh.sharedMesh.blendShapeCount; i++) {
         BlendshapeNameList.Add(FaceMesh.sharedMesh.GetBlendShapeName(i));
     }
     string BlendshapePrefixMain = FindCommonPrefix(BlendshapeNameList);
     
     for(int i=0; i<ExtraBlendshapeMeshes.Count; i++){
         indexMap.Add (new List<int>());
         List<string> nameList = new List<string>();
         for(int j=0; j<ExtraBlendshapeMeshes[i].sharedMesh.blendShapeCount; j++) {
             nameList.Add ( ExtraBlendshapeMeshes[i].sharedMesh.GetBlendShapeName(j));
         }
         string shapesPrefix = FindCommonPrefix(nameList);
         
         for(int j=0; j<nameList.Count; j++) {
             for(int k=0; k<BlendshapeNameList.Count; k++) {
                 if(nameList[j].Remove(0,shapesPrefix.Length-1) == BlendshapeNameList[k].Remove(0,BlendshapePrefixMain.Length-1)){
                     indexMap[i].Add(k);
                 }
             }
         }
         
     }
 }
 
 
 void LateUpdate () {
     for(int i=0; i<indexMap.Count; i++){
         for(int j=0; j<indexMap[i].Count; j++){
             float curBlendshapeValue = FaceMesh.GetBlendShapeWeight (indexMap[i][j]);
             ExtraBlendshapeMeshes[i].SetBlendShapeWeight (j, curBlendshapeValue);
         }
     }
 }

endif

I am new to Unity, so could anyone help me with this problem?

Comment
Add comment
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

0 Replies

· Add your reply
  • Sort: 

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.

Follow this Question

Answers Answers and Comments

3 People are following this question.

avatar image avatar image avatar image

Related Questions

Assets\PlayerController.cs(29,29): error CS0200: Property or indexer 'Vector3.normalized' cannot be assigned to -- it is read only 1 Answer

I have an error "MissingReferenceException" and i dont know why 1 Answer

Can anyone help with this serialization script (missing the class attribute 'ExtensionOfNativeClass'!) 2 Answers

Errors i can't understand. SetSystemInterested 1 Answer

error CS0019: Operator `-' cannot be applied to operands of type `System.DateTime' and `string' 1 Answer


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