Log in

View Full Version : Aegisub: Set Resolution


jay123210599
16th November 2024, 15:08
I have a bunch of 640x360 subtitles, and I want to use them for 1920x1080 videos. How do I them to that resolution at once using Aegisub?

I'm talking about this, but I want to put it in a batch process or something like that.

https://imgur.com/gjmMJhr

GeoffreyA
16th November 2024, 17:25
I stand to be corrected but think it should work without changing them because the aspect ratio is the same.

jay123210599
16th November 2024, 22:30
I stand to be corrected but think it should work without changing them because the aspect ratio is the same.

I want the subtitles to be different. From this (https://imgur.com/S0Iok5t) to this (https://imgur.com/ZjyLLdP).

Z2697
17th November 2024, 05:37
You don't
You enable scale border and shadow
But dude that thick border is ugly
Up your aesthetics

GeoffreyA
17th November 2024, 06:33
The thick border is terrible. The original looks better. Try increasing it a little till it's just visible and leave it at that. I think you'll be able to do that in the Styling Assistant.

FranceBB
17th November 2024, 08:20
I stand to be corrected but think it should work without changing them because the aspect ratio is the same.

You're exactly right.
Both AssRender() and TextSub() will scale the subtitles accordingly and automatically, so there's no reason to do anything.

@Geoffrey, when it asks you about scaling and changing the resolution to make it match the one of the video, hit cancel.

It's very common to work with low resolution and quality proxies and then encode at high resolution starting from the original master.

For instance, I generally work at 848x480, so all the subtitles, styles, font sizes etc are for that resolution. When that very same subtitle is applied to the original FULL HD source via AssRender() it's automatically scaled and everything works perfectly. The important thing is that the aspect ratio has to be the same, in my case 16:9 so 1.77 for both the proxy and the actual source. Nothing stops you from working with 1.85, 2.35 etc as long as they're the same. Obviously the same applies to 4:3 1.33, so you can't mix and match aspect ratios but you can mix and match resolutions and vsfilter will adjust the subtitles for you automatically.

hellgauss
17th November 2024, 14:41
I want the subtitles to be different. From this (https://imgur.com/S0Iok5t) to this (https://imgur.com/ZjyLLdP).

Add the command

ScaledBorderAndShadow: yes

in the [Script Info] header of the .ass

You can do it with notepad. Keep resolution 640 x 360.

I also prefer the thick subtitles since at full hd are more readable. And actually, if rendered at original resolution 640x360, they appears thicker indeed.

jay123210599
18th November 2024, 18:33
Add the command

ScaledBorderAndShadow: yes

in the [Script Info] header of the .ass

How do I do that to multiple subtitle files at once?

hellgauss
18th November 2024, 19:39
I managed to do that easily with a c++ script. Any other language would be ok.

You can do it via windows bat file, but it is somewhat an hack and a bit slow. For example this .bat accepts 2 arguments: input_file (%1) and output_file (%2). You can call it in a for cycle through your .ass files.

echo off
for /F "tokens=*" %%A in (%1) do (
echo %%A >> %2
if "%%A" == "[Script Info]" (
echo ScaledBorderAndShadow: yes >> %2
echo OK - String found in %1
)
)

The .bat looks for the line "[Script Info]" and add the command after. Note that it will not work if the line is even a little bit different, e.g. if there are space after the "]". I also inserted a check log to the script. Note that you may want to delete previous output %2 before starting the script, since text will be added.