[PR #1710] [MERGED] [FEAT][Rust] Added Encoder Module #2427

Open
opened 2026-01-29 17:22:05 +00:00 by claunia · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/CCExtractor/ccextractor/pull/1710
Author: @steel-bucket
Created: 7/13/2025
Status: Merged
Merged: 8/6/2025
Merged by: @prateekmedia

Base: masterHead: migration-encoder-common-g608


📝 Commits (10+)

  • 699626d Added Encoder Module
  • 0ffab50 Encoder: Windows Compatibility
  • 49c218e Encoder: C formatting
  • 4220c99 Merge branch 'master' into migration-encoder-common-g608
  • 5dfc62d Encoder: recommended changes to the encoding module - logic reduction
  • b2674da Encoder: Minor stylistic change
  • 06ccc2b Encoder: Review changes, renamed Line21 to Ascii
  • a564ac1 Encoder: Slight modification in C version of write_cc_buffer_as_simplexml
  • 4f954ec Encoder: Renamed 2 files
  • e1c1c74 Encoder: Minor Capitalization Change

📊 Changes

16 files changed (+1471 additions, -142 deletions)

View changed files

📝 docs/CHANGES.TXT (+1 -0)
📝 src/lib_ccx/ccx_encoders_common.c (+9 -2)
📝 src/lib_ccx/ccx_encoders_spupng.c (+0 -12)
📝 src/lib_ccx/ccx_encoders_structs.h (+12 -0)
📝 src/rust/build.rs (+4 -0)
src/rust/lib_ccxr/src/encoder/mod.rs (+4 -0)
src/rust/lib_ccxr/src/encoder/txt_helpers.rs (+427 -0)
📝 src/rust/lib_ccxr/src/lib.rs (+1 -0)
📝 src/rust/lib_ccxr/src/util/encoding.rs (+143 -120)
📝 src/rust/src/common.rs (+2 -2)
src/rust/src/encoder/common.rs (+420 -0)
src/rust/src/encoder/g608.rs (+253 -0)
src/rust/src/encoder/mod.rs (+99 -0)
src/rust/src/encoder/simplexml.rs (+89 -0)
📝 src/rust/src/lib.rs (+1 -0)
📝 src/rust/src/parser.rs (+6 -6)

📄 Description

In raising this pull request, I confirm the following (please check boxes):

  • I have read and understood the contributors guide.
  • I have checked that another pull request for this purpose does not exist.
  • I have considered, and confirmed that this submission will be valuable to others.
  • I accept that this submission may not be used, and the pull request closed at the will of the maintainer.
  • I give this submission freely, and claim no ownership to its content.
  • I have mentioned this change in the changelog.

My familiarity with the project is as follows (check one):

  • I have never used CCExtractor.
  • I have used CCExtractor just a couple of times.
  • I absolutely love CCExtractor, but have not contributed previously.
  • I am an active contributor to CCExtractor.

In this PR, I have migrated a large part of ccx_encoders_common.c and the library ccx_encoders_g608.c alongside it's helper functions. I have also fixed some issues(wrong functions) in the encoding module which were caught during regression testing. After this PR all the writing that is done on txt files is done by Rust.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/CCExtractor/ccextractor/pull/1710 **Author:** [@steel-bucket](https://github.com/steel-bucket) **Created:** 7/13/2025 **Status:** ✅ Merged **Merged:** 8/6/2025 **Merged by:** [@prateekmedia](https://github.com/prateekmedia) **Base:** `master` ← **Head:** `migration-encoder-common-g608` --- ### 📝 Commits (10+) - [`699626d`](https://github.com/CCExtractor/ccextractor/commit/699626da1d56094261b8894211e8a1fc7f3f1112) Added Encoder Module - [`0ffab50`](https://github.com/CCExtractor/ccextractor/commit/0ffab503dae48006260a7a5fd59a1d6ec3f7a768) Encoder: Windows Compatibility - [`49c218e`](https://github.com/CCExtractor/ccextractor/commit/49c218e08900865d2c0240b80a33f594e1f6272c) Encoder: C formatting - [`4220c99`](https://github.com/CCExtractor/ccextractor/commit/4220c99fd53e642641d0a2e4a15de5aeaf7b4601) Merge branch 'master' into migration-encoder-common-g608 - [`5dfc62d`](https://github.com/CCExtractor/ccextractor/commit/5dfc62d116ae4b5f2b739830832b0f54c97b8056) Encoder: recommended changes to the encoding module - logic reduction - [`b2674da`](https://github.com/CCExtractor/ccextractor/commit/b2674dad0ca537a5a8bc71f34f8670f8a4928a31) Encoder: Minor stylistic change - [`06ccc2b`](https://github.com/CCExtractor/ccextractor/commit/06ccc2b4a4cbfc524a9671a8723b000de344c0ae) Encoder: Review changes, renamed Line21 to Ascii - [`a564ac1`](https://github.com/CCExtractor/ccextractor/commit/a564ac1b79e98c8bc5a58e02e9910f717d686c14) Encoder: Slight modification in C version of write_cc_buffer_as_simplexml - [`4f954ec`](https://github.com/CCExtractor/ccextractor/commit/4f954ec8485be566d0d178780743effa23925f0c) Encoder: Renamed 2 files - [`e1c1c74`](https://github.com/CCExtractor/ccextractor/commit/e1c1c74705b887205fc4c9f98cd2235c37c39da9) Encoder: Minor Capitalization Change ### 📊 Changes **16 files changed** (+1471 additions, -142 deletions) <details> <summary>View changed files</summary> 📝 `docs/CHANGES.TXT` (+1 -0) 📝 `src/lib_ccx/ccx_encoders_common.c` (+9 -2) 📝 `src/lib_ccx/ccx_encoders_spupng.c` (+0 -12) 📝 `src/lib_ccx/ccx_encoders_structs.h` (+12 -0) 📝 `src/rust/build.rs` (+4 -0) ➕ `src/rust/lib_ccxr/src/encoder/mod.rs` (+4 -0) ➕ `src/rust/lib_ccxr/src/encoder/txt_helpers.rs` (+427 -0) 📝 `src/rust/lib_ccxr/src/lib.rs` (+1 -0) 📝 `src/rust/lib_ccxr/src/util/encoding.rs` (+143 -120) 📝 `src/rust/src/common.rs` (+2 -2) ➕ `src/rust/src/encoder/common.rs` (+420 -0) ➕ `src/rust/src/encoder/g608.rs` (+253 -0) ➕ `src/rust/src/encoder/mod.rs` (+99 -0) ➕ `src/rust/src/encoder/simplexml.rs` (+89 -0) 📝 `src/rust/src/lib.rs` (+1 -0) 📝 `src/rust/src/parser.rs` (+6 -6) </details> ### 📄 Description <!-- Please prefix your pull request with one of the following: **[FEATURE]** **[FIX]** **[IMPROVEMENT]**. --> **In raising this pull request, I confirm the following (please check boxes):** - [x] I have read and understood the [contributors guide](https://github.com/CCExtractor/ccextractor/blob/master/.github/CONTRIBUTING.md). - [x] I have checked that another pull request for this purpose does not exist. - [x] I have considered, and confirmed that this submission will be valuable to others. - [x] I accept that this submission may not be used, and the pull request closed at the will of the maintainer. - [x] I give this submission freely, and claim no ownership to its content. - [x] **I have mentioned this change in the [changelog](https://github.com/CCExtractor/ccextractor/blob/master/docs/CHANGES.TXT).** **My familiarity with the project is as follows (check one):** - [ ] I have never used CCExtractor. - [ ] I have used CCExtractor just a couple of times. - [ ] I absolutely love CCExtractor, but have not contributed previously. - [x] I am an active contributor to CCExtractor. --- In this PR, I have migrated a large part of `ccx_encoders_common.c` and the library `ccx_encoders_g608.c` alongside it's helper functions. I have also fixed some issues(wrong functions) in the `encoding` module which were caught during regression testing. After this PR all the writing that is done on txt files is done by Rust. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
claunia added the pull-request label 2026-01-29 17:22:05 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/ccextractor#2427