Search Unity

UMA Power Tools Support (v. 2.9)

Discussion in 'Assets and Asset Store' started by UnLogick, Jan 7, 2014.

  1. UnLogick

    UnLogick

    Joined:
    Jun 11, 2011
    Posts:
    1,745
    Honestly I never tested Power Tools with DCS, but since DCS is essentially a layer on top that ends up populating the UMAData same as vanilla does I didn't give it much focus.

    It is known that the first time you build an uma Unity has to load a lot of textures and data into memory so you can experience some slowdown. But nothing at the scale of 10-15 seconds.

    Please post some very specific repro steps, load this scene, enable power tools, select character X, create prefab, observe lag, that way I avoid chasing shadows and move straight onto verify the problem and verify the fix. :)
     
  2. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    That is pretty much all you have to do haha, or at least what I just did then to reproduce the steps. I loaded up a new project, imported UMA and Powertools, hit play in the scene, created a cube dragged the cube into the folder to attempt to create a prefab and then there is about a 10 second wait. After creating the first prefab, if I create a new prefab from a square there will no longer be a 10 second wait. However, if I hit play again in the scene and repeat the same steps I get the same lag again.

    The same thing will if I try to save the scene, IE after coming out of runtime, if I create a cube and try to save the scene, I'll get the wait again. If I do the same steps without hitting play again, saving the scene will be more or less instant.

    This is what I'm getting on my end with Unity 2017.1.1, hope that helps and thanks in advance! :)
     
  3. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    More or less any interaction with the Unity editor aside from hitting play in the scene on my end will trigger some sort of wait time.
     
  4. UnLogick

    UnLogick

    Joined:
    Jun 11, 2011
    Posts:
    1,745
    Specifics man... what scene? Any of the uma test scenes? :D
     
  5. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    Ya any scene, at least for me I got lag on any scene, even a blank scene, doesn't have to be DCS scene :)
     
  6. UnLogick

    UnLogick

    Joined:
    Jun 11, 2011
    Posts:
    1,745
    And this goes away by deleting power tools?
     
  7. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    I don't use UMA alone without power tools, however I just tested it then and I can at least confirm that I'm getting the lag with UMA alone. I've posted this issue over on the main UMA forums as well, but telling you wouldn't hurt since your an UMA expert :p
     
  8. UnLogick

    UnLogick

    Joined:
    Jun 11, 2011
    Posts:
    1,745
    That is true, however there is a severity issue for me. If this was purely related to something I did in power tools I'd be charging at it. But right now I'm at a time in my life where time has become a very limited resource.

    A repeating 10-15 seconds delay sounds horrible and shouldn't happen, so I'll keep an eye on the uma slack to make sure this doesn't get forgotten.
     
    hopeful likes this.
  9. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    Appreciate it and I understand how precious time is. I originally thought it was powertools related as I only use UMA because of powertools. Regardless, I've pasted it onto the main thread :)
     
  10. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    If you don't mind, I'd appreciate if you quickly loaded the latest version of UMA and try creating a prefab after coming out from a scene. If I know that it isn't only happening to me, that would be nice.
     
  11. UnLogick

    UnLogick

    Joined:
    Jun 11, 2011
    Posts:
    1,745
    Just to wrap this up. Looks really bad as a last post on a support forum. ;)

    Turns out to be an issue that several of the uma inspectors spawn a uma context for you if none is in your scene. So before selecting uma objects it's wise to have an uma context in your scene. I'm not entirely a fan of this problem, the original implementation which I made many years ago was that it just said no context available so I can't tell you what's inside this uma recipe... I guess that can be annoying too. We'll be adding visibility to this issue, so that you know what is stealing all your io and cpu speed. Hopefully sometime in the future we can do even better.
     
    Mark_01 and hopeful like this.
  12. Rajmahal

    Rajmahal

    Joined:
    Apr 20, 2011
    Posts:
    2,101
    Hi, Im thinking of picking up these tools solely for the save as prefab functionality. Can you confirm that this still works well with the latest official release of uma and that you intend to support any upcoming releases for the next year or so? Thanks,
     
  13. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    No worries, I reached out to the main UMA forums and have found a temporary solution, more or less what you said, so thanks for reaching out as well!

    Just have another question, does bone baking still work in the latest power tools release? Probably a oversight on my behalf but I can't seem to be able to swap out the script in the UMA Generator script. I am using DCS as well.
     
  14. UnLogick

    UnLogick

    Joined:
    Jun 11, 2011
    Posts:
    1,745
    @Rajmahal save as prefab works just fine.

    @Bantichai you no longer need to swap out the generator, only the mesh combiner. There is a menu item that should allow you to turn bone baking on/off modifying UMA in your active scene.
     
  15. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    How exactly does it work now? I enabled "Scene Bone Baking" in the UMA DCS scene and saw that the default mesh combiner script got swapped over to "UMABoneBakingMeshCombiner" however after saving the prefab, it still contained all the extra bones in the head.
     
  16. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    Nvm on that part, forgot to enable it before rendering the UMA's, I had enabled it during runtime so that is why. The problem now is my own custom UMA armor is making the entire UMA pink, however the default UMA armor that came with the recipe is fine. Any ideas?

    Getting this warning too:

    Exception in UMAGeneratorBuiltin.OnDirtyUpdate: System.ArgumentException: length
    at System.Array.Copy (System.Array sourceArray, Int32 sourceIndex, System.Array destinationArray, Int32 destinationIndex, Int32 length) [0x000ab] in
     
  17. UnLogick

    UnLogick

    Joined:
    Jun 11, 2011
    Posts:
    1,745
    That's definitely a bug of some kind. I'm almost certain it's related.

    I need the full call stack, the next part of the call stack is the most important one... all this tells me is than an array copy failed (probably in the skinned mesh combiner) but not which one. Get me the full error message and I can tell exactly what is going on.
     
  18. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    Here is the full stack:

    Exception in UMAGeneratorBuiltin.OnDirtyUpdate: System.ArgumentException: length
    at System.Array.Copy (System.Array sourceArray, Int32 sourceIndex, System.Array destinationArray, Int32 destinationIndex, Int32 length) [0x000ab] in /Users/builduser/buildslave/mono/build/mcs/class/corlib/System/Array.cs:971
    at UMA.PowerTools.SkinnedMeshCombinerRetargeting.CombineMeshes (UMA.PowerTools.MeshBuilder target, .CombineInstance[] sources, UnityEngine.Matrix4x4[] inverseTargetBoneMatrixes) [0x001d4] in D:\Project Cataylst - AAA\Assets\UMA\Extensions\UMAPowerTools\Scripts\SkinnedMeshCombinerRetargeting.cs:90
    at UMA.PowerTools.UMABoneBakingMeshCombiner.UpdateUMAMesh (Boolean updatedAtlas, UMA.UMAData umaData, Int32 atlasResolution) [0x0010d] in D:\Project Cataylst - AAA\Assets\UMA\Extensions\UMAPowerTools\Scripts\UMABoneBakingMeshCombiner.cs:133
    at UMA.UMAGeneratorBuiltin.UpdateUMAMesh (Boolean updatedAtlas) [0x00026] in D:\Project Cataylst - AAA\Assets\UMA\Core\StandardAssets\UMA\Scripts\UMAGeneratorBuiltin.cs:282
    at UMA.UMAGeneratorBuiltin.HandleDirtyUpdate (UMA.UMAData data) [0x0016b] in D:\Project Cataylst - AAA\Assets\UMA\Core\StandardAssets\UMA\Scripts\UMAGeneratorBuiltin.cs:226
    at UMA.UMAGeneratorBuiltin.OnDirtyUpdate () [0x0005c] in D:\Project Cataylst - AAA\Assets\UMA\Core\StandardAssets\UMA\Scripts\UMAGeneratorBuiltin.cs:265
    UnityEngine.Debug:LogWarning(Object)
    UMA.UMAGeneratorBuiltin:OnDirtyUpdate() (at D:/Project Cataylst - AAA/Assets/UMA/Core/StandardAssets/UMA/Scripts/UMAGeneratorBuiltin.cs:274)
    UMA.UMAGeneratorBuiltin:Work() (at D:/Project Cataylst - AAA/Assets/UMA/Core/StandardAssets/UMA/Scripts/UMAGeneratorBuiltin.cs:132)
    UMA.UMAGeneratorBuiltin:Update() (at D:/Project Cataylst - AAA/Assets/UMA/Core/StandardAssets/UMA/Scripts/UMAGeneratorBuiltin.cs:97)
     
  19. UnLogick

    UnLogick

    Joined:
    Jun 11, 2011
    Posts:
    1,745
    Thanks, from there it was trivial to determine the problem. One of your slots doesn't have uv2 while several of them does. There seems to be a general problem with these safety checks, the same problem could occur with several other mesh channels.

    Please change line 88 of SkinnedMeshCombinerRetargeting.cs from "if (source.meshData.uv2 != null)" to
    Code (CSharp):
    1. if (source.meshData.uv2 != null && source.meshData.uv2.Length != 0)
    That should take care of the uv2 problem, if you get a similar problem with the other channels please add the length check there as well.

    I'll make sure to clean this up for the next release.
     
    Mark_01, Rajmahal and hopeful like this.
  20. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    Thanks a lot for that, will the next release be when UMA 2.7 drops?
     
  21. JeffG

    JeffG

    Joined:
    Oct 21, 2013
    Posts:
    85
    Is there any documentation or updated videos for the Power Tools? (or some other resource)
     
  22. magique

    magique

    Joined:
    May 2, 2014
    Posts:
    4,030
    When you bake UMA 2 to a prefab can it be used normally with systems like Invector, Ootii, etc? Also, Does a baked UMA 2 work with SALSA's UMA 2 one-click setup?
     
  23. UnLogick

    UnLogick

    Joined:
    Jun 11, 2011
    Posts:
    1,745
    I have no idea, but I would expect that it doesn't work. There is no trace of UMA in the prefab, it can be exported into a project that doesn't have UMA at all. This also means that any code that expects to find UMA wont work. I could be wrong in my assumption that SALSA looks at the UMAData component, if all it does is Find named game objects then it will probably work.
     
  24. magique

    magique

    Joined:
    May 2, 2014
    Posts:
    4,030
    Thanks for the info.
     
  25. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    WIth UMA 2.7 now officially out do you have a rough idea when you'll be updating power tools to 2.7? Would this update address the issue I had with the uv2 problem and bone baking as you mentioned that you would clean that up on the next release :)

    To save you from scrolling up again:

    Thanks, from there it was trivial to determine the problem. One of your slots doesn't have uv2 while several of them does. There seems to be a general problem with these safety checks, the same problem could occur with several other mesh channels. That should take care of the uv2 problem, if you get a similar problem with the other channels please add the length check there as well. I'll make sure to clean this up for the next release.
     
  26. UnLogick

    UnLogick

    Joined:
    Jun 11, 2011
    Posts:
    1,745
    Right, I had completely forgotten about that, I thought you used the hack I sent you to solve the issue. I'll try to squeeze it in soon.
     
    Mark_01 likes this.
  27. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    If you could squeeze it in soon that would be greatly appreciated! :)
     
  28. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    Hey UnLogick, do you have a rough idea when your going to release Power Tools 2.7?
     
  29. Urbanwarfare-Std

    Urbanwarfare-Std

    Joined:
    Jan 6, 2013
    Posts:
    33
    Hi UnLogick,

    I have been asking some questions on the UMA2 thread and I have been directed here by @Jaimi who has been really helpful but these questions it turns out are specific to UMA Powertools.

    I have 4 UMA models which I intend to use in a Field Hockey Sports Action Simulation game:
    https://www.instagram.com/p/BfcBtw6nVZG/?taken-by=thefieldhockeygame

    I have exported them as Prefabs but I am unsure on the best route for creating animations for them given that they don't appear to have a fully fledged Avatar within the prefab that you can rig etc?

    I have been using the Raw Mocap to try out various bits and I have noticed on certain animations that avatar/models float up a foot or so off the ground when you have a player controller applied to it - has anyone else experienced that sort of outcome? Is it a player controller problem rather than anything to do with UMA/Powertools.

    Thanks in advance for any suggestions you might have on this.
     
  30. UnLogick

    UnLogick

    Joined:
    Jun 11, 2011
    Posts:
    1,745
    If I recall correctly the avatar resides in a file next to the prefab. I might be mistaken here it's been a while since I looked at the avatars. But this means you might have to copy the avatar along with the prefab. (Same as the generated textures)

    The power tools does very little to the avatars, they're generated by uma and the power tools just writes it to an asset, this means that any animation would play exactly the same as uma would.

    What version of Unity are you using? Perhaps something broke a new release.
     
  31. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    Sorry to ask again UnLogick, do you have a rough idea when 2.7 is going to drop?
     
  32. Rajmahal

    Rajmahal

    Joined:
    Apr 20, 2011
    Posts:
    2,101
    Hi, can anyone confirm whether the bake to prefab function works with uma 2.7?
     
  33. UnLogick

    UnLogick

    Joined:
    Jun 11, 2011
    Posts:
    1,745
    It works for the 2.5 features, it hasn't been updated to work for cloth or blendshapes.
     
  34. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    Hey UnLogick, I know you are busy but I've asked a few times with no response. I just want to know roughly when you will update power tools to 2.7 and fix the issue I was having.
     
  35. UnLogick

    UnLogick

    Joined:
    Jun 11, 2011
    Posts:
    1,745
    Hey Bantichai
    Thank you for your patience, I'll push it to the front of the queue and try to get it done tonight.
     
  36. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    Wasn't expecting tonight but if you could that would be even better. Thanks again! :)
     
  37. Rajmahal

    Rajmahal

    Joined:
    Apr 20, 2011
    Posts:
    2,101
    Has anyone taken a prefab created from power tools and used simplygon to optimize it further? I'm trying to figure out if the prefab will work in my current workflow.
     
  38. UnLogick

    UnLogick

    Joined:
    Jun 11, 2011
    Posts:
    1,745
    The output is a fully qualified unity mesh, so any unity tool that doesn't rely on an external commandline should just work.

    Well you didn't get tonight, but it's still first in the queue. :)
     
  39. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    No worries, let me know when it drops :)
     
  40. drakedane

    drakedane

    Joined:
    May 23, 2017
    Posts:
    62
    I imported UMA Power Tools 2, but haven't started to use it yet. But I keep seeing console warnings about code deprecations. New to programming and Unity, so not sure if users need to bother reporting stuff like this. I checked to ensure that there wasn't an update, since purchasing. From what I can tell, I am using the latest version of Power Tools. Anyway, just hoping to minimize any issues, when I am finally ready to test/use Power Tools. So, please, let me know, if you want me to report the code deprecation warnings I keep seeing. Otherwise, guess I will assume you are seeing the same warnings and plan to deal with them in a future release. :)
     
  41. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    I don't think Power Tools works with UMA 2.7 if that is what you are using, UnLogick is hopefully going to release an update soon for 2.7.
     
  42. UnLogick

    UnLogick

    Joined:
    Jun 11, 2011
    Posts:
    1,745
    Code deprecation is unity's way of warning you that you're using old api. In other words it's not doing anything wrong it's just doing it "the old way". The current power tools version works with unity 5.3.4f and newer, as long as it's just warnings I'm in no rush to update it. If you are a professional company that has a treat warnings as errors policy it should be trivial to remove the warnings.

    Power tools does work with uma 2.7, however the bone baking doesn't support the "new" features of 2.7, most importantly the blend shapes and the cloth.
     
  43. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    Hey @UnLogick any word on an update eta?
     
  44. MotionBrain

    MotionBrain

    Joined:
    Dec 5, 2015
    Posts:
    30
    Hey @UnLogick
    I got a problem with your FBX Exporter.
    I'm using Unity 2017.4.0f1 and tried it with Unity 2017.2...

    On .4:
    Fbx Exporter - DLL unable to load!
    The Fbx Exporter DLL was located at Assets/UnLogickFactory/FbxExporter/DLL/UnityFbxExporter_x86_64_v14.dll but failed to load.
    UnityEngine.Debug:LogErrorFormat(String, Object[])
    UnLogickFactory.FbxExporter:LogErrorFormat(Boolean, String, Object[]) (at Assets/UnLogickFactory/FbxExporter/Scripts/FbxExporter.cs:562)
    UnLogickFactory.UnityFbxExporterBinding:Init(Int32) (at Assets/UnLogickFactory/FbxExporter/Scripts/UnityFbxExporterBinding.cs:99)
    UnLogickFactory.FbxExporter:GetFormatNames(Boolean, String[]&, Int32[]&) (at Assets/UnLogickFactory/FbxExporter/Scripts/FbxExporter.cs:780)
    UnLogickFactory.FbxExporterWindow:OnEnable() (at Assets/UnLogickFactory/FbxExporter/Scripts/Editor/FbxExporterWindow.cs:107)

    And on your FBX exporter Screen is on the tab Exported FBX Format : Platform not supported or dll is missing.

    In the version .2 i get the error :
    Assets/UnLogickFactory/FbxExporter/Scripts/FbxTextureExportScheme.cs(103,63): error CS0117: `UnityEditor.EditorGUILayout' does not contain a definition for `EnumFlagsField'

    Hope you can help me out here.

    Thank you,

    Joachim | MotionBrain
     
  45. UnLogick

    UnLogick

    Joined:
    Jun 11, 2011
    Posts:
    1,745
    Hi Joachim
    I'm aware of the problem and working on a solution. If you pm me a mail address I'll send you the slightly older 1.3.1 release as a temporary measure.
    Regards
    Joen
     
  46. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    Hey @UnLogick I know I keep asking, but it'd be great if I could at least get an ETA as to when you plan to update this to 2.7.
     
  47. UnLogick

    UnLogick

    Joined:
    Jun 11, 2011
    Posts:
    1,745
    @Bantichai these past months have skipped by so fast I have no metric to even guess at an ETA. Honestly I thought uma 3 would be nearing release now, but alas it's still a long way off.

    When you say updating to 2.7 you mean adding blend shape and cloth support to the bone baking or the prefab creation? Because everything else should work just fine.
     
  48. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    Hi @UnLogick I mainly want an update so I can move past the error I get when bone baking my prefabs. The error had to do with uv2.

    Full stack from a couple months ago:

    Exception in UMAGeneratorBuiltin.OnDirtyUpdate: System.ArgumentException: length
    at System.Array.Copy (System.Array sourceArray, Int32 sourceIndex, System.Array destinationArray, Int32 destinationIndex, Int32 length) [0x000ab] in /Users/builduser/buildslave/mono/build/mcs/class/corlib/System/Array.cs:971
    at UMA.PowerTools.SkinnedMeshCombinerRetargeting.CombineMeshes (UMA.PowerTools.MeshBuilder target, .CombineInstance[] sources, UnityEngine.Matrix4x4[] inverseTargetBoneMatrixes) [0x001d4] in D:\Project Cataylst - AAA\Assets\UMA\Extensions\UMAPowerTools\Scripts\SkinnedMeshCombinerRetargeting.cs:90
    at UMA.PowerTools.UMABoneBakingMeshCombiner.UpdateUMAMesh (Boolean updatedAtlas, UMA.UMAData umaData, Int32 atlasResolution) [0x0010d] in D:\Project Cataylst - AAA\Assets\UMA\Extensions\UMAPowerTools\Scripts\UMABoneBakingMeshCombiner.cs:133
    at UMA.UMAGeneratorBuiltin.UpdateUMAMesh (Boolean updatedAtlas) [0x00026] in D:\Project Cataylst - AAA\Assets\UMA\Core\StandardAssets\UMA\Scripts\UMAGeneratorBuiltin.cs:282
    at UMA.UMAGeneratorBuiltin.HandleDirtyUpdate (UMA.UMAData data) [0x0016b] in D:\Project Cataylst - AAA\Assets\UMA\Core\StandardAssets\UMA\Scripts\UMAGeneratorBuiltin.cs:226
    at UMA.UMAGeneratorBuiltin.OnDirtyUpdate () [0x0005c] in D:\Project Cataylst - AAA\Assets\UMA\Core\StandardAssets\UMA\Scripts\UMAGeneratorBuiltin.cs:265
    UnityEngine.Debug:LogWarning(Object)
    UMA.UMAGeneratorBuiltin:OnDirtyUpdate() (at D:/Project Cataylst - AAA/Assets/UMA/Core/StandardAssets/UMA/Scripts/UMAGeneratorBuiltin.cs:274)
    UMA.UMAGeneratorBuiltin:Work() (at D:/Project Cataylst - AAA/Assets/UMA/Core/StandardAssets/UMA/Scripts/UMAGeneratorBuiltin.cs:132)
    UMA.UMAGeneratorBuiltin:Update() (at D:/Project Cataylst - AAA/Assets/UMA/Core/StandardAssets/UMA/Scripts/UMAGeneratorBuiltin.cs:97)

    That is pretty much the only thing that I'm after so I can update to UMA 2.7 and clear those errors after I do the bone baking. Perhaps you could release an update that fixes those issues?

    I'll also add that currently I can't bake away bones on my UMA models because of that error, so hoping I can get this resolved.
     
    Last edited: May 5, 2018
  49. UnLogick

    UnLogick

    Joined:
    Jun 11, 2011
    Posts:
    1,745
    Good news... I started working on the next power tools update yesterday. :)

    The bug is not related to uma 2.7 as such but to the fact that you use some slots that have uv2 and some slots that doesn't. I fixed your bug yesterday and is now working on blend shape support. The blend shape support turned out a bit more extensive than expected, mainly because I have to retarget the damn blendshapes as well. :)
     
    Mark_01 and twobob like this.
  50. Bantichai

    Bantichai

    Joined:
    Nov 6, 2016
    Posts:
    138
    That's awesome news! Thanks a lot @UnLogick looking forward to the update whenever it drops :)