View Single Post
Old 10th June 2018, 09:23   #5  |  Link
Yanak
Registered User
 
Join Date: Oct 2011
Posts: 275
Just tested this quickly :

Code:
LoadPlugin("H:\avs\DSS2mod\DSS2.dll")
Loadplugin("H:\VSFilterMod.dll")

DSS2("H:\test.mkv")

Subtitle("0", first_frame=0, last_frame=1,\
font="Pacific Again", font_filename="H:\Pacific Again.ttf", \
text_color=$FF000000, halo_color=$FF000000)

TextSubMod("H:\testsub.ass")
fake subtitle applied on first frame with transparent colors for text and halo, then using vsfiltermod (version r5 i found in a link not long ago in this forum ).

Probably only adding a space for the text will be enough and then no need for the colors part:
Code:
Subtitle(" ", first_frame=0, last_frame=1, font="Pacific Again", font_filename="H:\Pacific Again.ttf")
keeping first and last frame option to not slowdown the thing by doing this on the first frame only, if it have any significant speed impact to start with.

In the .ass file there is this, only thing i done is a manual editing to test the non installed font, was Arial before "Pacific Again" :
Quote:
[Script Info]
; Script generated by FFmpeg/Lavc57.107.100
ScriptType: v4.00+
PlayResX: 384
PlayResY: 288

[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,Pacific Again,16,&Hffffff,&Hffffff,&H0,&H0,0,0,0,0,100,100,0,0,1,1,0,2,10,10,10,0

[Events]
Format: Layer, Start, End, Style, Name, MarginL, MarginR, MarginV, Effect, Text
etc...
Seems to work, the script launched in avspmod or MPC-HC displays correctly the non-installed font on subtitles. ( also tried with the font "Pacific Again.ttf" loaded from a totally different path, on another drive just to be sure )

Don't know if i am missing something or doing something wrong or if i am lucky but seems to work ¯\_(ツ)_/¯

Last edited by Yanak; 10th June 2018 at 10:24.
Yanak is offline   Reply With Quote