TCAX 字幕特效制作工具官方论坛 | ASS | TCAS | Python | Aegisub | Lua
标题:
[内置特效EXT]光效test
[打印本页]
作者:
milkyjing
时间:
2011-9-1 18:03:21
标题:
[内置特效EXT]光效test
说明
感谢X大提供源代码(C#)
此效果出处:
http://u.115.com/file/clwyxisk#
[X]011_Asura_Cryin_OP.mkv
附件为预览及脚本下载
移植过来的py脚本, (TCAX内置特效兼容)
################################################################################
### description:
### shine
from tcaxPy import *
def tcaxPy_Init():
global _FD # frame duration, in millisecond
global _Fs
global Font
_FD = 1000 / GetVal(val_FXFPS)
_Fs = GetVal(val_FontSize)
Font = InitFont(GetVal(val_FontFileName), GetVal(val_FaceID), _Fs, GetVal(val_Spacing), GetVal(val_SpaceScale), 0xFFFFFF, 0, 0)
def tcaxPy_Fin():
FinFont(Font)
time_gap = 1 # you can change this value to 0, or 2 or any other number
time_fac = 1 # you can change this value to 0, or 2 or any other number
def tcaxPy_Main(_i, _j, _n, _start, _end, _elapk, _k, _x, _y, _a, _txt):
ASS_BUF = [] # used for saving ASS FX lines
TCAS_BUF = [] # used for saving TCAS FX raw data
ts = _start + _elapk - 20
te = _end + 7 * _j - 10
PIX = TextPix(Font, _txt)
points = PixPoints(PIX)
pt_num = len(points)
dx = _x - int(_a / 2 + 0.5) + PIX[0][0]
dy = _y - int(_Fs / 2 + 0.5) + PIX[0][1]
for i in range(pt_num):
ag = (dy + points[i][1] - _y) / GetVal(val_TextHeight)[_i][_j] * 0.25
iag = int(ag / pi / 2 * 360)
EFT = pos(dx + points[i][0], dy + points[i][1]) + frz(iag) + t(fry(180)) + fad(100, 500) + alpha1(HexToDec('F4')) + color1('6888FF') + be(1)
ass_main(ASS_BUF, SubL(ts, te, 10, Pix_Style), EFT, DrawLight(100))
return (ASS_BUF, TCAS_BUF)
复制代码
附件: [脚本]
ext_shine.py
(2011-9-1 18:04:28, 1.48 KB) / 下载次数 3185
http://tcax.org/forum.php?mod=attachment&aid=NDF8ZWQ0YmM1ZjB8MTczMjI1MDk4NHwwfDA%3D
附件: [预览]
preview.mp4
(2011-9-1 18:04:28, 176.06 KB) / 下载次数 3427
http://tcax.org/forum.php?mod=attachment&aid=NDB8MWQ0NDMxMjV8MTczMjI1MDk4NHwwfDA%3D
作者:
5231251
时间:
2011-9-1 21:52:43
收下了! milk大大继续啊
作者:
CMD
时间:
2018-2-12 10:10:13
谢谢楼主分享
作者:
CMD
时间:
2018-2-12 10:10:27
本帖最后由 CMD 于 2018-6-29 15:51 编辑
顶
作者:
weiyangacm
时间:
2018-7-3 23:12:22
学习一下
作者:
damo
时间:
2018-7-22 14:43:46
谢谢!
作者:
sdy623
时间:
2019-7-31 17:09:30
谢谢分享。
欢迎光临 TCAX 字幕特效制作工具官方论坛 | ASS | TCAS | Python | Aegisub | Lua (http://tcax.org/)
Powered by Discuz! X2