Code Monkey home page Code Monkey logo

usd-arnold's Introduction

USD-Arnold

USD Schemas and tools for exchanging Arnold shader information between multiple 3rd party packages.

Project Goals

  • Have a centralized set of schemas describing Arnold materials.
  • Provide writers and readers for rendering applications for seamlessly transferring shader information from one application to another.

Modules

Current

  • usdAi schema.
    • AiNodeApi - Handling generic Arnold nodes.
    • AiShapeAPI - Handling Arnold shape options, like visibility, sidedness, self-shadows, and receive-shadows.
    • AiMaterialAPI - Defining Arnold shader relationships.
    • AiProcedural - Schema for Arnold's procedural node.
    • AiVolume - Schema for Arnold's volume node.
  • Shader exporter for usdMaya. A custom shading mode exporter for Maya that exports all Arnold shader definitions via MtoA. We support MtoA-1.2 and MtoA-1.4.
  • Tools for usdKatana. Ops for describing and reading in procedurals to Katana.
  • Arnold render delegate.
  • Arnold shader discovery and parsing.

Planned

  • Adding a material importer for usdKatana. For more information, see building USD.
  • Making sure USD-Arnold works with a base installation of USD.
  • Build all the packages at once.
  • Add windows support.

Building

Our build process is designed to build USD-Arnold as multiple rez packages, so the different components need to be built separately from the main schema.

At this moment USD-Arnold relies on several customizations and fixes to USD, most of which have their PR and waiting to be merged back.

Use our custom build of USD

Building Luma Pictures' flavor of USD is the easiest option, we provide a set of new features, mostly to usdMaya and usdKatana, none of which are breaking any existing behavior in USD. Clone the repository at https://github.com/LumaPictures/USD and build the branch tg/luma/luma following the official build instructions. Note, we changed the default implementation for TfHashMap and TfHashSet to improve stability, make sure you build all your plugins using this version.

Use the official version and apply patches

Clone the latest dev version of USD, and apply the following change to support importing arnold materials in Katana:

Replace the file with Luma's version.

Build enviroment

Requirements

We use and test with the following library versions.

Name Version
GCC 4.8.5 / 6.3.1
Boost 1.61.0
TBB 2017.x
OpenEXR 2.2.0 - latest
MtoA 3.x
Katana 2.5v6 - 3.x
Maya 2018 - 2019
Arnold 5.2.x

You can use configuration variables to enable/disable individual components during the build process. These are the following.

  • BUILD_USD_PLUGIN - Generating the schemas.
  • BUILD_USD_IMAGING_PLUGIN - Building the render delegate and ndr plugins.
  • BUILD_USD_MAYA_PLUGIN - Building the usdMaya plugin.
  • BUILD_USD_KATANA_PLUGIN - Building the usdKatana plugin.

TODO: Finish.

Contributing

TODO.

usd-arnold's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

usd-arnold's Issues

Remove ai:volume relationship from AiMaterialAPI

Arnold doesn't really distinguish between surface and volume shaders, so having distinct relationships doesn't seem to make a lot of sense (especially since we're translating both as the "surface" shader in Katana).

[katana] Location decorator breaks shared shader connections in USD 20.02+

The changes in PixarAnimationStudios/OpenUSD@a627abb introduced some additional logic to the naming handle generation logic for shading nodes that are not immediate children of the material that is being built. This is to avoid collisions when shading nodes are nested in sub-graphs, but it also affects shaders that are shared between multiple material networks.

The new logic for making the shading node handles unique is not part of PxrUsdKatanaUtils::GenerateShadingNodeHandle, so our location decorator did not pick up the new behavior automatically. Thus, reading materials with shared shaders is currently broken when using USD 20.02+.

I'm going to ask Pixar about making the unique handle generation logic part of the public API.

Support MacOS

As the title says. There are a few linking issues and warnings on Mojave. Mainly usdAi does not link against all the required libraries (which is handled at runtime on Linux but not on MacOS), and the newer compiler on MacOS has a few extra warnings turned on.

Add a working Render Delegate

Implement a working render delegate to render via Hydra.

A (non-complete) list of subtasks for the initial implementation.

  • Camera that generates rays from the projection passed to the renderer.
  • Driver to pass render data and buffers to Hydra.
  • Polymesh support.
  • Implement HdAiRenderPass.
  • Blocking rendering.

Material support

Support materials in the render delegate, meaning converting HdMaterialNetworkMaps to Arnold shader networks. We can use the SdrRegistry to read default values.

Support building all the components at once.

Currently, it's not easily possible to build both the schemas and the plugins at the same time. While this is a good fit for rez based / multiple packages approaches, it's not a universal fit for everyone.

render delegate: support displayColor

For the default shader, would be nice to support primvars:displayColor, like GL stream renderer, and make the shader a lambert
for usdview support, this would require handling the usdview default light in some manner

Does it support only USD-Arnold MtoA1.4?

Modules
Current
We support MtoA-1.2 and MtoA-1.4.
Does this mean that code support only MtoA-1.2 and MtoA-1.4.Because Maya comes with 3.2 now. is the code old or has been updated now?
Can you please help me to understand?

Support Windows.

Currently, the build process only supports Linux, this needs to be fixed.

Support subdivision settings and crease weights

As the title says. Add support for subdivision settings (coming from the HdMeshTopology), setting up the subdiv crease weights for edges and vertices and using the display style to set subdivision levels.

Handling node updates

Not only we have to handle syncing of all the parameters, but we need to dirty and restart renders if anything has changed.

Support linking against monolithic USD builds

USD supports the option to compile all of its modules into a single monolithic shared library or archive, rather than individual libraries for each module (Tf, Sdf, Usd, etc).

Thus, we should eventually add support for linking against monolithic libraries as well.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.