您当前的位置: 首页 > 

插件开发

暂无认证

  • 3浏览

    0关注

    492博文

    0收益

  • 0浏览

    0点赞

    0打赏

    0留言

私信
关注
热门博文

AfterEffect(AE)插件-常规功能开发-改变层上帧的属性-js脚本开发

插件开发 发布时间:2022-03-14 08:13:29 ,浏览量:3

文章目录
    • 1.算法程序
    • 2.作者答疑

1.算法程序

  AfterEffect(AE)插件是Adobe公司开发的特效制作软件,稳定快速的功能和特效,在视频制作领域使用非常广泛,本文向大家介绍如何在项目里进行改变层上帧的属性功能。源代码如下所示:

{
	// Convert Selected Properties to Markers.jsx
	// 
	// For each layer that contains selected properties, convert the value of the property at each
	// frame time to an event cue point.
	
	function ConvertSelectedPropertiesToMarkers()
	{
		var scriptName = "Convert Selected Properties to Markers";
		var propsSkipped = new Array();
		
		
		function ConvertPropertyToMarkers(markerStream, prop)
		{
			// Only do properties, not property groups.
			if (!(prop instanceof Property)) {
				return;
			}
		
			// Custom/No_Value property types are not supported, so skip gracefully (but log so we can display useful error message later).
			if ((prop.propertyValueType == PropertyValueType.CUSTOM_VALUE) || (prop.propertyValueType == PropertyValueType.NO_VALUE)) {
				// Log just the first 10 custom properties, as we don't want to display too big of an error message dialog to the user,
				if (propsSkipped.length  0; --depth) {
				owningLayer = owningLayer.parentProperty;
			}
			if (prop.expressionEnabled) {
				// For properties with enabled expressions, add markers at each frame between the In and Out points.
				var curTime = owningLayer.inPoint;
				var outTime = owningLayer.outPoint;
				for ( ; curTime             
关注
打赏
1665481431
查看更多评论
0.0366s