Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. |
9th May 2007, 15:31 | #1 | Link |
Registered User
Join Date: Apr 2004
Posts: 126
|
Format of .style file? (VSFilter)
I'm u sing VisualSubSync which seems to use a custom vsfilter, and apparently I must create a ".style" file to change the look of subtitles. But it has proven almost impossible to find out what such a style file is made up of (and don't say search place, that doesn't help)
So anybody know what to add in such a file? |
9th May 2007, 22:59 | #2 | Link |
Registered User
Join Date: Oct 2001
Posts: 1,125
|
Sorry, but using the search would have led you to this thread (it did for me): http://forum.doom9.org/showthread.php?t=98681
In the subresync edit window, make your choices, apply them & subresync will write the style file for you. Steve |
10th May 2007, 03:42 | #3 | Link | |
Registered User
Join Date: Apr 2004
Posts: 126
|
Quote:
I have no file called subresync. |
|
10th May 2007, 14:42 | #4 | Link |
Registered User
Join Date: Sep 2006
Location: Brazil
Posts: 23
|
Here is an example of the subrip style file:
Code:
ScriptType: v4.00+ PlayResX: 720 PlayResY: 480 [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,HelveticaRounded LT Bold,28,&H00E6E6E6,&H000CEEF1,&H00000000,&H00000000,0,0,0,0,100,100,0,0,1,2,0,2,72,72,48,0 The subrip style format is actually a subset of the Substation Alpha subtitle format, and comes with a lot of parameters such as font type, size, color, attributes, safe area for subtitles, etc. To use this, write down the code above changing the parameters you want to a text file and use the same name as the original srt plus the ".style" extension at the end of the file. Example: spider.srt spider.srt.style If you have the VobSub 2.23 pack version, you can also create the style file using subresync. Just Right click on the SRT file and choose "Edit with Subresync". Select the apropriate FPS for the SRT file and a window pops with the subtitles. Just doubleclick on any of the subtitles and the Subtitle Style Editor pops. Make all the changes you want and press apply. Then all you have to do is save the subtitle (with another name if you want to keep the original as backup), and voilá! The new SRT file comes with the style file. hope it helps |
10th May 2007, 23:15 | #7 | Link | ||
Registered User
Join Date: Apr 2004
Posts: 126
|
Quote:
Quote:
If you had read my message you'd see i said vss uses a custom vsfilter. I have not, and don't plan to install anything. |
||
24th September 2015, 10:29 | #8 | Link |
PgcEdit daemon
Join Date: Jul 2003
Posts: 7,469
|
Sorry to resurrect this old thread, but I wonder if it is possible to overwrite the default style with a custom style, rather than having to create a style file for each SRT. Perhaps it is sufficient to copy a style file somewhere?
VSFilterMod and XY-VSFilter have introduced support for UTF character encoding, but I don't know the value to use in the last field of the style file. Someone knows the values for UTF-8 and UTF-16? (It is not possible to use Subresync to define them.) Also, I wonder what is the usage of these two parameters: PlayResX: 720 PlayResY: 480 Apparently, they define the resolution of the video. But why is it necessary to specify them? The player knows the resolution anyway. Thanks!
__________________
r0lZ PgcEdit homepage (hosted by VideoHelp) BD3D2MK3D A tool to convert 3D blu-rays to SBS, T&B or FS MKV |
24th September 2015, 11:39 | #9 | Link | ||
Registered User
Join Date: Dec 2002
Posts: 5,565
|
Quote:
Quote:
If in doubt I'd simply do what Aegisub does: create UTF-8 with BOM and set encoding according to subtitle language (see drop-down list in Aegisub). The player, but not necessarily the subtitle editor. Or maybe you mux the script into videos of different resolutions and want the subtitle positioning to be preserved. I wouldn't think too hard about the sense behind ASS "specs". Just set them to video resolution and move on. |
||
24th September 2015, 12:35 | #10 | Link | |
Registered User
Join Date: Jul 2015
Posts: 708
|
Quote:
The same can be found contenery ASS for multi-languages. The players can't read.:!: Encoding. This specifies the font character set or encoding and on multi-lingual Windows installations it provides access to characters used in multiple than one languages. It is usually 0 (zero) for English (Western, ANSI) Windows. It is dead function. What's so strange about that? We are using, for ex. editor Sony Vegas. There, each layer has a specific resolution size in the preview that you can change. If you change, fonts will be stretched, smaller or larger. Last edited by Jamaika; 24th September 2015 at 13:00. |
|
24th September 2015, 13:45 | #11 | Link |
PgcEdit daemon
Join Date: Jul 2003
Posts: 7,469
|
Thanks for the replies. I guess I haven't explained what I need correctly. I don't use ASS files. Only SRT files. (I know, that's stupid, but 99.99% of the time, you download a SRT file. I have never seen an ASS file in my life!) Anyway, my question about the encoding concerns the SRT file, and I don't know what is the "script" you are referring to. I forgot also to explain that I use VSFilter as an avisynth plugin. Perhaps that matters. My native language is French, and therefore most of the time there are accented characters in the SRT files. If I use a text editor to convert the SRT to ANSI, there is no problem and the file is rendered properly (with TextSub()), without any need for a style file. But if I leave it in UTF-8 format, TextSub() cannot render properly the accented characters. Obviously, by default, TextSub doesn't work as expected with UTF-8 SRT files.
I know what encoding means. But afaik, UTF-8 is a (relatively recent) encoding that can handle much more glyphes than what the "classic" encoding (or codepage) were able to do, because it encodes the non-standard characters on 2 bytes instead of 1, and the limit of a maximum of 256 characters (including the control chars) doesn't apply any more. And therefore there is normally no need to specify the language (or codepage). (UTF-16 can handle even more glyphes but it should not be necessary for French characters.) Am I right? So, I reformulate my question. How can I obtain the correct rendering of the French accented characters in an UTF-8 file with VSFilterMod/XY's TextSub() avisynth function? Do I need to create a style file, and if it's the case, what should I specify? Note that my UTF-8 SRT files do not have the BOM characters. Could it be the reason? Thanks for the precision about the PlayRes parameters. It's what I suspected.
__________________
r0lZ PgcEdit homepage (hosted by VideoHelp) BD3D2MK3D A tool to convert 3D blu-rays to SBS, T&B or FS MKV |
24th September 2015, 14:08 | #12 | Link |
Registered User
Join Date: Sep 2006
Location: Brazil
Posts: 23
|
Encoding has nothing to do with style. You only use the style file for SRT content in order to choose font, position, size, etc.
I believe that if you really need to use UTF-8 for SRT files, the applications that load the SRT should be able to support that. Edit: Oh, and forgot to mention: not all applications that support SRT files also support the SRT.Style files as well. When you add the complexity of encoding the files in an unusual cope page such as UTF-8, you narrow further the list of possible solutions that could work. Last edited by MBoufleur; 24th September 2015 at 14:15. |
24th September 2015, 14:10 | #13 | Link |
PgcEdit daemon
Join Date: Jul 2003
Posts: 7,469
|
OK, problem solved. Apparently, VSFilter is unable to recognise the UTF-8 file when it has not the BOM. IMO, it's a little bug, because there are other methods to recognise an UTF-8 file and the BOM is never mandatory. Most programs do not need the BOM to handle the UTF-8 format correctly. And it should not be the responsibility of the user to convert its UTS-8 SRT file w/o BOM to UTF-8 with BOM. Most users do not know that it's necessary and do not know how to do that conversion. (I have had to use an Hex editor!)
But the solution exists. At least, I understand now why my previous attempts did not work as expected. Thanks for the BOM pointer, guys!
__________________
r0lZ PgcEdit homepage (hosted by VideoHelp) BD3D2MK3D A tool to convert 3D blu-rays to SBS, T&B or FS MKV |
24th September 2015, 14:14 | #14 | Link | |
PgcEdit daemon
Join Date: Jul 2003
Posts: 7,469
|
Quote:
The application is VSFilter itself. It doesn't support UTF-8 well, because it requires the presence of the BOM. Pity, but as I wrote in my previous post, the solution is to add the BOM manually.
__________________
r0lZ PgcEdit homepage (hosted by VideoHelp) BD3D2MK3D A tool to convert 3D blu-rays to SBS, T&B or FS MKV |
|
|
|