Skip to content

Akatmks/Akatsumekusa-Aegisub-Scripts

Repository files navigation


Table of Contents


DependencyControl
https://raw.githubusercontent.com/Akatmks/Akatsumekusa-Aegisub-Scripts/master/DependencyControl.json
Motion Tracking
aae-export
Typesetting Aid
aka.BackupSection
aka.BoundingBox
aka.Cycles
aka.dupe-and-not-comment
farn huah
NN.farnhuah
Aegisub VapourSynth
tkinter_alternatives

Modules
aka.actor
aka.config
aka.config2
aka.singlesimple
aka.optimising
aka.outcome
aka.threads
aka.unicode
aka.unsemantic
Thirdparty Modules
effil
request


aae-export

AAE Export Function Preview

AAE Export is a Blender add-on that exports tracks and plane tracks into Aegisub-Motion and Aegisub-Perspective-Motion compatible AAE data.

– Download (Windows)
– Download (Linux x86_64)
– Download (Linux aarch64)
– Download (Mac)
– Tutorial 1: Install AAE Export
– Tutorial 2: Basic motion tracking
– Tutorial 3: Introducing smoothing feature
– Tutorial 4: Tracking perspective

Thanks to

– arch1t3cht for helping in improving algorithms and for developing the original AAE Export (Power Pin) script.
– bucket3432, Noroino Hanako for helping with AAE Export's function.
– bucket3432, petzku and others for helping with UI/UX design.
– Martin Herkt for developing the original AAE Export script in 2012.

License information
aae-export was originally released by Martin Herkt under ISC License. Since then, aae-export has been completely rewritten, with every original line replaced. It is now released under a single MIT License.
aae-export-install-dependencies is a helper tool with its binary included in Linux x86_64 and Mac version of aae-export. The tool is released under MIT License, using Qt libraries under LGPLv3.
aae-export-base122 is a helper tool with its binary included in Linux x86_64 and Mac version of aae-export. It is a wrapper of Kevin Albertson's libbase122 library, and is released under Apache License.

aka.BackupSection & aka.dupe-and-not-comment

aka.BackupSection and aka.dupe-and-not-comment are similar in function to garret.dupe-and-comment but arrange the new lines in different ways.

To backup using aka.BackupSection, select the lines to backup and click „Backup“. To start from a previous backup, select the previously commented lines and click „Backup“.

Comparing the three scripts,
when applied to the following selection:
image

aka.BackupSection:
image

garret.dupe-and-comment:
image

aka.dupe-and-not-comment:
image

aka.BoundingBox

aka.BoundingBox adds either SubInspector-style or text_extents-style bounding box as rect clip to selected lines.

SubInspector:
image

aegisub.text_extents:
image

aka.Cycles

aka.Cycles is largely the same as ua.Cycles but with a configuration editor inside Aegisub.

NN.farnhuah

NN.farnhuah is an Aegisub frontend for zhconvert.

To use NN.farnhuah, select the line for farnhuah and click „farn huah“. To switch between chs and cht subtitles, click „chie huann chs her cht“.
On first launch, NN.farnhuah will show a configuration window. Create your own configuration from zhconvert's documentation, or click „Apply Preset“ to use the default config from SweetSub.

tkinter_alternatives

tkinter_alternatives.py is a fix for Aegisub VapourSynth Default Video Script if your Python installation does not come with Tkinter.

Download the file and put it in automation/vapoursynth in your Aegisub install location.

Open Aegisub, open „View > Options“ and select „VapourSynth“. In „Default Video Script“, find the import aegisub_vs line:

import aegisub_vs as a

Add the following line below import aegisub_vs line:

import tkinter_alternatives as ask

Find the line to generate keyframe:

__aegi_keyframes = a.get_keyframes(filename, clip, __aegi_keyframes, generate=a.GenKeyframesMode.ASK)

Replace the line with:

__aegi_keyframes = a.get_keyframes(filename, clip, __aegi_keyframes, generate=a.GenKeyframesMode.ASK, ask_callback=ask.callback)

aka.actor

aka.actor is a flag system visible to the user.
For example, when you backup a line with aka.BackupSection, a backup flag will be added to the commented line.

Check whether a flag exists and the number of times it exists on line:

aactor.flag(line, "backup")

Set flag on line:

aactor.setFlag(line, "backup")

Other functions include:

aactor.flag(line, flag)
aactor.setFlag(line, flag)
aactor.clearFlag(line, flag)
aactor.toggleFlag(line, flag)
aactor.onemoreFlag(line, flag)
aactor.onelessFlag(line, flag)

aactor.field is a aka.singlesimple config specifying the field to place the flags. It has three possible values, actor, effect and style. It is synced across all scripts using aka.actor.

aka.config & aka.config2

aka.config is a config module that features a builtin JSON editor with pretty JSON. aka.config2 provides the base JSON and file system functions while aka.config implements three readytouse config functions with GUI.

Readytouse config functions include:

aconfig.read_and_validate_config_if_empty_then_default_or_else_edit_and_save(self, config, config_supp, validation_func)
aconfig.read_and_validate_config_or_else_edit_and_save(self, config, config_supp, validation_func)
aconfig.read_edit_validate_and_save_config(self, config, config_supp, validation_func)

Detailed tutorial is available at docs/Using aka.config and aka.config2.md.

aka.singlesimple

aka.singlesimple is a config module. It stores one enum per config and the enum is synced* across all scrips requesting the same config.

-- Create a config
config = ss.make_config("aka.Testing", possible_values, default_value)
-- Get the current value
config:value()
-- Set the value
config:setValue(value)

*: Loosely.

Detailed tutorial is available at docs/Using aka.singlesimple.md.

aka.optimising

aka.optimising introduces a timing function for debugging.

Set aka.optimising.json under DependencyControl's configDir to { true }. Use optimising.start() to start the timer. Use optimising.lap(lap_name) to print time to aegisub.debug.out.

aka.outcome

aka.outcome introduces Result and Option similar to Rust's std::result::Result and std::option::Option. It is based on mtdowling's Outcome and is used by aka.config, aka.config and many other Akatsumkusa's scripts.

Detailed introduction is available at docs/Using aka.outcome.md.

License Information
Outcome is originally released by Michael Dowling under MIT License.
It is modified with exisiting functions changed and new functions added by Akatsumekusa.

aka.threads

aka.threads is a synced aka.singlesimple config storing the number of threads used when multithreading.

aka.threads defaults to the number of logical processors on the system. Any multithreading script could get the number of threads to use from this config and also change this config at user's request.

threads = require("aka.threads")
-- Get the number of threads to use
threads.threads()
-- Change this config for all scripts
threads.setThreads(8)

aka.unicode

aka.unicode extends aegisub.unicode with a unicode.char(codepoint) function to turn codepoints back to characters.

aka.unsemantic

aka.unsemantic is a version compare module that supports basic version format with two or three positive numbers separated by periods.

V = require("aka.unsemantic").V
assert(V"1.1.2" > V"1.0.24")

Two-number version is treated as three-number version with a patch number of `-1``.

assert(V"2.1.0" > V"2.1")

effil

effil is a multithreading library for Lua.

Add aka.effil to DependencyControl's required modules. View the documents at the original repository.

It is recommended to use the synced module aka.threads for the number of threads to use when multithreading.

License Information
effil is copyrighted to Mikhail Kupriyanov and Ilia Udalov and is licensed under MIT License.

request

LuaJIT-Request is a request module for LuaJIT based on libcurl.

Add aka.request to DependencyControl's required modules. View the documents at the original repository.

License Information
LuaJIT-Request is copyrighted to Lucien Greathouse and is licensed under zlib License. It is adapted to Aegisub environment with minimum modifications.

About

Aegisub automation scripts

Resources

License

MIT, Zlib licenses found

Licenses found

MIT
LICENSE.MIT
Zlib
LICENSE.Zlib

Stars

Watchers

Forks