- UID
- 702
- 积分
- 1002
- 帖子
- 241
- 主题
- 12
- 论坛币
- 2292
- 威望
- 2
- EP值
- 520
- MP值
- 0
- 阅读权限
- 50
- 注册时间
- 2012-9-9
- 在线时间
- 281 小时
- 最后登录
- 2014-4-1
|
呜咕。。偶想的特效是这样的:在K值里一个字一个字从右边移动到你设定的地方。。可是偶弄出了移动的特效。。还有遮罩。。可是两个组合起来就没特效了怎么回事呀?
呜咕。。这个是移动特效的代码- from tcaxPy import *
- def tcaxPy_Init():
- global _FD # frame duration, in millisecond
- global _Fs
- global _Blur
- global COLOR
- _FD = 1000 / GetVal(val_FXFPS)
- _Fs = GetVal(val_FontSize)
- _Blur = GetVal(val_Blur)
- COLOR = DivClr(GetVal(val_1C), GetVal(val_2C), _Fs)
- def tcaxPy_Fin():
- pass
- 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
- duration = 10 * _FD
- ts = _start + _elapk # start time, in semi-second
- te = _start + _elapk + _k
- EFT = move(_x + 200, _y , _x, _y)
- ass_main(ASS_BUF, SubL(ts, te), EFT, _txt)
- return (ASS_BUF, TCAS_BUF)
复制代码 呜咕。。这个是遮罩:- from tcaxPy import *
- def tcaxPy_Init():
- global _FD # frame duration, in millisecond
- global _Fs
- global _Blur
- global COLOR
- _FD = 1000 / GetVal(val_FXFPS)
- _Fs = GetVal(val_FontSize)
- _Blur = GetVal(val_Blur)
- COLOR = DivClr(GetVal(val_1C), GetVal(val_2C), _Fs)
- def tcaxPy_Fin():
- pass
- 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
- te = _end - (_n - _j - 1) * time_fac * _FD / 10 + time_gap * _FD / 10
- y1 = _y - _a / 2
- y2 = _y + _a / 2
- for i in range(_Fs):
- x1 = _x - _Fs / 2 + i
- x2 = x1 + 1
- EFT = pos(_x, _y) + clip(x1, y1, x2, y2) + color1(COLOR[i]) + alpha3(255)
- if _Blur > 0:
- EFT += blur(_Blur)
- ass_main(ASS_BUF, SubL(ts + i * _k / _Fs, te, 10), EFT, _txt)
- return (ASS_BUF, TCAS_BUF)
复制代码 啊呜。。这个就是偶将它们组合的可是显示无特效:- from tcaxPy import *
- def tcaxPy_Init():
- global _FD # frame duration, in millisecond
- global _Fs
- global _Blur
- global COLOR
- _FD = 1000 / GetVal(val_FXFPS)
- _Fs = GetVal(val_FontSize)
- _Blur = GetVal(val_Blur)
- COLOR = DivClr(GetVal(val_1C), GetVal(val_2C), _Fs)
- def tcaxPy_Fin():
- pass
- 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
- te = _end - (_n - _j - 1) * time_fac * _FD / 10 + time_gap * _FD / 10
- y1 = _y - _a / 2
- y2 = _y + _a / 2
- for i in range(_Fs):
- x1 = _x - _Fs / 2 + i
- x2 = x1 + 1
- EFT = clip(x1, y1, x2, y2) + color1(COLOR[i]) + alpha3(255) + move(_x + 100, _y , _x, _y)
- if _Blur > 0:
- EFT += blur(_Blur)
- ass_main(ASS_BUF, SubL(ts + i * _k / _Fs, te, 10), EFT, _txt)
- return (ASS_BUF, TCAS_BUF)
复制代码 啊呜。。。为什么呢(T.T)。。还有就是。。TCAX可以使用jitter这个抖动特效吗? |
|