weizhenye / ASS

A JavaScript ASS subtitle format renderer
https://ass.js.org
MIT License
495 stars 75 forks source link

Caption gradually change to black when setting alpha values in PrimaryColour #46

Open RealTake opened 1 month ago

RealTake commented 1 month ago

In the .ass file, I set PrimaryColour to &Hff6eff00 among the [V4+Styles] fields. If the alpha value is given to the caption, the background does not become transparent and gradually turns black.

weizhenye commented 3 weeks ago

Can you provide a ASS file to reproduce it? I don't get your point.

RealTake commented 3 weeks ago

Here is ass file, the caption should be transparent except for the outside

[Script Info]
Title: Default Aegisub file
ScriptType: v4.00+
PlayResX: 1280
PlayResY: 720
WrapStyle: 2

[V4+ Styles]
Format: Name, Fontname, Fontsize, PrimaryColour, SecondaryColour, OutlineColour, BackColour, Bold, Italic, Underline, StrikeOut, ScaleX, ScaleY, Spacing, Angle, BorderStyle, Outline, Shadow, Alignment, MarginL, MarginR, MarginV, Encoding
Style: Default, 맑은고딕, 54, &Hff000000, &H000000FF, &H00000000, &H0.00x000x000x00, 0, 0, 0, 0, 100, 100, 0, 0, 1, 4, 0, 1, 30, 30, 30, 0

[Events]
Format: Layer, Start, End, Style, Name, MarginL, MarginR, MarginV, Effect, Text
Dialogue: 0, 0:00:00.00, 0:00:16.00, Default, , 0, 0, 0, , {\frz-90}{\pos(0, 0)}The ocean floor rises five \nmiles to the shores\n of what people call th\ne Seven Mile Miracle.
Dialogue: 0, 0:00:16.00, 0:00:40.00, Default, , 0, 0, 0, , {\frz90}{\pos(-52.64516,105.27937)}What would it be like to be born on this island to grow up on these shores to witness this water every day?
Dialogue: 0, 0:00:40.00, 0:00:46.00, Default, , 0, 0, 0, , {\frz90}{\pos(-52.64516,105.27937)}You're about to meet someone you think.
Dialogue: 0, 0:01:10.00, 0:01:24.00, Default, , 0, 0, 0, , {\frz90}{\pos(-52.64516,105.27937)}One fall behind and one for sure, three tears from the sun's blood.
Dialogue: 0, 0:01:24.00, 0:01:36.00, Default, , 0, 0, 0, , {\frz90}{\pos(-52.64516,105.27937)}One day we made the perfect thing, learn them all with all I've been thinking.
Dialogue: 0, 0:01:40.00, 0:01:50.00, Default, , 0, 0, 0, , {\frz90}{\pos(-52.64516,105.27937)}One day we made the perfect thing, learn them all with all I've been thinking.
Dialogue: 0, 0:01:50.00, 0:02:04.00, Default, , 0, 0, 0, , {\frz90}{\pos(-52.64516,105.27937)}One day we made the perfect thing, learn them all with all I've been thinking.
Dialogue: 0, 0:02:04.00, 0:02:14.00, Default, , 0, 0, 0, , {\frz90}{\pos(-52.64516,105.27937)}One day we made the perfect thing, learn them all with all I've been thinking.
Dialogue: 0, 0:02:14.00, 0:02:26.00, Default, , 0, 0, 0, , {\frz90}{\pos(-52.64516,105.27937)}One day we made the perfect thing, learn them all with all I've been thinking.
Dialogue: 0, 0:02:26.00, 0:02:36.00, Default, , 0, 0, 0, , {\frz90}{\pos(-52.64516,105.27937)}One day we made the perfect thing, learn them all with all I've been thinking.
Dialogue: 0, 0:02:36.00, 0:02:46.00, Default, , 0, 0, 0, , {\frz90}{\pos(-52.64516,105.27937)}One day we made the perfect thing, learn them all with all I've been thinking.
Dialogue: 0, 0:02:46.00, 0:02:56.00, Default, , 0, 0, 0, , {\frz90}{\pos(-52.64516,105.27937)}One day we made the perfect thing, learn them all with all I've been thinking.