Skip to content

Commit

Permalink
Adjust clip duplication check logic and form unique key for used clips.
Browse files Browse the repository at this point in the history
- Refactored condition to handle clip boundaries.
- Added formation of a unique key for each used clip.
  • Loading branch information
jakubjezek001 committed Nov 7, 2024
1 parent 785925f commit a2a30b5
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions client/ayon_hiero/api/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -914,17 +914,19 @@ def _convert_to_tag_data(self):
then skip this clip and do not add to hierarchical shared
metadata to them.
"""
if self.clip_in < hero_in and self.clip_out > hero_out:
if self.clip_in < hero_in or self.clip_out > hero_out:
continue

_distrib_data = deepcopy(hero_data)
_distrib_data["heroTrack"] = False

# form used clip unique key
data_product_name = hero_data["productName"]
new_clip_name = hero_data["newClipName"]

# get used names list for duplicity check
used_names_list = self.vertical_clip_used.setdefault(
data_product_name, []
)
f"{new_clip_name}{data_product_name}", [])

clip_product_name = self.product_name

Expand Down

0 comments on commit a2a30b5

Please sign in to comment.