Skip to content

Commit

Permalink
Merge branch 'main' into AY-5178_Traypublisher-user-perspective
Browse files Browse the repository at this point in the history
  • Loading branch information
jakubjezek001 authored May 22, 2024
2 parents 2ad6033 + 327e1b4 commit 657ce87
Show file tree
Hide file tree
Showing 13 changed files with 138 additions and 32 deletions.
37 changes: 37 additions & 0 deletions website/docs/addon_maya_admin.md
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,43 @@ When you publish your model with top group named like `foo_GRP` it will fail. Bu
All regexes used here are in Python variant.
:::

### Extract Alembic

`ExtractAlembic`

![ExtractAlembic](assets/maya/admin/alembic_settings.png)

The settings below will become the default when extracting the alembics for `pointcache` and `animation`. Any attributes exposed in `Exposed Overrides` will be visible to the users to edit when publishing. When a user edits an attribute, the default settings below no longer has any effects on the publishing values. To enforce settings even when exposing attributes, you can utilize the validators; `ValidateAlembicDefaultsPointcache` and `ValidateAlembicDefaultsAnimation`.

- **Euler Filter**: Apply Euler filter while sampling rotations.
- **Renderable Only**: Only export renderable visible shapes.
- **Strip Namespaces**: Namespaces will be stripped off of the node before being written to Alembic.
- **UVs Only**: If this flag is present, only uv data for PolyMesh and SubD shapes will be written to the Alembic file.
- **UV Write**: UV data for PolyMesh and SubD shapes will be written to the Alembic file.
- **Verbose**: Prints the current frame that is being evaluated.
- **Visible Only**: Only export dag objects visible during frame range.
- **Whole Frame Geo**: Data for geometry will only be written out on whole frames.
- **World Space**: Any root nodes will be stored in world space.
- **Write Color Sets**: Write vertex colors with the geometry.
- **Write Face Sets**: Write face sets with the geometry.
- **Write Normals**: Write normals with the deforming geometry.
- **Write UV Sets**: Write all uv sets on MFnMeshes as vector 2 indexed geometry parameters with face varying scope.
- **Write Visibility**: Visibility state will be stored in the Alembic file. Otherwise everything written out is treated as visible.
- **Pre Roll**: When enabled, the pre roll start frame is used to pre roll the evaluation of the mesh. From the pre roll start frame to the Alembic start frame, will not be written to disk. This can be used for simulation run-up.
- **Pre Roll Start Frame**: The frame to start scene evaluation at. This is used to set the starting frame for time-dependent translations and can be used to evaluate run-up that isn't actually translated. NOTE: Pre Roll needs to be enabled for this start frame to be considered.
- **Data Format**: The data format to use to write the file.
- **Bake Attributes**: List of attributes that will be included in the Alembic export.
- **Bake Attribute Prefixes**: List of attribute prefixes for attributes that will be included in the Alembic export.
- **Custom Attributes**: Attributes matching by name will be included in the Alembic export. Attributes should be separated by semi-colon ;.
- **Custom Attributes Prefix**: Attributes starting with these prefixes will be included in the Alembic export. Attributes should be separated by semi-colon ;.
- **User Attr**: Attributes matching by name will be included in the Alembic export. Attributes should be separated by semi-colon ;.
- **User Attr Prefix**: Attributes starting with these prefixes will be included in the Alembic export. Attributes should be separated by semi-colon ;.
- **Mel Per Frame Callback**: When each frame (and the static frame) is evaluated the string specified is evaluated as a Mel command.
- **Mel Post Job Callback**: When the translation has finished the string specified is evaluated as a Mel command.
- **Python Per Frame Callback**: When each frame (and the static frame) is evaluated the string specified is evaluated as a python command.
- **Python Post Job Callback**: When the translation has finished the string specified is evaluated as a python command.
- **Exposed Overrides**: These are the attributes from above that will be exposed in the publisher for users to edit when publishing.

## AYON Tools
You can add your custom tools menu into Maya by extending definitions in **Maya -> Scripts Menu Definition**.

Expand Down
93 changes: 64 additions & 29 deletions website/docs/addon_maya_arnold_artist.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,44 +11,82 @@ import versions from '@site/docs/assets/json/Ayon_addons_version.json'
{versions.Maya_Badge}
</ReactMarkdown>

You are able to create two types of **Arnold Scene Source** product

- Arnold Scene Source
- Arnold Scene Source Proxy

![Publish instance types](assets/maya/artist/ass_publish_types.png)

## Arnold Scene Source (.ass)
Arnold Scene Source can be published as a single file or a sequence of files, determined by the frame range.
**Arnold Scene Source** contains whatever user selects when creating the publish instance. Arnold Scene Source can be published as a single file or a sequence of files and its determined by the frame range set on the publish instance. Use those values for producing still or animated `standin`.

![Publish instance framerange](assets/maya/artist/ass_publish_framerange.png)

### Arnold Scene Source Proxy
The main difference of this product type being possibility to use proxy geometries for viewport performance reasons. If this is not an issue use the first standin type instead.
Once the publish instance have been created, there is a `proxy_SET` created inside of the `Main_SET`. Meshes assigned to the `proxy_SET` will be the viewport representation of the `standin`. Once render triggered, they are switched for the content of the `Main_SET` on the fly.
In order to utilize operators and proxies on the `standin`, the content and proxy nodes need to share the same names (including the shape names
and cbIDs).

:::note
You can duplicate content keeping all its attributes using maya `Group` for objects used in `Main_SET` and `proxy_SET` each being in distinct `Group` as maya does not allow having the same objects within the same hierarchy.
:::

![Ass Proxy Sets](assets/maya/artist/ass_proxy_sets.gif)

Here you can see we are having `Content_GRP` for renderable objects and `Proxy_GRP` for viewable objects in the maya viewport. Each having the same objects inside as duplicates differing only by level of detail. Note that offset of `Proxy` objects is just for sake of clarity and normally would be in the exact same location as high detail meshes for rendering aka `Content_GRP`.

:::note
Use **Arnold Scene Source** product instead as there are not so many requirements / constraints when creating it if viewport performance not an issue.
:::

### Validation of the Arnold Scene Source publishes

When creating the instance, two objectsets are created; `content` and `proxy`. Meshes in the `proxy` objectset will be the viewport representation when loading as `standin`.
After triggering publishing via Publisher a round of different validation checks being triggered informing user if anything setup wrong and offering set of `Repair` actions to fix those issues.

### Arnold Scene Source Proxy Workflow
`AssMain` set is created with `assMain_content_SET` and `assMain_proxy_SET` as its children.
In order to utilize operators and proxies, the content and proxy nodes need to share the same names (including the shape names
and CBIDs). This is done by parenting the content and proxy nodes into separate groups. For example:
Most common `Validator` is for checking proper asset hierarchy. Just by following the report you are able to adjust your scene hierarchy to match the desired one.

![Arnold Scene Source](assets/maya/artist/arnold_scene_source.png)
Here is an example of wrong hierarchy set as the model `Groups` assigned to the `standin` being children of the World and no such a hierarchy being allowed so need to be adjusted properly.

Once you put geometry contents(grouped objects) and proxy groups respectively into contents and proxies set,
you are ready to see if it passes validation and gets published.
![Ass Validator Hierarchy](assets/maya/artist/ass_validator_hierarchy.png)

Besides the grouped contents and proxies, you can put meshes and proxies into contents and proxies set.
It would pass validation too and gets published.
And the invalid hierarchy seen in the Maya Outliner

![Mesh Objects for contents and proxies sets](assets/maya/artist/creator_sets.png)
![Ass Validator Hierarchy 2](assets/maya/artist/ass_validator_hierarchy2.png)

Validators `ASS has relative texture paths` and `Validate Arnold Scene Source CBID` can allow you to set up
the context correctly by using repair function.
Instead of having the `Content_GRP` and `Proxy_GRP` in the `standin` sets, you should put in the actual `objects` geometries instead to fix this validation failure. As seen below the correct one:

![Ass Validator Hierarchy 3](assets/maya/artist/ass_validator_hierarchy3.png)


Validators `ASS has relative texture paths` and `Validate Arnold Scene Source cbID` allows you to set up
the context correctly by using `Repair` action.

![Arnold Scene Source Validators](assets/maya/artist/validators_ass_family.png)

Once you pass the validator, you can publish your contents and proxies.
## Standin
Arnold Scene Source `ass` and Alembic `abc` are supported to load as standins.
When you load `ass` when the loaders, it will import two `ass` groups with standins as children.
Both standins load `_proxy` ass files by default, and you can choose to change the `content`
manually by clicking file icon in the standin and change the files with `_proxy` naming conventions.
Once all `Validators` being resolved you are ready to publish the `Arnold Scene Source` aka `Standin` product with the `.ass` representation being ready to be loaded using `Loader` tool located in the `Ayon toolset`.

## Using Standins

You can use published `standin` in your workfile via `AYON / Load` action. User is able to load `Arnold Scene Source` , `Arnold Scene Source Proxy` and even `Alembic` products as `standin` allowing taking advantage of arnold features also for other products like `animation` and `pointcache`.

![Arnold Scene Source Loaders](assets/maya/artist/ass_loader.gif)

![Arnold Scene Source Loaders](assets/maya/artist/ass_loader.png)
:::note Arnold Standins
You can highly optimize your workfiles by introducing `standins` instead of regular reference loading of products like `animation` as there wont be any files referenced-in just local `standin` but still managable using `Scene Inventory`.
:::

## Standins and LookDev
`Standin` supports `look` products and its assignment. If `look` product being available, You can assign the `look` to the loaded Arnold Scene Source `ass` and Alembic `abc` using

`AYON -> Look Assigner...`

## Look Development
Standin Nodes are now supported for look assignment.If you publish the look development object with the look family, while you publish the object with Arnold Scene Source. You can assign the look to the published Arnold Scene Source `ass` and Alembic `abc` through `AYON -> Look Assigner...` when you load it as standin.
:::note Current Standins Limitation
`Look` assignment is not possible when using `Arnold Scene Source Proxy`
:::

![Arnold Standin](assets/maya/artist/ass_look_assigner.png)
![Standin Look Assign](assets/maya/artist/ass_look_assign.gif)

:::note Limited support for shader assignments with standin nodes
Limited amount of attributes supported by using operator to assign shaders to the loaded standins.
Expand Down Expand Up @@ -76,14 +114,11 @@ aiSubdivIterations
```
:::

### Standin Proxy Workflow
If a product has a proxy representation, this will be used as display in the viewport. At render time the standin path will be replaced using the recommended string replacement workflow;
### Arnold Scene Source Proxy
If a product has a `proxy_SET` representation, this will be used as display in the viewport. At render time the standin path will be replaced using the recommended string replacement workflow:

https://help.autodesk.com/view/ARNOL/ENU/?guid=arnold_for_maya_operators_am_Updating_procedural_file_paths_with_string_replace_html

Since the content and proxy nodes share the same names and hierarchy, any manually shader assignments will be shared.


:::note for advanced users
You can stop the proxy swapping by disabling the string replacement operator found in the container.
![Arnold Standin](assets/maya/artist/arnold_standin.png)
Expand Down
40 changes: 37 additions & 3 deletions website/docs/addon_maya_artist.md
Original file line number Diff line number Diff line change
Expand Up @@ -352,7 +352,7 @@ Example setup:

| Create Point Cache | Adjust Hierarchy |
|--|--|
| ![Maya - PointCache 1 Example](assets/maya/artist/pointcache_setup_1.png) | ![Maya - PointCache 2 Example](assets/maya/artist/pointcache_setup_2.png) |
| ![Maya - PointCache 1 Example](assets/maya/artist/pointcache_setup_1.png) | ![Maya - PointCache 2 Example](assets/maya/artist/pointcache_setup_2.png) |

| Publish Point Cache |
|--|
Expand All @@ -366,11 +366,45 @@ Example setup:
- **Handle Start**: additional frames to export at frame end. Ei. frame end + handle end = export end.
- **Step**: frequency of sampling the export. For example when dealing with quick movements for motion blur, a step size of less than 1 might be better.
- **Refresh**: refresh the viewport when exporting the pointcache. For performance is best to leave off, but certain situations can require to refresh the viewport, for example using the Bullet plugin.
- **Attr**: specific attributes to publish separated by `;`.
- **AttrPrefix**: specific attributes which start with this prefix to publish separated by `;`.
- **Include User Defined Attribudes**: include all user defined attributes in the publish.
- **Farm**: if your studio has Deadline configured, artists could choose to offload potentially long running export of pointache and publish it to the farm. Only thing that is necessary is to toggle this attribute in created pointcache instance to True.
- **Priority**: Farm priority.
- **Include Parent Hierarchy**: Set the root nodes if we don't want to include parents. The roots are to be considered the ones that are the actual direct members of the set.
- **Visible Only**: Does not filter out nodes that are only hidden on some frames as it counts "animated" or "connected" visibilities as if it's always visible.

#### Alembic Options

![Maya - Alembic Options](assets/maya/artist/alembic_options.png)

:::note
These options can differ from settings depending on studios settings. Not all options below would be exposed in the publisher.
:::

- **Euler Filter**: Apply Euler filter while sampling rotations.
- **Renderable Only**: Only export renderable visible shapes.
- **Strip Namespaces**: Namespaces will be stripped off of the node before being written to Alembic.
- **UVs Only**: If this flag is present, only uv data for PolyMesh and SubD shapes will be written to the Alembic file.
- **UV Write**: UV data for PolyMesh and SubD shapes will be written to the Alembic file.
- **Verbose**: Prints the current frame that is being evaluated.
- **Visible Only**: Only export dag objects visible during frame range.
- **Whole Frame Geo**: Data for geometry will only be written out on whole frames.
- **World Space**: Any root nodes will be stored in world space.
- **Write Color Sets**: Write vertex colors with the geometry.
- **Write Face Sets**: Write face sets with the geometry.
- **Write Normals**: Write normals with the deforming geometry.
- **Write UV Sets**: Write all uv sets on MFnMeshes as vector 2 indexed geometry parameters with face varying scope.
- **Write Visibility**: Visibility state will be stored in the Alembic file. Otherwise everything written out is treated as visible.
- **Pre Roll**: When enabled, the pre roll start frame is used to pre roll the evaluation of the mesh. From the pre roll start frame to the Alembic start frame, will not be written to disk. This can be used for simulation run-up.
- **Pre Roll Start Frame**: The frame to start scene evaluation at. This is used to set the starting frame for time-dependent translations and can be used to evaluate run-up that isn't actually translated. NOTE: Pre Roll needs to be enabled for this start frame to be considered.
- **Data Format**: The data format to use to write the file.
- **Custom Attributes**: Attributes matching by name will be included in the Alembic export. Attributes should be separated by semi-colon ;.
- **Custom Attributes Prefix**: Attributes starting with these prefixes will be included in the Alembic export. Attributes should be separated by semi-colon ;.
- **User Attr**: Attributes matching by name will be included in the Alembic export. Attributes should be separated by semi-colon ;.
- **User Attr Prefix**: Attributes starting with these prefixes will be included in the Alembic export. Attributes should be separated by semi-colon ;.
- **Mel Per Frame Callback**: When each frame (and the static frame) is evaluated the string specified is evaluated as a Mel command.
- **Mel Post Job Callback**: When the translation has finished the string specified is evaluated as a Mel command.
- **Python Per Frame Callback**: When each frame (and the static frame) is evaluated the string specified is evaluated as a python command.
- **Python Post Job Callback**: When the translation has finished the string specified is evaluated as a python command.

### Loading Point Caches

Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added website/docs/assets/maya/artist/ass_loader.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 657ce87

Please sign in to comment.