Skip to content

collect_comp

CollectCurrentCompFusion

Bases: ContextPlugin

Collect current comp

Source code in client/ayon_fusion/plugins/publish/collect_comp.py
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
class CollectCurrentCompFusion(pyblish.api.ContextPlugin):
    """Collect current comp"""

    order = pyblish.api.CollectorOrder - 0.4
    label = "Collect Current Comp"
    hosts = ["fusion"]

    def process(self, context):
        """Collect all image sequence tools"""

        current_comp = get_current_comp()
        assert current_comp, "Must have active Fusion composition"
        context.data["currentComp"] = current_comp

        # Store path to current file
        filepath = current_comp.GetAttrs().get("COMPS_FileName", "")
        context.data['currentFile'] = filepath

process(context)

Collect all image sequence tools

Source code in client/ayon_fusion/plugins/publish/collect_comp.py
13
14
15
16
17
18
19
20
21
22
def process(self, context):
    """Collect all image sequence tools"""

    current_comp = get_current_comp()
    assert current_comp, "Must have active Fusion composition"
    context.data["currentComp"] = current_comp

    # Store path to current file
    filepath = current_comp.GetAttrs().get("COMPS_FileName", "")
    context.data['currentFile'] = filepath