2016-05-08 8 views

答えて

1

これはスクリプトによって実現できます。 私はこれら2つのスクリプトを用意しています。私はずっと前にそれらを書きました。たぶんあなたはいくつかの調整をする必要があります。

これは、csvファイルからいくつかのテキストレイヤーを追加します。

https://github.com/fabiantheblind/after-effects-script-snippets/blob/master/comp_with_text.jsx

この1つは、CSVの内容に設定されたソース・テキストを1つのテキストレイヤーを追加する必要があります。

https://github.com/fabiantheblind/after-effects-script-snippets/blob/master/text_to_comp.jsx

これはsourceText

/** 
* main function 
*/ 
var main = function() { 
    var txt = ['Hello - World', 'dog -cat', 'foo - bah']; // the text to add 
    app.beginUndoGroup('add source text'); // open a undo group 
    var curComp = app.project.activeItem; // get the current comp 
    // check if the curent active item is a comp 
    if (!curComp || !(curComp instanceof CompItem)) { 
    alert('noComp'); 
    return; 
    // end if no comp is active 
    } 
    var txtLayer = curComp.layers.addText('titles'); // add a text layer 
    var counter = 0; // the time to add a keyframe to (in seconds) 
    // loop the text 
    for (var i = 0; i < txt.length; i++) { 
    var curFrame = (counter/curComp.frameRate); // calc time for each frame 
    $.writeln(curFrame); 
    // add a keyframe with the text as value every frame 
    txtLayer.text.sourceText.setValueAtTime(curFrame, txt[i]); 
    counter++; // increase the time by one 
    } 
    app.endUndoGroup(); 
}; 
main(); 
とテキストレイヤーを追加するために、最小限の例であります
関連する問題