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

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

[完整特效] [SAI]019_[C]OP [复制链接]

Administrator

Shanzhai Pro.

Rank: 7Rank: 7Rank: 7

跳转到指定楼层
楼主
发表于 2011-10-22 18:27:14 |只看该作者 |倒序浏览
預覽:http://pan.baidu.com/s/1hqqY9CC#dir/path=%2FSaiyakuFX_Preview
  1. from tcaxPy import *


  2. def tcaxPy_Init():
  3.     # Tips: initialize your global variables here
  4.     global _FontSize
  5.     global pyFont
  6.     _FontSize = GetVal(val_FontSize)
  7.     pyFont    = InitFont(GetVal(val_FontFileName), GetVal(val_FaceID), GetVal(val_FontSize), GetVal(val_Spacing), GetVal(val_SpaceScale), 0x0000FF, 0, 0)

  8. def tcaxPy_Main(_I, _J, _N, _BT, _ET, _SK, _KT, _X, _Y, _A, _TXT):
  9.     ASS_BUF = []        # used for saving raw TCS FX data

  10. # 格子光圈

  11.     if _I >= 5 :
  12.         for i in range (0,24,2):
  13.             for j in range(10,60,20):
  14.                 a = -5 + j
  15.                 x = 5+ j
  16.                 sb1 = "m " + str(a) + " " +"-5" + " l "+ str(x)+" " +"-5"+" l"+" "+str(x)+" "+"5"+" l"+" "+str(a)+" "+"5"
  17.                 ass_main(ASS_BUF, SubL(_BT+_SK-3,_BT+_SK+_KT+50-j,1),alpha3(20)+alpha1(80)+color1("42FFFF")+bord(2)+blur(4)+color3("00A0FF")+be(8)+pos(_X,_Y)+fad(50,200)+org(_X,_Y)+frz(15*i)+t1(0,(_KT+30)*10,alpha1(40-randint(-10,20))+alpha3(50-randint(-20,10))),"{\\p1}"+sb1)

  18.         for i in range(1,24,2):
  19.             for j in range(0,60,20):
  20.                 a = -5 +j
  21.                 x = 5+j
  22.                 sb2 = "m " + str(a) + " " +"-5" + " l "+ str(x)+" " +"-5"+" l"+" "+str(x)+" "+"5"+" l"+" "+str(a)+" "+"5"
  23.                 ass_main(ASS_BUF, SubL(_BT+_SK-3,_BT+_SK+_KT+50-j,1),alpha3(20)+alpha1(80)+color1("42FFFF")+bord(2)+blur(4)+color3("00A0FF")+be(8)+pos(_X,_Y)+fad(50,200)+org(_X,_Y)+frz(15*i)+t1(0,(_KT+30)*10,alpha1(40-randint(-10,20))+alpha3(50-randint(-20,10))),"{\\p1}"+sb2)
  24.             


  25.     ass_main(ASS_BUF, SubL(_BT-40,_BT+_SK-3,20),pos(_X,_Y)+fad(100,0),"{\\b1}"+_TXT)
  26.     ass_main(ASS_BUF, SubL(_BT-40,_BT+_SK-3,15),pos(_X+2,_Y+2)+alpha1(20)+fad(100,0)+color1("000000")+blur(1.5),"{\\b1}"+_TXT)

  27. #金属字

  28.     ass_main(ASS_BUF, SubL(_BT+_SK-5,_BT+_SK+_KT,49),pos(_X+1,_Y+1)+alpha1(120)+t2(0,50,0.6,fscx(140)+fscy(140))+t2((_KT+5)*10-80,(_KT+5)*10,0.4,fscx(100)+fscy(100)+bord(0)+blur(0)) + color1("000000") + blur(1) , "{\\b1}"+_TXT)
  29.     ass_main(ASS_BUF, SubL(_BT+_SK-5,_BT+_SK+_KT,50),pos(_X,_Y)+alpha1(0)+t2(0,50,0.6,fscx(140)+fscy(140))+t2((_KT+5)*10-80,(_KT+5)*10,0.4,fscx(100)+fscy(100)+bord(0)+blur(0)) + color1("FFFFFF"), "{\\b1}"+_TXT)
  30.     ass_main(ASS_BUF, SubL(_BT+_SK-5,_BT+_SK+_KT,51),pos(_X+2,_Y+2)+alpha1(35)+t2(0,50,0.6,fscx(140)+fscy(140))+t2((_KT+5)*10-80,(_KT+5)*10,0.4,fscx(100)+fscy(100)+bord(0)+blur(0)) + color1("1B1B1B")+ blur(1) , "{\\b1}"+_TXT)

  31.     ass_main(ASS_BUF, SubL(_BT+_SK+_KT,_ET,20),pos(_X,_Y)+fad(0,100),"{\\b1}"+_TXT)
  32.     ass_main(ASS_BUF, SubL(_BT+_SK+_KT,_ET,15),pos(_X+2,_Y+2)+alpha1(20)+fad(0,100)+color1("000000")+blur(1.5),"{\\b1}"+_TXT)

  33. #马赛克

  34.     for i in range(int(_A/10)):
  35.         for j in range(int(40/10)):
  36.             X = randint(0,5)
  37.             if X == 0 :
  38.                 ass_main(ASS_BUF, SubL(_BT-30+randint(-20,20),_BT+randint(-20,20),20),an(7)+pos(_X-_A/2+i*10+randint(-3,3),_Y-20+j*10+randint(-3,3))+fad(50,50)+alpha(0)+shad(0),"{\p1}m 0 0 l 15 0 15 15 0 15{\p0}")
  39.             elif X == 1 :
  40.                 ass_main(ASS_BUF, SubL(_BT-30+randint(-20,20),_BT+randint(-20,20),20),an(7)+pos(_X-_A/2+i*10+randint(-3,3),_Y-20+j*10+randint(-3,3))+fad(50,50)+alpha(150)+shad(0),"{\p1}m 0 0 l 15 0 15 15 0 15{\p0}")
  41.             else :
  42.                 ass_main(ASS_BUF, SubL(_BT-30+randint(-20,20),_BT+randint(-20,20),20),an(7)+pos(_X-_A/2+i*10+randint(-3,3),_Y-20+j*10+randint(-3,3))+fad(50,50)+alpha(255)+shad(0),"{\p1}m 0 0 l 15 0 15 15 0 15{\p0}")        


  43.     return (ASS_BUF,None)


  44. def tcaxPy_Fin():
  45.     # Tips: finalize your global variables here
  46.     FinFont(pyFont)
复制代码
1

查看全部评分

您需要登录后才可以回帖 登录 | 新人加入

GitHub|TCAX 主页

GMT+8, 2024-12-4 16:31

Powered by Discuz! X2

© 2001-2011 Comsenz Inc.

回顶部
RealH