devejesus/video-encoder
Composer 安装命令:
composer require devejesus/video-encoder
包简介
A simple PHP-based video encoder that converts raw RGB24 frames to YUV420p format using custom pixel processing.
README 文档
README
A simple PHP-based video encoder that converts raw RGB24 frames to YUV420p format using custom pixel processing.
Features
- Convert RGB24 frames to YUV420p format
- Efficient pixel processing
- Simple and easy-to-use interface
- No external dependencies required
Requirements
- PHP >= 8.0
Installation
You can install the package via composer:
composer require devejesus/video-encoder
Usage
use Devejesus\VideoEncoder\Encoder\RGB24ToYUV420Encoder; use Devejesus\VideoEncoder\Model\VideoConfig; // Create a video configuration $config = new VideoConfig(384, 216); // width and height must be even numbers // Initialize the encoder $encoder = new RGB24ToYUV420Encoder(); // Convert the video try { $encoder->encode( 'input.rgb24', // Input file path (RGB24 format) 'output.yuv', // Output file path (YUV420p format) $config ); echo "Conversion completed successfully!\n"; } catch (\Exception $e) { echo "Error: " . $e->getMessage() . "\n"; }
Input Format Requirements
- The input file must be in RGB24 format
- Width and height must be even numbers
- Each pixel is represented by 3 bytes (R, G, B)
- No headers or metadata in the file
Testing
composer test
Contributing
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
License
This package is licensed under the MIT License - see the LICENSE file for details.
devejesus/video-encoder 适用场景与选型建议
devejesus/video-encoder 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 0 次下载、GitHub Stars 达 0, 最近一次更新时间为 2025 年 06 月 11 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 devejesus/video-encoder 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 devejesus/video-encoder 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
统计信息
- 总下载量: 0
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 26
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2025-06-11