Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AY-7235 Restrict shot/plate/audio instance collection from selected clips in the timeline #45

Merged
merged 7 commits into from
Feb 12, 2025

Conversation

robin-ynput
Copy link
Contributor

@robin-ynput robin-ynput commented Feb 4, 2025

Changelog Description

resolve #36
These changes allows to restrict the collection of plate, shot and audio instances via a newly added creator setting.
An additional check is added to ensure associated shot instances are also enabled.

Additional review information

Testing notes:

  1. Prepare a timeline in Hiero with shot and clip (ideally multi-track using vertical align feature)
  2. Create instances from the creator using this timeline
  3. Package and upload this version to your local server as it adds a new setting.
  4. Enable ayon+settings://hiero/create/CollectShotClip/collectSelectedInstance setting
  5. Reopen Hiero and select only some of the "created" clips
  6. Open creator or publisher
  7. Ensure only the product(s) related to the selected clips are collected

Copy link
Contributor Author

@robin-ynput robin-ynput Feb 4, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jakubjezek001 @iLLiCiTiT @BigRoy what do you think about this approach (code is not ready for prod yet) ?

Basically client asked to be able to filter out collected instances from the product list based on timeline selection.
That's something too long for them to do manually.

Ideally I'd have like to be able to tweak the collector logic and collect only the relevant instances based on some UI settings, but I could not find anything like that (collection filters or specific UX button which act on collected instances).

So I went with this: a context plugin that ditch out any instance that is not relevant based on selection.
It's not very elegant, and I don't like the fact that the user cannot check what is detected before hitting "Publish", but I could not find anything better.

Any better ideas ?

EDIT: @iLLiCiTiT suggested another way by allowing a custom collection restrected to selected clips via a server settings. (Which honestly I believe is a better approach.)

Copy link
Member

@jakubjezek001 jakubjezek001 Feb 5, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This issue is somewhat related to the Ayon Core issue Publisher editorial linked instances with grouping view #874. How are they linked? A selected clip on the Hiero timeline can generate four products: shot, plate, audio, and effect. This new grouped way of visualizing products might add another layer of interactivity. For example, if the settings allow it in the creator settings, you could control the active state of a product group based on the active timeline selection.

I realize this might go beyond the scope of this PR, but having editorial-related grouping would greatly simplify the user experience. Currently, there's a limitation that doesn't allow disabling a group of products based on the shot-related context.

Given the current limitation, it seems best to control the creator's active toggle based on the active selection. However, it would be better to enable this from the Creator settings.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah I agree with you that ideally this would be made easier through the grouping feature.
As this is quite another topic that would impact much more than this repo/workfilow, I have followed @iLLiCiTiT recommendation and implemented a solution using a creator plugins.

Let me know if that works for you for now.

@robin-ynput robin-ynput added sponsored This is directly sponsored by a client or community member type: enhancement Improvement of existing functionality or minor addition labels Feb 4, 2025
@robin-ynput robin-ynput self-assigned this Feb 4, 2025
@iLLiCiTiT
Copy link
Member

From my point of view, if we want to respect selection then it should happen in create, not in publish. Current approach would just disable instance, and artist would have no idea that it happened.

The logic in create (collect_instances) might be also confusing as it may change enabled/disabled state on publisher reset, but there is definetelly more control for user to affect it.

We probably should store "user state of enabled" and use that value when instance is selected, so if he does turn off plates and resets publisher, it does not re-enable them.

@jakubjezek001 jakubjezek001 marked this pull request as ready for review February 10, 2025 10:54
@robin-ynput robin-ynput changed the title Validate approach to solve AY-7235 AY-7235 Restrict shot/plate/audio instance collection from selected clips in the timeline Feb 10, 2025
Copy link
Member

@jakubjezek001 jakubjezek001 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes it works as it should

@robin-ynput robin-ynput merged commit 4c76095 into develop Feb 12, 2025
1 check passed
@robin-ynput robin-ynput deleted the enhancement/AY-7235_publish_only_selected_clips branch February 12, 2025 09:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
sponsored This is directly sponsored by a client or community member type: enhancement Improvement of existing functionality or minor addition
Projects
None yet
Development

Successfully merging this pull request may close these issues.

AY-7235_Publish to optionally disable plates and shots that have no clips selected
3 participants