mirror of
https://github.com/CCExtractor/ccextractor.git
synced 2026-04-18 20:12:50 +00:00
[PR #1662] [MERGED] [FEAT] added demuxer and file_functions module
#2368
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/CCExtractor/ccextractor/pull/1662
Author: @steel-bucket
Created: 2/11/2025
Status: ✅ Merged
Merged: 12/8/2025
Merged by: @prateekmedia
Base:
master← Head:migration-demuxer-module📝 Commits (10+)
1bae1a8feat: added demuxer modulea1dc67eCargo Lock Update26aba5eCompleted file_functions and demuxer7718d7bCompleted file_functions and demuxer9ad0e05written extern functions for demuxer63da17fRemoved libc completely, added tests for gxf and ported gxf to C6bc2607Hardsubx error fixed985a188Fixing format issues1cbe989clippy errors fixed7e15406fixing format issues📊 Changes
35 files changed (+7885 additions, -808 deletions)
View changed files
📝
docs/CHANGES.TXT(+1 -0)📝
src/lib_ccx/ccx_demuxer.c(+35 -1)📝
src/lib_ccx/ccx_demuxer_mxf.c(+0 -24)📝
src/lib_ccx/ccx_demuxer_mxf.h(+27 -2)📝
src/lib_ccx/ccx_gxf.c(+0 -299)📝
src/lib_ccx/ccx_gxf.h(+298 -0)📝
src/lib_ccx/es_functions.c(+16 -6)📝
src/rust/Cargo.lock(+474 -193)📝
src/rust/Cargo.toml(+7 -2)📝
src/rust/build.rs(+16 -0)📝
src/rust/lib_ccxr/src/activity.rs(+29 -2)📝
src/rust/lib_ccxr/src/common/constants.rs(+17 -1)📝
src/rust/src/avc/common_types.rs(+0 -107)📝
src/rust/src/avc/core.rs(+1 -1)📝
src/rust/src/avc/mod.rs(+0 -50)📝
src/rust/src/common.rs(+478 -7)➕
src/rust/src/ctorust.rs(+845 -0)➕
src/rust/src/demuxer/common_types.rs(+326 -0)➕
src/rust/src/demuxer/demux.rs(+717 -0)➕
src/rust/src/demuxer/demuxer_data.rs(+41 -0)...and 15 more files
📄 Description
In raising this pull request, I confirm the following (please check boxes):
My familiarity with the project is as follows (check one):
In this PR, I have attempted to port the large
demuxermodule to Rust, the primary logic of the heavily interconnected C librariesfile_functions.cand,ccx_demuxer.cand their corresponding header files has aleady been implemented here.This PR was inspired by the ones done for the 708 Decoder in CCextractor.
The part of the codebase that the demuxer part of this PR migrates to Rust is the part that Opens a File(ccx_demuxer_open), points the codebase towards that file, detects the stream type and some other parameters like myth, and then closes the file or gets the file size.
The file_functions part of this PR is tested locally, and in unit tests, but integrating it into C made the codebase really slow, due to the constant copying back and forth C and Rust, so it was left to be used in future Rust Libraries like MythTV, MXF, GXF, etc.
Any criticism or suggestion is wholeheartedly welcome.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.