Search Unity

  1. Unity Asset Manager is now available in public beta. Try it out now and join the conversation here in the forums.
    Dismiss Notice

Official USD for Unity Updates

Discussion in 'Formats & External Tools Previews' started by marief_unity, Mar 18, 2019.

  1. pachermann

    pachermann

    Joined:
    Dec 18, 2013
    Posts:
    133
    Yes, but Terrain is not Mesh, you need to make it into a mesh first.
    Simplygon is not needed if you work with unity terrain, only for asset LOD's.
    If you to mesh terrains, different story but then you have no export problems with USD.
    And many other Objects are maybe not in a format USD understands it, so you need to either work in meshes if you use USD as source, or split things up.
    Other assets with Polygons are no problem, i tried the export and they work as excepted.
    I even exported nested Quads and planes from unity base objects i used as 3d tooltips and everything was perfectly in the USD.
    Tested it with Modo.
     
  2. cubrman

    cubrman

    Joined:
    Jun 18, 2016
    Posts:
    412
    The package cannot be installed on 2021.2.15f1. Cannot be found in Package Manager (with pre-released packages enabled) and cannot be installed using the git clone url.
     
  3. judub

    judub

    Unity Technologies

    Joined:
    Nov 5, 2019
    Posts:
    11
    Hi @cubrman, experimental packages are not listed in the package manager even with pre-released packages enabled.
    But installing from git URL or from name is still working. I just did it in a fresh project in 2021.2.17f1.

    To install by name: use com.unity.formats.usd
    To install by git URL: use com.unity.formats.usd@3.0.0-exp.2
     
  4. cubrman

    cubrman

    Joined:
    Jun 18, 2016
    Posts:
    412
    Ok, thanks. I would recommend mentioning these two URLs somewhere on the GIT page as it is absolutely unclear where to find them or how to construct them.
     
    Jaxxtrend likes this.
  5. eastes

    eastes

    Joined:
    Sep 1, 2012
    Posts:
    59
    Thanks @judub. This worked for me! You can install by name with the little + icon on the top left of the package manager.
     
  6. eastes

    eastes

    Joined:
    Sep 1, 2012
    Posts:
    59
    At time of writing:

    3.0.0-exp.2 doesn't work with simplygon.


    I needed to use com.unity.formats.usd@3.0.0-exp.1 as a git URL
     
  7. cubrman

    cubrman

    Joined:
    Jun 18, 2016
    Posts:
    412
    Hahahahah, I also used it for simplygon)
     
  8. talespinvr

    talespinvr

    Joined:
    Apr 11, 2020
    Posts:
    7
    Where and how can I get sample USD files that work with the latest USD package? I've had trouble getting anything from the film tv toolbox.
     
  9. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    Hi,
    I'm wondering if anyone can point me in the right direction. I have a USD file with some extra primvar data on each vertex of the mesh (basically a string[] with one entry per vertex). I need to convert that into renderable data - something like reading those strings and marking a vertex color or texcoord with a value based on the string. Digging through the API and examples it looks like there's a way to do this using IImporter or one of the other import processors, but I'm having a hard time understanding the mapping between primvars and the resulting meshes. Ideally what I want do so is something along the lines of (in psuedocode):

    Code (CSharp):
    1. For all meshes in scene
    2.     If mesh has primarys named "extra_data"
    3.        foreach vertex in mesh
    4.           if extradata[vertex.index] == "foo"
    5.                mesh.vertexColor = red
    6.           else
    7.                mesh.vertexColor = blue
    8.  
     
  10. JasonBooth

    JasonBooth

    Joined:
    Jan 27, 2014
    Posts:
    651
    So I guess the USD importer for unity is another project that's died before it was finished?

    Has anyone gotten a skinned mesh renderer to import right? It seems like the SkinnedMeshRenderer.bones array is not filled out correctly (it has data, just not the right data) and because of that nothing renders..
     
  11. holo-krzysztof

    holo-krzysztof

    Joined:
    Apr 5, 2017
    Posts:
    77
    Kinda looks like it, there hasn't been a release in like a year. There are some WIP branches from 2 months ago with animation fixes, not sure if that helps you at all, but maybe it's something.

    I checked the omniverse website yesterday and it looks like all mentions of the Unity connector are gone, it's not even "coming soon" anymore. Oh well...
     
  12. Cascho01

    Cascho01

    Joined:
    Mar 19, 2010
    Posts:
    1,347
    Last edited: Aug 10, 2022
  13. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    So I can import the pixar example of a character fine, and I can import the USD I have into Unreal fine, but in Unity it doesn't render. I've debugged the bones array on the Skinned Mesh Renderer and it matches the list of joints in the USD file, in the same order. If I just assign the bones array a list of all the transforms in the skeleton, it will render, but obviously as a jumbled mess as the transforms are not in any particular order.
     
  14. ROBYER1

    ROBYER1

    Joined:
    Oct 9, 2015
    Posts:
    1,454
    How do I import textures with my USD file? On export from Blender, they are in a separate folder
     
  15. fherbst

    fherbst

    Joined:
    Jun 24, 2012
    Posts:
    802
    I think you need to copy the entire folder into Unity (including the textures). Alternative is having absolute paths but that just makes things harder across a team.
     
    ROBYER1 likes this.
  16. ben-britton

    ben-britton

    Joined:
    Feb 7, 2015
    Posts:
    15
    My goal with the USD exporter is to use Unity to compose virtual worlds and export them to implement in metaverse environments using USD as an interchange format. For example, I would like to create a virtual world in Unity and export it completely to import it into NVidia Omniverse tools, or Maya, or Blender, or 3DSMax. Cap1.PNG



    So far, I have a few impressions of the SDK, using Unity 2022.2.0b4.2768* <DX11> with this version of the USD SDK.
    https://github.com/Unity-Technologies/usd-unity-sdk/archive/dev.zip/


    1. It appears true that Unity destroys the UV coordinates when you export objects out of Unity into USD, and then import the resulting file back into Unity. The UV coordinates are gone from the model. This seems to be a bug, and because the UV coordinates are lost, the material cannot simply be reconstituted in the USD Shader component and reapplied to the gameObject, because the UV coordinates are lost so the texture map cannot be applied properly on the object.

    It seems that the USD exporter needs to to retain the UV mapping coordinates on the meshes it exports.

    It also seems that USD exporter needs to convert Unity Standard Shader materials into USD compatible USD shader material components in the exported material. The textures should be effectively embedded/exported with or within the USD file with path designations correct.

    2. I would like the USD exporter to convert the terrain into a USD compatible mesh and export it and its splat maps and textures also. Floral vegetation should also somehow be exportable - maybe new/more/better USD compatible Unity shaders are needed with transparency and translucency (not to mention normal maps, height maps, and splat maps).

    3. Consistently, exported models are rotated by 90 degrees on the X axis. This would be good to fix immediately.

    Hoping work in ongoing with this SDK, if Unity is to be a compositional tool for the metaverse, it MUST embrace or replace the USD train, halfway hanging on is no way to travel. It is dangerous and stressful to test with a half-built tool, and we need to start building metaverse environments today, so we need an authoring tool that will work; gosh, it seems like Unity would be our answer - IF Unity enables us to export our Unity compositions in a compatible file format! USD exists for that purpose, will Unity overlook USD? is there something better it is doing? If so, tell me, so I would like to continue using Unity to help me make virtual environments for the metaverse. It seems the USD format is vital for this.

    I am looking forward to a new version of the Unity USD exporter soon, or I will have to begin looking at Unreal after years of dedication to Unity. We may seem like stupid idiots, but developers need to prepare for web3d and realtime 3d interactivity on the net, and the usd format is an emerging solution - so we hope Unity will embrace it or replace it.
    #Beta2022Win_Unity
     

    Attached Files:

    • Cap2.PNG
      Cap2.PNG
      File size:
      116.6 KB
      Views:
      152
    • Cap2.PNG
      Cap2.PNG
      File size:
      116.6 KB
      Views:
      159
    Marcos-Elias, afshin_a_1 and ROBYER1 like this.
  17. ben-britton

    ben-britton

    Joined:
    Feb 7, 2015
    Posts:
    15
    waited a few days for a reply but none so far.

    maybe work has stopped on this USD file import/export sdk, and maybe they are doing another project with another file standard output, which is why the gltfast and a few others like it look like the next step to explore for me now.
    any suggestions would be appreciated.

    now examining gltfast and UniVRM on github and a few other gltf exporters for unity, and it appears that the world is coming back to the h-anim standard of vrml in the vrm file format for humanoids, so that is part of the puzzle. How does Unity expect to generate files with cameras, interactivity, lights, terrains, etc that are interoperable with everyone elses? the html of 3d?

    so next effort is to try exporting gltf files from unity instead of usd to explore interoperability.

    thanks,
     
    Last edited: Sep 17, 2022
  18. axmsw

    axmsw

    Joined:
    Mar 13, 2019
    Posts:
    9
    With the apparent Nvidia announcement, more attention is likely to come here :)

    Any timelines for when USD support will go live?

    Will it be backported to 2021 LTS?

    Will this work with WebGL? One issue seems to be that due to just embedding Pixar's USD engine there's a nice dependency with Intel TBB.

    How are USD assets going to work with runtime addressables? :)
     
    PeteSmalls, Blarp and DEEnvironment like this.
  19. afshin_a_1

    afshin_a_1

    Joined:
    Apr 26, 2015
    Posts:
    52
    usd unity sdk latest version 3.0.0-exp.2 Oct2021 does export usdz but it doesn't import usdz... :/
     
  20. jsingh_unity750

    jsingh_unity750

    Joined:
    Oct 23, 2022
    Posts:
    4
    Hi All, I am trying to make a standalone unity app to take in usd format and view them on scene. The plugin for usd by unity only works on OSX/PC. Is there a point of release planned for a stable version which supports runtime import on Android as well. And the plugin has issues on mac where it cannot find certain dll.
     
  21. yosimba2000

    yosimba2000

    Joined:
    Jun 3, 2021
    Posts:
    25
    How do you get textures/materials to show? I have a source .usdc file and an Assets folder containing my base mesh and textures. Unity only imports the model and skeleton, no textures or materials. I've tried changing every setting under the sun and it doesn't work.

    Blender imports the usdc with textures perfectly...
     
  22. yosimba2000

    yosimba2000

    Joined:
    Jun 3, 2021
    Posts:
    25
    Hi, can you expand on this? My usdc file came with an Assets folder containing textures and meshes. What should the file path look like when placing these textures in the Unity project folder?
     
  23. Cazforshort

    Cazforshort

    Joined:
    Feb 22, 2016
    Posts:
    16
    It doesn't work on Android?
    So I can't even import a USDC file into the scene at runtime on Unity?
    I just want my users to be able to bring in their own models.
     
    jsingh_unity750 likes this.
  24. jsingh_unity750

    jsingh_unity750

    Joined:
    Oct 23, 2022
    Posts:
    4
    Can you please elaborate those limitations. I am trying to make an android app that imports usd models from a path chosen with a file picker. And the usd package fails to build for android build settings
     
    PeteSmalls likes this.
  25. PeteSmalls

    PeteSmalls

    Joined:
    Apr 29, 2020
    Posts:
    11
    In the latest (Nov) Unite 2022 update, Unity teased that Universal Scene Description (USD) would be a topic on the roadmap for 2023 with no other information. Those are cool words - yet meaningless.
    So far, Unity has not instilled confidence that the organization understands the value of having such a format / framework more integrated to the engine. It is not about importing and exporting models (which the current package BARELY does and does it poorly as illustrated with peoples experiences above) - It is about collaborative workflows and the ability to work across applications which is something I have to imagine Unity will consider a threat to their proprietary solutions and NOT actually integrate to the best of its ability.
    We are about to embark on a significant project with “USD during runtime” at the center; leveraging much more of the great capabilities USD can unlock for creators. USD is our approach and Unity would be an obvious solution around this - but only if USD is going to be taken seriously in some meaningful period of time.
    Would it be possible to get a more detailed update in this forum, or a position posted or would it be possible for me to connect with someone at Unity to get more information so we can make a decision on the tools to address our needs?
    Any tangible insight would be appreciated.
    As it currently stands - we could not proceed with Unity as our solution if the existing package is the level of thinking Unity is willing to put toward this framework.
     
  26. PeteSmalls

    PeteSmalls

    Joined:
    Apr 29, 2020
    Posts:
    11
    Nothing? Silence? How would Unity like us to interpret no response on the subject? Is the USD topic headed the way of EditorXR, ArtEngine, etc?
     
  27. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    Certainly seems so.
     
  28. echu33

    echu33

    Joined:
    Oct 30, 2020
    Posts:
    62
    There's few new commits on github repo. also see some job position open for the USD tool on the site. probably(pure guessing) not going to die soon. But certainly update in a very very slow pace......
     
    PeteSmalls likes this.
  29. Marcos-Elias

    Marcos-Elias

    Joined:
    Nov 1, 2014
    Posts:
    159
    Is there a way to import materials and textures in runtime? It is hard to find a sample, or maybe I am not searching for it the right way haha... The documentation I have found expect textures to be included in Unity.
    This USD format will be perfect for games with user modding capabilities. But I got stuck here due to importing materials/textures outside of the editor =/
     
  30. ROBYER1

    ROBYER1

    Joined:
    Oct 9, 2015
    Posts:
    1,454
    Try GLTF/GLB files for that, use GLTFast or UnityGLTF for those from GIthub
     
    Marcos-Elias likes this.
  31. creat327

    creat327

    Joined:
    Mar 19, 2009
    Posts:
    1,756
    Anyone was able to import a rigged character with animations with this importer? It seems impossible but the main screenshot of the tool has a rigged character on it. So I’m wondering what am I doing wrong?
     
  32. Marcos-Elias

    Marcos-Elias

    Joined:
    Nov 1, 2014
    Posts:
    159
    I am using other formats for now. But it seems that this USD importer imports it way faster (at least on the desktop).
     
  33. r618

    r618

    Joined:
    Jan 19, 2009
    Posts:
    1,305
    Managed to export current work as FBX, out of -pre1 needed for Simplygon (only static meshes, thankfully (with Polybrush shaders on top))

    Never going to go anywhere near this probably
    It's really sad
     
  34. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    This effort is dead. Another abandoned Unity package in a half working state..
     
    ROBYER1 likes this.
  35. Carpet_Head

    Carpet_Head

    Joined:
    Nov 27, 2014
    Posts:
    258
    there are commits in the repo just yesterday so I wouldn't abandon all hope just yet
     
  36. ngclcs

    ngclcs

    Joined:
    Aug 22, 2013
    Posts:
    2
    @judub @jeremyco It's been near a year since someone from Unity weighed in here. Can we get an update? What is needed to get momentum on having a working tool for USD in Unity. Corporate partnerships, user petitions, mass abandonment? Or is this not a priority due to solutions like Pixyz. This is another tool that will either drive people to or away from Unity as a long-term solution. Please keep users and investors informed. Thank you.
     
  37. creat327

    creat327

    Joined:
    Mar 19, 2009
    Posts:
    1,756
  38. PixelDough

    PixelDough

    Joined:
    Apr 27, 2018
    Posts:
    56
    Unity's GDC presentation this year mentioned "USD integration" specifically. Seems pretty clear they are trying to put some hands on deck to get USD working seamlessly, as it's becoming more and more standard across many industries.

    I'm very excited to see it, as I grow more sick and tired of FBX with each passing year :p
     
    Marcos-Elias and ROBYER1 like this.
  39. Prashant_206

    Prashant_206

    Joined:
    Feb 26, 2014
    Posts:
    11
    Hi,

    Has anyone successfully imported a usd model in a standalone build using this package ?
     
  40. Prashant_206

    Prashant_206

    Joined:
    Feb 26, 2014
    Posts:
    11
    Hi,

    Were you able to import custom models at runtime using this package ?
     
  41. unity_0B00ACD928B27E3B18AA

    unity_0B00ACD928B27E3B18AA

    Joined:
    Apr 19, 2022
    Posts:
    1
    Hi,

    I export an object from Omniverse in .usd. That object have physics properties (with Collider and RigidBidy) that I can find after the export (in the MetaData with USD Viewer).

    upload_2023-4-17_11-46-46.png

    But when I export some Unity object with RigidBody or a Mesh Collider, that physics Meta Datas aren't present on the .usd.

    I'm confuse, but I guess I can't have this Datas from export in both ways.
    If you have any idea of export physics data from Unity with the usd format, let me know.

    Thanks.
     
  42. omidhedayati

    omidhedayati

    Joined:
    Nov 19, 2018
    Posts:
    4
    hello , is this package works on ios runtime?can i use it for importing usdz models on ios device runtime?
     
  43. spacefrog

    spacefrog

    Joined:
    Jun 14, 2009
    Posts:
    734
    No
     
  44. sacb0y

    sacb0y

    Joined:
    May 9, 2016
    Posts:
    874
    The github is updated but it's been two years since a release?

    Atm the exporter doesn't work. Why is this taking so long?
     
  45. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    11,791
    Don’t worry everyone, they mentioned usd on the roadmap, which means we are approximately 5 years away from them announcing they are abandoning the feature.
     
    Christiansquare and creat327 like this.
  46. MarioISG

    MarioISG

    Joined:
    Apr 24, 2023
    Posts:
    1
    How can I import USD files during runtime in Unity, specifically in a compiled executable for Windows, where the USD file can be arbitrary and re-imported multiple times?

    I have read that it is possible, but I am unsure how to achieve it. Additionally, I am unclear on how this will work if the scripts from the Editor folder are not compiled into the executable.
     
    GDevTeam likes this.
  47. BrunoL_Unity

    BrunoL_Unity

    Unity Technologies

    Joined:
    Jun 6, 2022
    Posts:
    4
    Hey every one!
    I'm please to let you know that we've pushed an update to the USD Unity SDK: USD Experimental Package last week on GIT: actually we had 2 releases back to back, the latest being 3.0.0-exp.4.
    https://github.com/Unity-Technologies/usd-unity-sdk

    We've fixed about 40 outstanding defects, here's the high level change log:

    3.0.0-exp.4
    Features
    Added EditorAnalytics to track internally which features are most used.
    Bug Fixes
    Fixed the Samples Assembly Definitions compile errors.
    Changed
    Updated AppCollector YAML file to reflect latest info.
    We've removed the USD logo in a few places until we have a formal agreement in place to use it.

    3.0.0-exp.3
    Features
    The USD Recorder now has an option to export transform overrides.
    Bug Fixes
    "Export Transform Override" now properly exports modified transforms only.
    Fixed a bug where importing materials exported from USD version >= 21.11 would fail.
    Fixed loading of meshes with arbitrary primvars.
    Fixed regression in animated mesh properties.
    Fixed timeout when importing complex meshes.
    Fixed a bug on export where SkelRoot and Skeleton Prim were missing class identifiers.
    Fixed 'ExportSelectedWithChildren' on Mac.
    Fixed texture mapping for exported meshes.
    Fixed a bug causing PointInstances to be duplicated.
    Fixed regression in JointsMatch().
    Fixed scene not being marked dirty after changing load payload flag.
    Fixed exported Prims not having a type and fixed export for objects with same name.
    Fixed a bug causing an ApplicationException "all sample times in times and baseTime must either all be numeric or all be default" to be thrown when refreshing a PointInstancer.
    Fixed an import bug causing instanced primitives not to be sanitized to fit Unity formats, including converting basis, triangulating and unwinding meshes, and unrolling primvars.
    Changed
    GC allocs reduced by half for Scene.GetAttributeAtPath and Scene.GetRelationshipAtPath.
    Disabled plugins on unsupported platforms.
    Optimized triangulation to reduce the chance of a "Timed out while waiting for thread" error on importing a complex mesh.
    Optimized PointInstance importing.

    _______________________________________
    Note that the OpenUSD version is still 20.08
    Documentation Update here
    Please feel free to share feedback and/or report any issue.
    _______________________________________

    Thanks to the team involved and to each of you for your feedback & dedication. We are looking forward to continue this journey together, building a vibrant Unity community around USD workflows.

    Bruno
     
  48. pachermann

    pachermann

    Joined:
    Dec 18, 2013
    Posts:
    133
    Great News Bruno, thank you for the Update!
     
    mblain and BrunoL_Unity like this.
  49. jsingh_unity750

    jsingh_unity750

    Joined:
    Oct 23, 2022
    Posts:
    4
    I cannot find any documentation on how to load usd at runtime. Can you please point me to one
     
    LohanSGR, Christiansquare and Wolfram like this.
  50. Wolfram

    Wolfram

    Joined:
    Feb 16, 2010
    Posts:
    261
    Hi @BrunoL_Unity, and thanks for keeping the package alive!

    Could you please give us an update on what the current state, as well as the near-future and longterm plans are for runtime use? Both for import and export.
    I realize working in the Editor is more useful for most people, but there is definitely also a demand for runtime use, and we have a specific request of a customer for exporting/streaming models at runtime.

    Unfortunately the documentation is currently extremely sparse (as it is still an experimental package), but the initial release was now 4 years ago, so I was wondering whether it is sensible for Unity users to actually use this (and build on it), or whether we should look for external solutions.

    The current documentation for3.0.0-exp.4 states that "Usd Recorder Track" can be used for export at runtime, but it is marked as "Legacy", and no documentation or Sample Scene is given on how to accomplish this.

    Thank you very much for any insights that you can give us on this!

    Cheers,
    Wolfram
     
    Last edited: Sep 20, 2023
    Christiansquare and PixelDough like this.