标题: Usage of BigPix [打印本页] 作者: 面麻 时间: 2016-4-8 14:43:55 标题: Usage of BigPix
本帖最后由 面麻 于 2016-4-11 15:15 编辑
Problem: I tried to make pix of a line as a whole, but no words showed when previewing avs script.
Is it the reason that I made wrong with the usage of gloabl variable?
Or the misunderstanding of BigPix structure, especially the InitBigPix() function?
Codes listed below:
from tcaxPy import *
def tcaxPy_Init():
global font
global font_out
global font_size
font_file = GetVal(val_FontFileName)
face_id = GetVal(val_FaceID)
font_size = GetVal(val_FontSize)
spacing = GetVal(val_Spacing)
space_scale = GetVal(val_SpaceScale)
color = DecRGB(GetVal(val_1C))
bord = GetVal(val_Bord)
font = InitFont(font_file, face_id, font_size, spacing, space_scale, color, bord, 0)
the main cause of disappearance of your BigPix is that the pos information is already contained in ALINEPIX, however you specified another offset to it by line 58. just use tcas_main(TCAS_BUF, ALINEPIX, ts, te, 0, 0, 0) will output the right effect you expected.
I had wrote some demos about PIX and BigPix, I think it's a good idea for me to pack them and upload to the forum before my hard disc go bad :)作者: 面麻 时间: 2016-4-8 21:25:05
It's pretty grateful of you to offer me these references.
After learning about basic conception of tcas, it seems that creating a line effect has become more difficult than syllable effects, such as line clip.
Maybe it's because of my lack of knowledge about tcas. (Ignore this //作者: milkyjing 时间: 2016-4-9 00:28:16
面麻 发表于 2016-4-8 21:25
It's pretty grateful of you to offer me these references.
After learning about basic conception of t ...
Well, I do agree with you about the difficulty of tcas, since it exposes more details to the FXer, and the built-in (ease of use) PIX APIs are far to be rich (compared to ASS tags). Another point is that API is harder to use than tags. :)
At the very beginning, I designed the TCAS format just to be a supplement of ASS for handling Pix Effects (Using ASS to output often resulted in huge files, and slow to preview.). But after I finishing the specification of TCAS I found that ASS and TCAS are actually two different major approaches to subtitle effects (Both of them have the full ability of making a complete subtitle effects), one represents vectorial system, and the other for bitmap system. They protogenetically have their own strong and weak aspects. e.g.
Vectorial System is good at resizing, rotation, transformation, etc.
Bitmap System is good at texturing, masking, coloring, etc.