Skip to content

v24.8.7

Latest
Compare
Choose a tag to compare
@furby-tm furby-tm released this 16 Sep 18:41
· 3 commits to main since this release
bb5959f

What's New

🎧swift on.

SwiftUSD v24.8.7

Add support for creating instances of UsdImagingGL.Engine entirely in Swift.

Changelog

  • Thanks to the mighty @dgovil, his PR to OpenUSD has brought support for USD's imaging libraries to iOS & visionOS. 🎉

  • Bring in OpenUSD's ObjC implementation of HgiMetal, previously migrated to C++ to handle all retain/release calls because @furby-tm was not knowledgeable that having ARC enabled in ObjC code was powerful enough to handle all retain/release calls automatically. 😅

  • Corrected imports in (.glslfx) files (NOTE: none of this is tested, utilize these at your own peril until the USDView application in this repo is fully implemented, and I have had a chance to test it).

  • Fixed duplicated Garch source.

  • Ensuring HgiInterop compiles in ObjC (not C++!) mode on apple platforms.

  • Bring over the main USD imaging libraries to Swift.

    • HdAr
    • HdMtlx
    • HdSi
    • HdSt
    • Hdx
    • UsdImaging
    • UsdImagingGL
  • Hotfix for the <functional> header not being included in HdSt/glslProgram.h.

  • Bump SwiftSyntax to Swift 5.10, as we prepare to introduce the SwiftCrossUI dependency, to build a cross-platform UsdView application completely in Swift.

  • Removed SwiftBundler as a package dependency from MetaverseKit, we are working on getting the bundler in shape to build cross-platform apps (namely SwiftUSD & UsdView) across Linux, visionOS, iOS, macOS, and Windows, the recommended method to use the bundler is for users to install the bundler locally following these instructions.

  • Fixes any build issues on macOS and Linux after the recent changes to MetaverseKit to allow for Microsoft Windows support.

    • Nothing yet to report on Microsoft Windows (or Wasm) support, this is being worked on and will be coming in a future release of SwiftUSD.
  • Fixes all threading issues which caused crashing when reading and writing binary usd files (.usd, .usdc).

  • Fix a iOS build error related to incorrectly trying to link OpenGL (thanks @felfoldy!).

  • Supports building SwiftUSD with projects like Vapor for Swift on Server.

  • Allow creation/retrieval of USD stages from stage cache.

    • See this working example to learn how to work with UsdStageCache in Swift.
  • Examples application (beginning a repository of example use cases).

  • Various initial work around creating an OpenUSD version upgrader/downgrader.

  • Begin work for allowing proper subclassing and inheritance overrides of C++ virtual methods from Swift.

  • Adds a new optional parameter to Pixar.Bundler, in order to allow for explicit runtime auto-installation of all USD plugins when setting installPlugins: true (a requirement on iOS and visionOS devices)

    // usage like so:
    Pixar.Bundler.shared.setup(.resources, installPlugins: true)

Thank you, to those who make great things possible.


Usage

To use this release of Pixar's USD in your swift project, add the following to the dependencies section in your Package.swift file:

// swift-tools-version: 5.10

dependencies: [
  .package(url: "https://github.com/wabiverse/SwiftUSD.git", from: "24.8.6")
]

The Wabi Foundation uses SwiftUSD to build the Kraken metaversal creation suite, you can always find an up to date configuration to use for your own Swift project here.



Linux

For Linux, these are the only dependencies required, as MetaverseKit provides everything else.

Tip

If you are on a distro like Ubuntu there is a good chance you already have most of these installed.

Important

If you have installed TBB on your Linux system, it will break the entire std library on Linux, so you must ensure you do not have TBB installed on your system via (ex. sudo apt remove libtbb-dev), (pending this PR to Swift to fix this).

Dependency CentOS Ubuntu
Boost boost-devel libboost-all-dev
Python python3-devel python3-dev
BZ2 bzip2-devel libbz2-dev
ZLib zlib-devel zlib1g-dev
FreeGLUT freeglut-devel freeglut3-dev
DEFLATE libdeflate-devel libdeflate-dev
Expat libexpat-devel libexpat1-dev
Xcursor libXcursor-devel libxcursor-dev
Xt libXt-devel libxt-dev
Xi libXi-devel libxi-dev
Xinerama libXinerama-devel libxinerama-dev
Xrandr libXrandr-devel libxrandr-dev