Skip to content

User Environment Plugin #113

Description

@davidlatwe

Feature Propose

Allzpark allows user to inject environment change on Rez resolved context with it's environment editor widget, this is good for e.g. input VFX asset/shot name into the production pipeline context when required. However the widget is basically a plain text editor, so it's not really convenient for artist to use in their daily work.

So I propose to let Allzpark be able to accept custom widget e.g. Avalon mini launcher, and give that widget the ability to read/write/validate the user environment editor content.

Implementation

The custom widget can be loaded from allzparkconfig.py, e.g.

# allzparkconfig.py
def user_environment_plugin():
    from pipeline import tool
    return tool.AllzparkPlugin

Once it's been collected, Allzpark should validate the required signals and slots, e.g. :

  • on_launched, a slot that will be called right before launching the application, Rez resolved env and the user env will be given. This gives the chance to validate the context.
  • userEnvValidated, a signal for emitting the validation result, stop application launch if any message being emitted and log the message into Allzpark console.
  • userEnvChanged, a signal for emitting user environment key-value pairs from widget in one batch. This will not overwrite but update the content of Allzpark's user environment editor.
  • on_profile_changed, a slot that will be called on profile change. May give widget the ability to adopt current selected profile.
  • userEnvReset, a signal for wipe out user environment editor.

Then the widget will be added into one additional dock widget and present on the GUI header, next to the profiles toggle button.

One environment plugin per Allzpark config should be enough.

What do you think ?

Metadata

Metadata

Assignees

No one assigned

    Labels

    featureAdds new behaviour or a significant change

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions