aegisub-scripts/README.md

128 lines
4.5 KiB
Markdown
Raw Normal View History

2022-08-05 13:19:10 +00:00
# garret's aegisub scripts
2021-04-05 15:03:24 +00:00
Aegisub automation scripts I've written.
2022-08-05 13:19:10 +00:00
Nothing cool and exciting here, just little utilities that make my life easier.
2021-04-05 15:03:24 +00:00
2022-10-13 13:17:38 +00:00
I write and use these on [arch1t3cht's fork](https://github.com/arch1t3cht/Aegisub/) on Linux (previously aegisub mainline), but they should work perfectly fine wherever, I don't think there's anything OS or fork-specific in there.
2021-07-10 16:11:31 +00:00
2022-08-05 13:19:10 +00:00
One day I'll get round to sorting out a DependencyControl feed. If you're reading this, that day has not yet come.
2021-12-22 20:12:24 +00:00
2021-04-05 15:03:24 +00:00
----
2022-08-05 13:19:10 +00:00
## Dupe and Comment
2021-04-05 15:03:24 +00:00
2022-08-05 13:19:10 +00:00
Duplicates a line and comments out the original.
2021-04-05 15:03:24 +00:00
2022-08-05 13:19:10 +00:00
This lets you:
2021-04-05 15:03:24 +00:00
2022-08-05 13:19:10 +00:00
- quickly create different versions of a line
- see the differences at a glance
- easily revert to the original, even if the undo history is gone
2021-04-05 15:03:24 +00:00
2022-08-05 13:19:10 +00:00
Probably the script I use the most.
2022-08-05 13:19:10 +00:00
| Key | Function | Rationale |
| --- | -------- | --------- |
| D | `Dupe and Comment/Do` | Easy access. "D" for duplicate. |
| Shift-D | `Dupe and Comment/Undo` | Shift-D, like Shift-Delete for deleting files. |
| Ctrl-D | `edit/line/duplicate` | Still want to dupe without commenting occasionally. |
2022-08-05 13:19:10 +00:00
These hotkeys let me have everything related to duplication on one key.
2021-08-09 12:25:44 +00:00
2022-08-05 13:19:10 +00:00
## Syllable Splitter
2021-04-05 15:03:24 +00:00
2022-08-05 13:19:10 +00:00
Splits romaji into karaoke syls. For the lazy k-timer.
2021-04-05 15:03:24 +00:00
2022-08-05 13:19:10 +00:00
Tries to use the lengths that aegi would produce if you did it manually.
Does an alright enough job most of the time, but is ignorant of whitespace.
2021-04-05 15:03:24 +00:00
2022-08-05 13:19:10 +00:00
Not that it really matters, you'll be retiming it anyway.
2021-08-09 12:25:44 +00:00
2022-08-05 13:19:10 +00:00
## K-Timing -> Alpha Timing
2021-08-09 12:25:44 +00:00
2022-08-05 13:19:10 +00:00
Makes doing alpha timing significantly easier by getting rid of the part where you do alpha timing.
2021-04-05 15:03:24 +00:00
2022-08-05 13:19:10 +00:00
Instead, K-Time the line, and run the script. The highlighting of the syls will become the appearance of the syls.
2021-04-25 01:30:01 +00:00
2022-08-05 13:19:10 +00:00
The original line will be commented out, so you can go back and change it easily.
2021-04-25 01:30:01 +00:00
2022-08-05 13:19:10 +00:00
Originally created to convert stuff that should've been alpha timed in the first place, but that used a hack with `\ko` instead.
2021-04-25 01:30:01 +00:00
2022-08-05 13:19:10 +00:00
## DependencyControl Global Config
2021-07-10 16:11:31 +00:00
2022-08-05 13:19:10 +00:00
There's a line in the DependencyControl README that goes:
2021-04-05 15:03:24 +00:00
2022-08-05 13:19:10 +00:00
> DependencyControl stores its configuration as a JSON file in the _config_ subdirectory of your Aegisub folder (`l0.DependencyControl.json`). Currently you'll have to edit this file manually, in the future there will be a management macro.
That line's been there for about 7 years now.
I wanted to change some settings without wading through the JSON and typing in the right stuff myself, so I wrote this.
## Select Comments
2021-04-05 15:03:24 +00:00
2022-08-05 13:19:10 +00:00
Tiny utility script.
Easier than `Subtitle > Select Lines` etc
2021-04-05 15:03:24 +00:00
2022-08-05 13:19:10 +00:00
----
Updating this README has made me realise that I only really have 2 or 3 actually useful scripts. Here are the bad and/or useless ones.
These scripts should be considered abandoned for the foreseeable future.
2021-04-05 15:03:24 +00:00
2022-08-05 13:19:10 +00:00
They should all work decently enough, it's just that what they do isn't useful very often, or is done better by something else.
2021-04-05 15:03:24 +00:00
2022-08-05 13:19:10 +00:00
## A-B
2021-06-13 14:44:57 +00:00
2022-08-05 13:19:10 +00:00
Makes checking pre-timing possible by putting some text in the lines.
(the actor name, and `a` or `b`, hence the name)
2021-08-09 12:25:44 +00:00
2022-08-05 13:19:10 +00:00
ignores lines with text in them, prepends to lines with just tags in them
2021-12-23 13:04:43 +00:00
2022-08-05 13:19:10 +00:00
## Audio Clipper
2021-12-23 13:04:43 +00:00
2022-08-05 13:19:10 +00:00
Old and bad, but maybe still useful sometimes.
2021-12-23 13:04:43 +00:00
2022-08-05 13:19:10 +00:00
**Needs [FFMPEG](https://ffmpeg.org) in your PATH.**
2021-12-23 13:04:43 +00:00
2022-08-05 13:19:10 +00:00
Makes audio clips of all the selected lines.
Output is either stream-copied, or encoded to a format of your choice.
2021-12-23 13:04:43 +00:00
2022-08-05 13:19:10 +00:00
By default, makes a folder called `audioclipper_output` and dumps all the files in there.
The filename is the index of the line in your selection.
2021-12-23 13:04:43 +00:00
2022-08-05 13:19:10 +00:00
**Done better by**: [Petzku's `Encode Clip`](https://github.com/petzku/Aegisub-Scripts/blob/master/macros/petzku.EncodeClip.lua), Aegisub's `Create audio clip` button.
2021-07-10 15:24:32 +00:00
2022-08-05 13:19:10 +00:00
## Chapter Generator
2021-07-10 15:24:32 +00:00
2022-08-05 13:19:10 +00:00
Makes XML chapters for Matroska.
2021-07-10 15:24:32 +00:00
2022-08-05 13:19:10 +00:00
Incomplete clone of the chapter generator in [Significance](https://github.com/unanimated/luaegisub/blob/master/ua.Significance.lua).
No proper XML handling here, just mashing strings together and hoping for the best.
2021-12-22 20:12:24 +00:00
2022-08-05 13:19:10 +00:00
Makes lines with the effect `[Cc]hapter`, `[Cc]hptr` or `[Cc]hap` into chapters.
2021-12-22 20:12:24 +00:00
2022-08-05 13:19:10 +00:00
Start time is the timestamp, line text is the chapter name.
Language is currently hardcoded to English.
2021-12-22 20:12:24 +00:00
2022-08-05 13:19:10 +00:00
**Done better by**: `Significance`, SubKt.
2021-08-21 12:48:00 +00:00
2022-08-05 13:19:10 +00:00
## Restyler
2021-08-21 12:48:00 +00:00
2022-08-05 13:19:10 +00:00
previously `become-fansubber.lua`
2021-08-21 12:48:00 +00:00
2022-08-05 13:19:10 +00:00
For dealing with CR scripts.
Changes style of selected lines to `Default` and copies italic+alignment values from the script's styles to inline tags.
Can't help if the source script isn't sanely styled.
2021-08-21 12:48:00 +00:00
**cannot handle inline tags!**
2022-08-05 13:19:10 +00:00
## Scenebleed Detector
2021-07-06 19:45:18 +00:00
Finds scenebleeds in the selected lines, and marks them with an effect (`bleed`).
2022-08-05 13:19:10 +00:00
Currently has a hardcoded threshold of 500ms, as my brain is too small to figure out how to do a config file.
2021-08-09 12:25:44 +00:00
**Done better by**: probably some UA script