TCAX 字幕特效制作工具官方论坛 | ASS | TCAS | Python | Aegisub | Lua

 找回密码
 新人加入
查看: 6669|回复: 4
打印 上一主题 下一主题

Aegisub 特效字幕模板:逐字淡入淡出(卡拉OK版+转场版) [复制链接]

Rank: 4

跳转到指定楼层
楼主
发表于 2021-5-8 20:13:09 |只看该作者 |正序浏览
本帖最后由 Seekladoom 于 2022-1-25 21:02 编辑

Aegisub 特效字幕模板:逐字淡入淡出(卡拉OK版+转场版).rar (0 Bytes, 下载次数: 2152)

备份下载地址

备份1:伪射手网
备份2:SUBHD
备份3:字幕库
备份4:github

卡拉OK版
  1. [Script Info]
  2. ; Script generated by Aegisub 3.2.2
  3. ; http://www.aegisub.org/
  4. Title:
  5. ScriptType: v4.00+
  6. WrapStyle: 0
  7. PlayResX: 1920
  8. PlayResY: 1080
  9. ScaledBorderAndShadow: no
  10. Video Aspect Ratio: 0
  11. Video Zoom: 6

  12. [Aegisub Project Garbage]
  13. Video File: ?dummy:23.976000:120000:1920:1080:120:120:120:
  14. Video AR Value: 1.777778
  15. Video Zoom Percent: 0.375000
  16. Active Line: 5
  17. Video Position: 187

  18. [V4+ Styles]
  19. Format: Name, Fontname, Fontsize, PrimaryColour, SecondaryColour, OutlineColour, BackColour, Bold, Italic, Underline, StrikeOut, ScaleX, ScaleY, Spacing, Angle, BorderStyle, Outline, Shadow, Alignment, MarginL, MarginR, MarginV, Encoding
  20. Style: Comment-furigana,更纱黑体 SC Semibold,35,&H00FFFFFF,&H000000FF,&H00000000,&H00000000,0,0,0,0,100,100,0,0,1,1,0,5,10,10,10,1
  21. Style: Default-furigana,更纱黑体 SC Semibold,35,&H00FFFFFF,&H000000FF,&H00000000,&H00000000,0,0,0,0,100,100,0,0,1,1,0,5,10,10,10,1
  22. Style: Default,更纱黑体 SC Semibold,70,&H00FFFFFF,&H000000FF,&H00000000,&H00000000,0,0,0,0,100,100,0,0,1,2,0,5,10,10,10,1
  23. Style: Comment,更纱黑体 SC Semibold,70,&H00FFFFFF,&H000000FF,&H00000000,&H00000000,0,0,0,0,100,100,0,0,1,2,0,5,10,10,10,1

  24. [Events]
  25. Format: Layer, Start, End, Style, Name, MarginL, MarginR, MarginV, Effect, Text
  26. Dialogue: 0,0:00:00.00,0:00:00.00,Comment,-----template行-----,0,0,0,,
  27. Comment: 2,0:00:00.00,0:00:00.00,Default,,0,0,0,template char noblank,!retime("start2syl",($si-1)*30-200,0)!{\an5\pos($center,$middle)\1c&H000000&\3c&HFFFFFF&\blur2\fad(200,0)}
  28. Comment: 2,0:00:00.00,0:00:00.00,Default,,0,0,0,template char noblank,!retime("syl",0,0)!{\an5\pos($center,$middle)\blur2\1c&H000000&\3c&HFFFFFF&\t(0,$sdur,\1c&HFFFFFF&\3c&H000000&)}
  29. Comment: 2,0:00:00.00,0:00:00.00,Default,,0,0,0,template char noblank,!retime("syl2end",0,($si-1)*30+200)!{\an5\pos($center,$middle)\1c&HFFFFFF&\3c&H000000&\blur2\fad(0,200)}
  30. Dialogue: 0,0:00:00.00,0:00:00.00,Comment,-----K值行-----,0,0,0,,
  31. Comment: 0,0:00:01.00,0:00:06.00,Default,,0,0,0,karaoke,{\k36}透{\k36}过{\k36}特{\k36}效{\k36}字{\k36}幕{\k36}给{\k36}观{\k36}众{\k36}传{\k36}达{\k36}爱{\k36} {\k36}Aegisub
复制代码

转场版
  1. [Script Info]
  2. ; Script generated by Aegisub 3.2.2
  3. ; http://www.aegisub.org/
  4. Title:
  5. ScriptType: v4.00+
  6. WrapStyle: 0
  7. PlayResX: 1920
  8. PlayResY: 1080
  9. ScaledBorderAndShadow: no
  10. Video Aspect Ratio: 0
  11. Video Zoom: 6

  12. [Aegisub Project Garbage]
  13. Video File: ?dummy:23.976000:120000:1920:1080:120:120:120:
  14. Video AR Value: 1.777778
  15. Video Zoom Percent: 0.375000
  16. Active Line: 4
  17. Video Position: 24

  18. [V4+ Styles]
  19. Format: Name, Fontname, Fontsize, PrimaryColour, SecondaryColour, OutlineColour, BackColour, Bold, Italic, Underline, StrikeOut, ScaleX, ScaleY, Spacing, Angle, BorderStyle, Outline, Shadow, Alignment, MarginL, MarginR, MarginV, Encoding
  20. Style: Comment-furigana,更纱黑体 SC Semibold,35,&H00FFFFFF,&H000000FF,&H00000000,&H00000000,0,0,0,0,100,100,0,0,1,1,0,5,10,10,10,1
  21. Style: Default-furigana,更纱黑体 SC Semibold,35,&H00FFFFFF,&H000000FF,&H00000000,&H00000000,0,0,0,0,100,100,0,0,1,1,0,5,10,10,10,1
  22. Style: Default,更纱黑体 SC Semibold,70,&H00FFFFFF,&H000000FF,&H00000000,&H00000000,0,0,0,0,100,100,0,0,1,2,0,5,10,10,10,1
  23. Style: Comment,更纱黑体 SC Semibold,70,&H00FFFFFF,&H000000FF,&H00000000,&H00000000,0,0,0,0,100,100,0,0,1,2,0,5,10,10,10,1

  24. [Events]
  25. Format: Layer, Start, End, Style, Name, MarginL, MarginR, MarginV, Effect, Text
  26. Dialogue: 0,0:00:00.00,0:00:00.00,Comment,-----template行-----,0,0,0,,
  27. Comment: 2,0:00:00.00,0:00:00.00,Default,,0,0,0,template char noblank,!retime("line",($si-1)*30-200,-$syln*30)!{\an5\pos($center,$middle)\blur3\fad(200,0)}
  28. Comment: 2,0:00:00.00,0:00:00.00,Default,,0,0,0,template char noblank,!retime("line",$ldur-$syln*30,($si-$syln)*30+200)!{\an5\pos($center,$middle)\blur3\fad(0,200)}
  29. Dialogue: 0,0:00:00.00,0:00:00.00,Comment,-----K值行-----,0,0,0,,
  30. Comment: 0,0:00:01.00,0:00:06.00,Default,,0,0,0,karaoke,{\k36}透{\k36}过{\k36}特{\k36}效{\k36}字{\k36}幕{\k36}给{\k36}观{\k36}众{\k36}传{\k36}达{\k36}爱{\k36} {\k36}Aegisub
复制代码

Rank: 4

5#
发表于 2023-3-18 20:31:43 |只看该作者
谢楼主了!

Rank: 4

地板
发表于 2022-3-17 03:08:34 |只看该作者
本帖最后由 Seekladoom 于 2022-3-17 03:27 编辑

写法对比(逐字淡入淡出):

TCAX
  1. from tcaxPy import *

  2. def tcaxPy_Init():
  3.     pass

  4. def tcaxPy_Main(_i, _j, _n, _BT, _ET, _SK, _KT, _X, _Y, _A, _TXT):
  5.     ASS_BUF  = []                # 保存ASS特效

  6.     ass_main(ASS_BUF,SubL(_BT - 20 + _n * 30,_ET + 20 + _n * 30, 1),an(5)+pos(_X,_Y)+fad(200,200), _TXT)
  7.         
  8.     return (ASS_BUF,None)
复制代码

PyonFX
  1. from pyonfx import *

  2. io = Ass("CN.ass")
  3. meta, styles, lines = io.get_data()

  4. def CN(line, l):
  5.     # Translation Effect
  6.     for syl in Utils.all_non_empty(line.chars):
  7.         l.layer = 0
  8.         l.start_time = line.start_time - 200 + (syl.i*30)
  9.         l.end_time = line.end_time + 200 + (syl.i*30)
  10.         l.text = "{\\an5\\pos(%.f,%.f)\\fad(200,200)}%s" % (syl.center, syl.middle, syl.text)
  11.         io.write_line(l)
  12.    
  13. # Generating lines
  14. for line in lines:
  15.     if line.styleref.alignment > -1:
  16.         CN(line, line.copy())
  17. io.save()
  18. io.open_aegisub()
复制代码

Rank: 4

板凳
发表于 2022-3-17 02:43:08 |只看该作者
本帖最后由 Seekladoom 于 2022-3-17 02:55 编辑

PyonFX 单行文本测试(逐字淡入淡出).rar (2.64 KB, 下载次数: 1469)
PyonFX的逐字淡入淡出:
  1. from pyonfx import *

  2. io = Ass("CN.ass")
  3. meta, styles, lines = io.get_data()

  4. def CN(line, l):
  5.         # Translation Effect
  6.         for syl in Utils.all_non_empty(line.chars):
  7.                 l.layer = 0
  8.                 l.start_time = line.start_time - 200 + (syl.i*30)
  9.                 l.end_time = line.end_time + 200 + (syl.i*30)
  10.                 l.text = "{\\an5\\pos(%.f,%.f)\\fad(200,200)}%s" % (syl.center, syl.middle, syl.text)
  11.                 io.write_line(l)
  12.         
  13. # Generating lines
  14. for line in lines:
  15.         if line.styleref.alignment > -1:
  16.                 CN(line, line.copy())
  17. io.save()
  18. io.open_aegisub()
复制代码

Rank: 4

沙发
发表于 2022-1-25 11:31:24 |只看该作者
本帖最后由 Seekladoom 于 2022-1-25 12:03 编辑

TCAX的淡入淡出特效(此处有py脚本中整体拆分单词的方法):
http://www.tcax.org/forum.php?mod=viewthread&tid=526


↑↑↑↑↑不直接使用tcc文件将英文词汇进行拆分的方法↑↑↑↑↑
您需要登录后才可以回帖 登录 | 新人加入

GitHub|TCAX 主页

GMT+8, 2024-11-22 06:55

Powered by Discuz! X2

© 2001-2011 Comsenz Inc.

回顶部
RealH