• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
2

Copy Layer markers to Comp markers

Contributor ,
Dec 07, 2023 Dec 07, 2023

Copy link to clipboard

Copied

I need a way to make comp markers from layer markers with their comments. I can make layer markers from nested comp markers with Update markers from Source, I can copy markers from one layer to another with the rd_CopyMarkers script, but i can not create markers or copy the comments from layer markers to comp markers in any automated way.  For a VERY long time I have been trying to figure out how, but to the best of my knowledge there is no way to do this except manually. I can't find a script or addon that does this and have been try to automate this process with my own scripts, but it does not work. i don't think there is even a scripting way to do this. no matter how i approach it, i can't figure it out.  can this please be implemented?

Idea Acknowledged
TOPICS
Workflow

Views

96

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
2 Comments
Adobe Employee ,
Dec 07, 2023 Dec 07, 2023

Copy link to clipboard

Copied

Hi @TheFosterHouse,

Thanks very much for this request, I've created a ticket for our team to review. What type of workflow do you think would benefit from this feature?

 

It is definitely possible to accomplish this via scripting. Below is a short script that will copy layer markers from selected layers to comp markers with comments, labels, etc. It can also remove the layer markers, but I've left that commented out.

 

(function copyLayerMarkersToComposition() {
  var activeComp = app.project.activeItem instanceof CompItem && app.project.activeItem;

  if (!activeComp || !activeComp.selectedLayers.length) {
    alert("Please select a layer with markers.");
    return null;
  }

  app.beginUndoGroup("Copy layer markers to composition");

  try {
    var currentLayer, markerValue, markerTime, markerCopy;

    for (var l = 0; l < activeComp.selectedLayers.length; ++l) {
      currentLayer = activeComp.selectedLayers[l];

      for (var m = currentLayer.marker.numKeys; m; --m) {
        markerValue = currentLayer.marker.keyValue(m);
        markerTime = currentLayer.marker.keyTime(m);
        markerCopy = getAllMarkerSettings(markerValue);

        activeComp.markerProperty.setValueAtTime(markerTime, markerCopy);

        // Uncomment this line to remove layer markers
        // currentLayer.marker.removeKey(m);
      }
    }
  } catch (err) {
    alert(err.description);
  } finally {
    app.endUndoGroup();
  }

  function getAllMarkerSettings(marker) {
    var params = marker.getParameters(),
      newMarker = new MarkerValue("");

    newMarker.setParameters(params);

    for (var i in marker) {
      newMarker[i] = marker[i];
    }

    return newMarker;
  }
})();

 Cheers,

- John, After Effects Engineering Team 

Votes

Translate

Translate

Report

Report
Contributor ,
Dec 07, 2023 Dec 07, 2023

Copy link to clipboard

Copied

LATEST

@JohnColombo Thank you so much! I don't even know how long I've been searching for a solution to this! I'm a VFX Artist. When I'm compositing several shots in one scene, I will usually get shots grouped together that are shot from the same angle. I can string them together in one Comp and composite them all as one shot. the footage is precomped to one layer so it can be degrained and clean plated as one layer. This is so all my background & DMP layers, set extension, matting, keying settings, etc. are consistent through all the shots in that scene from that angle. If something needs changing, I only need to change it once.  I have scripts that set all this up, makes my render comps edited from the main strung together work comp. Each shot in my main work comp is separated by layer markers with the shot name at the first frame of each shot. If my layer stack gets really long I have to search for where those markers are, but if they're in the comp markers section, They'll always be visible. 

Votes

Translate

Translate

Report

Report