From d0f53c3e32d061860cbf2675c269e02e1b6b03e4 Mon Sep 17 00:00:00 2001 From: Lawtro <98205608+Lawtro37@users.noreply.github.com> Date: Fri, 2 Oct 2026 17:25:59 +1000 Subject: [PATCH 1/4] fix spelling mistakes in README.md --- README.md | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index 84b6c04..b9b0d8b 100644 --- a/README.md +++ b/README.md @@ -3,25 +3,25 @@ [![ass-kt - Version](https://img.shields.io/maven-central/v/io.github.peerless2012/ass-kt?label=ass-kt)](https://central.sonatype.com/artifact/io.github.peerless2012/ass-kt) [![ass-media - Version](https://img.shields.io/maven-central/v/io.github.peerless2012/ass-media?label=ass-media)](https://central.sonatype.com/artifact/io.github.peerless2012/ass-media) -A collection of libraries for implementing [libass](https://github.com/libass/libass) for Android. +A collection of libraries for implementing [libass](https://github.com/libass/libass) into Android apps. -It use [libass-cmake](https://github.com/peerless2012/libass-cmake) to build libass. +It is built using [libass-cmake](https://github.com/peerless2012/libass-cmake). ## Modules ### [lib_ass](./lib_ass) -A native build library with prefab feature, this module contains libass.so and the header files. +A native build library with prefab features, this module contains libass.so and its header files. -App want to use libass in C/C++ can use this module. +Apps that want to use libass in C/C++ can use this module. ### [lib_ass_kt](./lib_ass_kt) -A kotlin wrapper for libass native api. +A kotlin wrapper for libass's native api. -App want to use libass in java/kotlin can use this module. +Apps that want to use libass with java/kotlin can use this module. ### [lib_ass_media](./lib_ass_media) -A media3 extend library for libass. +A media3 extension library for libass. -App use media3 can use this module to add ass for your player. +Apps that use media3 can use this module to implement libass into your player. ## Who is using | Icon | Name | @@ -33,7 +33,7 @@ App use media3 can use this module to add ass for your player. | NuvioTV | [NuvioTV](https://github.com/NuvioMedia/NuvioTV) | ## Issue -If you have issue when use, [create](https://github.com/peerless2012/libass-android/issues/new) an issue. +If you have any issues while useing this, [create](https://github.com/peerless2012/libass-android/issues/new) an issue. ## PR -If you want to fix or add feature, [create](https://github.com/peerless2012/libass-android/compare) a pr. +If you want to fix something or add features, [create](https://github.com/peerless2012/libass-android/compare) a pr. From 1e10966cb022f8ce48082d2a868e0a48d72149db Mon Sep 17 00:00:00 2001 From: Lawtro <98205608+Lawtro37@users.noreply.github.com> Date: Fri, 2 Oct 2026 17:29:03 +1000 Subject: [PATCH 2/4] fix grammar and spelling --- lib_ass/README.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lib_ass/README.md b/lib_ass/README.md index b04af0a..af14565 100644 --- a/lib_ass/README.md +++ b/lib_ass/README.md @@ -1,10 +1,10 @@ # ASS -A native build library with prefab feature, this module contains libass.so and the header files. +A native build library with prefab features, this module contains libass.so and its header files. -App want to use libass in C/C++ can use this module. +Apps that want to use libass in C/C++ can use this module. ## How to use -1. Add MavenCenter to your project +1. Add MavenCentral to your project ``` allprojects { repositories { @@ -12,7 +12,7 @@ App want to use libass in C/C++ can use this module. } } ``` -2. Enable prefab feature. +2. Enable the prefab feature. ``` android { buildFeatures { @@ -24,13 +24,13 @@ App want to use libass in C/C++ can use this module. ``` implementation "io.github.peerless2012:ass:x.x.x" ``` -4. Add prebuild in `CMakeLists.txt` +4. Add the prebuild in `CMakeLists.txt` ``` # Add these two lines. find_package(lib_ass REQUIRED CONFIG) target_link_libraries(${CMAKE_PROJECT_NAME} PRIVATE lib_ass::ass) ``` -5. Add libass header in your c/c++ code +5. Add the libass headers in your c/c++ code ``` #include "ass.h" ``` \ No newline at end of file From 6d90fdae3242c62d3865e58790d0f971987ca3c1 Mon Sep 17 00:00:00 2001 From: Lawtro <98205608+Lawtro37@users.noreply.github.com> Date: Fri, 2 Oct 2026 17:33:02 +1000 Subject: [PATCH 3/4] fix spelling and grammar --- lib_ass_kt/README.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib_ass_kt/README.md b/lib_ass_kt/README.md index b9776fe..e03b130 100644 --- a/lib_ass_kt/README.md +++ b/lib_ass_kt/README.md @@ -1,10 +1,10 @@ # ASS Kt -A kotlin wrapper for libass native api. +A kotlin wrapper for libass's native api. -App want to use libass in java/kotlin can use this module. +Apps that want to use libass in java/kotlin can use this module. ## How to use -1. Add MavenCenter to your project +1. Add MavenCentral to your project ``` allprojects { repositories { @@ -12,11 +12,11 @@ App want to use libass in java/kotlin can use this module. } } ``` -2. Add dependency. +2. Add the dependency. ``` implementation "io.github.peerless2012:ass-kt:x.x.x" ``` -3. Use libass-kt in java/kotlin +3. Use libass-kt your java/kotlin code ``` val ass = ASS() ``` \ No newline at end of file From 4a6fd9a78a4abd2acd634df03879b3b99ab36113 Mon Sep 17 00:00:00 2001 From: Lawtro <98205608+Lawtro37@users.noreply.github.com> Date: Fri, 2 Oct 2026 18:06:25 +1000 Subject: [PATCH 4/4] fix grammar and spelling --- lib_ass_media/README.md | 47 ++++++++++++++++++++--------------------- 1 file changed, 23 insertions(+), 24 deletions(-) diff --git a/lib_ass_media/README.md b/lib_ass_media/README.md index 2938aad..5387d94 100644 --- a/lib_ass_media/README.md +++ b/lib_ass_media/README.md @@ -1,11 +1,10 @@ # ASS Media -A media3 extend library for libass. +A media3 extension library for libass. -App use media3 can use this module to add ass for your player. +Apps that use media3 can use this module to add libass into their player. ## Feature -There are three ways to render ass subtitle. -Which is defined in `AssRenderType`. +There are three ways to render ass subtitles which are defined in `AssRenderType`. | Type | Feature | Anim | HDR/DV | Block render/UI | | :----: | :----: | :----: | :----: | :----: | @@ -16,44 +15,44 @@ Which is defined in `AssRenderType`. | OVERLAY_OPEN_GL | Overlay | ✅ | ✅ | ❌ | * [OverlayShaderProgram does not support HDR colors yet](https://github.com/androidx/media/issues/723) -* [Why does TextOverLay support hdr, but Bitmap not support?](https://github.com/androidx/media/issues/2383) +* [Why does TextOverLay support hdr, but not Bitmap support?](https://github.com/androidx/media/issues/2383) ### 1. CUES -The ass/ssa subtitle will be parsed and transcode to bytes, and decode to bitmap when render. +The ass/ssa subtitles will be parsed and transcoded into bytes, and decoded into a bitmap when rendered. -This type not support dynamic feature, because all subtitle and it time is static. +This type does not support the dynamic feature, because all subtitles and their time are static. -But since the subtitle is transcode, it will not cost too much time when render. All work is done in parse thread. +However, since the subtitles are transcodeed, they will be to expensiveto render. All the work is done in the parse thread. ### 2. EFFECTS_CANVAS -The ass/ssa subtitle will be cal and render at runtime use media3 effect feature, and this will support all dynamic features. +The ass/ssa subtitles will be calculated and rendered at runtime using the media3 effect feature, this supports all dynamic features. -And this need to create a screen size offscreen bitmap to render the libass bitmap pieces. +This needs the screen size to create an off-screen bitmap and render the libass bitmap pieces. -But when the dynamic feature is too complex, and libass will cost too much time to cal, the render will be blocked. +If a dynamic feature is too complex, libass will take too long to long to calculate and the render will be blocked. ### 3. EFFECTS_OPEN_GL -Just like `EFFECTS_CANVAS`, but use OpenGL to render. and the offscreen tex is create to render the bitmap pieces. +Just like `EFFECTS_CANVAS`, but uses OpenGL to render. and the offscreen text is created to render the bitmap pieces. -Due to test, the `EFFECTS_OPEN_GL` will save 1/3 time when render. +According to tests, the `EFFECTS_OPEN_GL` will take a 1/3 of the time to render. ### 4. OVERLAY_CANVAS -The ass/ssa subtitle will be cal at runtime, and add a `Overlay` widget in `SubtitleView` to render subtitle. +The ass/ssa subtitles will be calculated at runtime, and an `Overlay` widget is added in `SubtitleView` to render the subtitles. -The `libass` render result will copy to bitmap, and draw in `Canvas`. +The `libass` render result will copy into a bitmap, and draw in the `Canvas`. -It will block UI thread when rendering. +This will block UI thread when rendering. ### 4. OVERLAY_OPEN_GL -Just like `OVERLAY_CANVAS`, but the `libass` render result will pass to `OpenGL` texture, and avoid create tmp bitmap. +Just like `OVERLAY_CANVAS`, but the `libass` render result will passed to `OpenGL` as a texture to avoid creating temporary bitmap. -It will save half memory than `OVERLAY_CANVAS`. +It uses about half as much memory as `OVERLAY_CANVAS`. -And the `libass` render and `OpenGL` draw on another separate thread, it will not block the UI thread like `OVERLAY_CANVAS`. +The `libass` renderer and `OpenGL` draw on separate thread, so it will not block the UI thread like `OVERLAY_CANVAS`. ## How to use -1. Add MavenCenter to your project +1. Add MavenCentral to your project ``` allprojects { repositories { @@ -61,11 +60,11 @@ And the `libass` render and `OpenGL` draw on another separate thread, it will no } } ``` -2. Add dependency. +2. Add the dependency. ``` implementation "io.github.peerless2012:ass-media:x.x.x" ``` -3. Use libass-media in java/kotlin +3. Using libass-media in your java/kotlin code ``` player = ExoPlayer.Builder(this) .buildWithAssSupport( @@ -73,7 +72,7 @@ And the `libass` render and `OpenGL` draw on another separate thread, it will no AssRenderType.OPEN_GL ) ``` -4. Add external subtitles. +4. Adding external subtitles ``` val enConfig = MediaItem.SubtitleConfiguration .Builder(Uri.parse("http://192.168.0.254:80/files/f-en.ass")) @@ -101,7 +100,7 @@ And the `libass` render and `OpenGL` draw on another separate thread, it will no .setUri(url) .setSubtitleConfigurations(ImmutableList.of(enConfig, jpConfig, zhConfig)) ``` - NOTE: Make sure the `id` is set and different from media self track size. Recommend bigger than 128 or more bigger. + NOTE: Make sure the `id` is set and different from the media self track size. The recommend value is 128 or larger. ## Configuration