OpenPype icon indicating copy to clipboard operation
OpenPype copied to clipboard

Maya: Build workfile by template

Open iLLiCiTiT opened this issue 2 years ago • 1 comments

Modified source PR. Code was moved from openpype/lib into openpype/pipeline/workfile to match refactor goals we're working on right now.

Was modified by PR which changed how placeholders work primarily because of mongo queries.

Brief description

Following discussion #2013 and resumption of work from ellipsanime #2202

Templated Build Workfile

Building a workfile using a template designed by users. Helping to assert homogeneous subsets hierarchy and imports. Template stored as file easy to define, change and customize for production needs.

1. Make a template

Make your template. Add families and everything needed for your tasks. Here is an example template for the modeling task using a placeholder to import a gauge.

maya-workfile-outliner

If needed, you can add placeholders when the template needs to load some assets. OpenPype > Template Builder > Create Placeholder

maya-create_placeholder

  • Configure placeholders

Fill in the necessary fields (the optional fields are regex filters)

maya-placeholder_new

- Builder type: Wether the the placeholder should load current asset representations or linked assets representations

- Representation: Representation that will be loaded (ex: ma, abc, png, etc...)

- Family: Family of the representation to load (main, look, image, etc ...)

- Loader: Placeholder loader name that will be used to load corresponding representations

- Order: Priority for current placeholder loader (priority is lowest first, highet last)
  • Save your template

2. Configure Template

  • Go to Studio settings > Project > Your DCC > Templated Build Settings
  • Add a profile for your task and enter path to your template

template_build_workfile

3. Build your workfile

  • Open maya

  • Build your workfile

maya-build_workfile_from_template

Testing notes:

  • [ ] Deadline should find representation resources as did (do we need that functionality?)
  • [ ] Placeholder templates should work as described above

iLLiCiTiT avatar Jul 27 '22 08:07 iLLiCiTiT

Current state adds a lot of stuff we're trying to avoid and remove with OpenPype refactor. So I expect this feature will change in near future a lot and will break backwards compatibility few times.

For example how representations are queried which is against our goal of not using direct mongo queries in code which is at this moment 100% dependent on using mongo syntax.

iLLiCiTiT avatar Jul 28 '22 14:07 iLLiCiTiT