第1种索引值-变化不定
index
第2种索引值-以某一个图层作为开始索引值的基准图层
startIndex = thisComp.layer("Start").index; // 定义"Start"图层的index值myIndex = index - startIndex; // 实际索引值=当前图层索引值-start图层索引值
startIndex = thisComp.layer("Start").index; // 定义"Start"图层的index值
myIndex = index - startIndex; // 实际索引值=当前图层索引值-start图层索引值
第3种索引值-当前目标“开始-结尾”图层之间的索引值总数
startIndex = thisComp.layer("Start").index; // 定义"Start"图层的index值
endIndex = thisComp.layer("End").index; //定义“End”图层的index值得
//myIndex = index - startIndex; // 实际索引值=当前图层索引值-start图层索引值
totalIndex = endIndex - startIndex - 1; // Start图层与End图层之间的图层总数
第4种索引值-反向求出越底层的图层索引值越小
目前是正向排序
目前是反向排序
利用索引值来计算自动排序:
startIndex = thisComp.layer("Start").index;
endIndex = thisComp.layer("End").index;
a = index - startIndex;
totalIndex = endIndex - startIndex;
b = totalIndex - a;
//求出当前图层索引值
x = thisComp.layer("及时雨").transform.position[0];
y = thisComp.layer("及时雨").transform.position[1]+(b-1)*thisComp.layer("Control").effect("间距")("Slider");
[x,y];
//自动绑定Y轴坐标值







网友评论