将 B 站弹幕转换为 ASS 弹幕
Project description
biliass
biliass,只是 Danmaku2ASS 的 bilili 与 yutto 适配版
原版:https://github.com/m13253/danmaku2ass
仅支持 bilibili 弹幕,支持 XML 弹幕和 Protobuf 弹幕
Install
pip install biliass
Usage
# XML 弹幕
biliass danmaku.xml -s 1920x1080 -o danmaku.ass
# protobuf 弹幕
biliass danmaku.pb -s 1920x1080 -f protobuf -o danmaku.ass
from biliass import convert_to_ass
# xml
convert_to_ass(
xml_text_or_bytes,
width,
height,
input_format="xml",
reserve_blank=0,
font_face="sans-serif",
font_size=width / 40,
text_opacity=0.8,
duration_marquee=15.0,
duration_still=10.0,
comment_filter=None,
is_reduce_comments=False,
)
# protobuf
convert_to_ass(
protobuf_bytes, # only bytes
width,
height,
input_format="protobuf",
reserve_blank=0,
font_face="sans-serif",
font_size=width / 40,
text_opacity=0.8,
duration_marquee=15.0,
duration_still=10.0,
comment_filter=None,
is_reduce_comments=False,
)
TODO
- 导出 bilibili 网页上的弹幕设置,并导入到 biliass
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
File details
Details for the file biliass-2.0.0.tar.gz
.
File metadata
- Download URL: biliass-2.0.0.tar.gz
- Upload date:
- Size: 29.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0540aed257aa4f62cb4e78e5e3c45b5bd3a6c4350595e2ce56265c879747e821 |
|
MD5 | 5680ca2b5978fcaa7a088306a59ddeb2 |
|
BLAKE2b-256 | 0bd50e713c6597ae2d30ff28d9d0d048476fd2d73ab25dcae8bb5a9ef29b1190 |
File details
Details for the file biliass-2.0.0-cp39-abi3-win_amd64.whl
.
File metadata
- Download URL: biliass-2.0.0-cp39-abi3-win_amd64.whl
- Upload date:
- Size: 886.0 kB
- Tags: CPython 3.9+, Windows x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b4ec11a5df4bab9447b189c4a4be0c2048bd0dbb455b3171c248cecec864f7f6 |
|
MD5 | 26e43ec19943be732b5d9a92260374de |
|
BLAKE2b-256 | 2a9952385bde52aa5a8bdf16a5f136c7c53839ca0962dbd8a991c6db5edd56c0 |
File details
Details for the file biliass-2.0.0-cp39-abi3-win32.whl
.
File metadata
- Download URL: biliass-2.0.0-cp39-abi3-win32.whl
- Upload date:
- Size: 813.1 kB
- Tags: CPython 3.9+, Windows x86
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 98461120fe4a813a7a93ad92a9ad430f97bca417ef47cd56394ed55e580c6f10 |
|
MD5 | c7124c9fdc487f6bc18050724e2318bd |
|
BLAKE2b-256 | 797e3bd095a37895cc6797f0325c08cf8f213562cbe227ce5f452c3abbb65095 |
File details
Details for the file biliass-2.0.0-cp39-abi3-musllinux_1_2_x86_64.whl
.
File metadata
- Download URL: biliass-2.0.0-cp39-abi3-musllinux_1_2_x86_64.whl
- Upload date:
- Size: 1.3 MB
- Tags: CPython 3.9+, musllinux: musl 1.2+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 257f31eddeae9ceebd379dac848810272a918e39396be99341961d14b977d0b4 |
|
MD5 | 8a688c2a0c987d702257960fa237f9ef |
|
BLAKE2b-256 | 9e01c56c820df8db5ebbf4139ee8655c2f2685b2f621eb5f5c43839606c34c76 |
File details
Details for the file biliass-2.0.0-cp39-abi3-musllinux_1_2_i686.whl
.
File metadata
- Download URL: biliass-2.0.0-cp39-abi3-musllinux_1_2_i686.whl
- Upload date:
- Size: 1.3 MB
- Tags: CPython 3.9+, musllinux: musl 1.2+ i686
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 62ee2e8974668b0640794795073685fefd1ad97852756e5d1ab450d1464dd03c |
|
MD5 | f57b6dc1851b5143c77a46df1188c4d5 |
|
BLAKE2b-256 | 9267a97aed1176171b3336b3102ac4593da45c9044a31fda3bfe391aa21d99a7 |
File details
Details for the file biliass-2.0.0-cp39-abi3-musllinux_1_2_armv7l.whl
.
File metadata
- Download URL: biliass-2.0.0-cp39-abi3-musllinux_1_2_armv7l.whl
- Upload date:
- Size: 1.3 MB
- Tags: CPython 3.9+, musllinux: musl 1.2+ ARMv7l
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 566a8abcd3b79dfc9f9904bec171f593b3e5a73d0eaaaf41e5526a56fe1f75d4 |
|
MD5 | 7b77a35ca17fc5657eaf87198cee4907 |
|
BLAKE2b-256 | 26859a65029a74e1e9a12ff998d9f68e511746c181573261e1c178ffab1d03d3 |
File details
Details for the file biliass-2.0.0-cp39-abi3-musllinux_1_2_aarch64.whl
.
File metadata
- Download URL: biliass-2.0.0-cp39-abi3-musllinux_1_2_aarch64.whl
- Upload date:
- Size: 1.3 MB
- Tags: CPython 3.9+, musllinux: musl 1.2+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 649952252ab753694b8e550df9c42c19b721f4a57770659d907e829547eb9df1 |
|
MD5 | 10995394a1b161674f68b0488862d981 |
|
BLAKE2b-256 | 778f976def7ce6ded8b07f6a8d7da67709a994906c86c2c1c0ee5527000c1bf3 |
File details
Details for the file biliass-2.0.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
.
File metadata
- Download URL: biliass-2.0.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 1.2 MB
- Tags: CPython 3.9+, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | af3ca37155d0652e32cd4d45bb33b7d835adedbfdd5b561d6dad71fb42c6d1b8 |
|
MD5 | fc6cdf3a561c3bc55ac15a76933bf579 |
|
BLAKE2b-256 | 6f47fcdbd2cdfe2f077cb280e0db71797e86757f3dc7e71d3e06d5d8cb797de0 |
File details
Details for the file biliass-2.0.0-cp39-abi3-manylinux_2_17_s390x.manylinux2014_s390x.whl
.
File metadata
- Download URL: biliass-2.0.0-cp39-abi3-manylinux_2_17_s390x.manylinux2014_s390x.whl
- Upload date:
- Size: 1.3 MB
- Tags: CPython 3.9+, manylinux: glibc 2.17+ s390x
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b5d230c066a19d687d7ce5b422201cd095b3c4eeffff20cb3d67237d2b2e63d6 |
|
MD5 | 597adacacc254e2c25aa098a6a882264 |
|
BLAKE2b-256 | 717b5ac7976706f65e7ba4e6eca8e3f3bd59bacf00722e77354a3ece8387cc3a |
File details
Details for the file biliass-2.0.0-cp39-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl
.
File metadata
- Download URL: biliass-2.0.0-cp39-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl
- Upload date:
- Size: 1.2 MB
- Tags: CPython 3.9+, manylinux: glibc 2.17+ ppc64le
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7ceebd81991903cb69dc2eceeaffb540900dfe33451cd3232cff7eb18220ecab |
|
MD5 | 1c78fc8d67a91ced3ab43c34a17d3d1b |
|
BLAKE2b-256 | 0e693a5f1888e56d4d07a7622e45a388c1a765ff2c17ba6cf3c113053c5c6776 |
File details
Details for the file biliass-2.0.0-cp39-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
.
File metadata
- Download URL: biliass-2.0.0-cp39-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
- Upload date:
- Size: 1.1 MB
- Tags: CPython 3.9+, manylinux: glibc 2.17+ ARMv7l
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 08407965b71678a6bcf4681c831411532b40ce935cabf0f4af78922818c6987c |
|
MD5 | 0bde77d62f855402fac8319d18728b9f |
|
BLAKE2b-256 | 3734982e647dd27285617890dc8aa9cf70bc60e7e20c26a07d876cb9accddb2f |
File details
Details for the file biliass-2.0.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
.
File metadata
- Download URL: biliass-2.0.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
- Upload date:
- Size: 1.2 MB
- Tags: CPython 3.9+, manylinux: glibc 2.17+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 337f1e83a86899b6e961d9c8c29a5f10b1234422299f5375cabe20a9cf3534e3 |
|
MD5 | d93a628154c84ff3dcc9bfd36edc0e68 |
|
BLAKE2b-256 | a4e45ce17da22a75ab05d03e4af836574064fb74937b5beab4099c5e555ee891 |
File details
Details for the file biliass-2.0.0-cp39-abi3-manylinux_2_5_i686.manylinux1_i686.whl
.
File metadata
- Download URL: biliass-2.0.0-cp39-abi3-manylinux_2_5_i686.manylinux1_i686.whl
- Upload date:
- Size: 1.2 MB
- Tags: CPython 3.9+, manylinux: glibc 2.5+ i686
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ef1e59d321887f06e17246a2b0d23b179ad4f39764092e5cc9576cd56dfe3895 |
|
MD5 | 1707548c661ced75384d64d6b37a5a29 |
|
BLAKE2b-256 | eef082fb65945d3605e6211475ee50f145fbb55895b4702413fefe2a7ef89ad8 |
File details
Details for the file biliass-2.0.0-cp39-abi3-macosx_11_0_arm64.whl
.
File metadata
- Download URL: biliass-2.0.0-cp39-abi3-macosx_11_0_arm64.whl
- Upload date:
- Size: 994.2 kB
- Tags: CPython 3.9+, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 09c9e97a262141342cd06f0d84a6f1dc4823d0501b19eb06fd819b2dd3a4672e |
|
MD5 | dc08cff193c393895d7995641a8979c4 |
|
BLAKE2b-256 | 8bd48e658079a733591fecb4d281bea9a65ae06890857d7c77e767ef56fd0dac |
File details
Details for the file biliass-2.0.0-cp39-abi3-macosx_10_12_x86_64.whl
.
File metadata
- Download URL: biliass-2.0.0-cp39-abi3-macosx_10_12_x86_64.whl
- Upload date:
- Size: 1.0 MB
- Tags: CPython 3.9+, macOS 10.12+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8d8de5a9eef22af49b13ba1ad0474d54676fbcf91f1d24ff9a74182c363127d0 |
|
MD5 | 525186f3903c305e09e299f94c651185 |
|
BLAKE2b-256 | 9fed31ca7f476a0328f842087606b526f7e4559c7658da40c1ecb501ffe78cdf |