# format_converter **Repository Path**: mousess/format_converter ## Basic Information - **Project Name**: format_converter - **Description**: 格式工厂转换 - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: main - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2026-04-21 - **Last Updated**: 2026-04-21 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # 格式转换工具 一款简单易用的 Windows 桌面格式转换工具,支持视频和图片格式转换,专为老年用户设计。 ## 功能特点 - **视频格式转换**: 支持 MP4、AVI、MOV、MKV、WEBM、GIF 等格式 - **图片格式转换**: 支持 PNG、JPG、WEBP、BMP、GIF 等格式 - **批量转换**: 支持一次选择多个文件批量转换 - **大文件支持**: 支持转换超大文件 - **简单易用**: 界面简洁,拖拽即可添加文件 ## Windows 构建与运行 ### 前置要求 1. **安装 Flutter SDK** - 下载地址: https://docs.flutter.dev/get-started/install/windows - 将 Flutter 添加到系统 PATH 环境变量 2. **安装 Visual Studio Build Tools** - 下载地址: https://visualstudio.microsoft.com/downloads/ - 选择 "C++ 桌面开发" 工作负载 3. **安装 FFmpeg (视频转换必需)** ```powershell # 使用 winget 安装 (推荐) winget install Gyan.FFmpeg # 或者下载安装包: https://ffmpeg.org/download.html # 将 FFmpeg 添加到系统 PATH 环境变量 ``` ### 构建步骤 ```powershell # 1. 克隆项目 git clone https://gitee.com/mousess/format_converter.git cd format_converter # 2. 启用 Windows 支持 flutter config --enable-windows-desktop # 3. 安装依赖 flutter pub get # 4. 运行应用 (开发模式) flutter run -d windows # 5. 构建发布版本 flutter build windows --release ``` ### 运行构建好的程序 构建完成后,`.exe` 文件位于: ``` build\windows\runner\Release\format_converter.exe ``` 双击运行即可。 ## macOS 构建与运行 ```bash # 1. 克隆项目 git clone https://gitee.com/mousess/format_converter.git cd format_converter # 2. 安装 FFmpeg brew install ffmpeg # 3. 运行应用 flutter run -d macos ``` ## 系统要求 ### Windows - Windows 10 或更高版本 - Flutter SDK 3.0+ - Visual Studio Build Tools - 至少 4GB 内存 - FFmpeg (视频转换必需) ### macOS - macOS 10.14+ - Flutter SDK 3.0+ - FFmpeg (视频转换必需) ## 界面预览 软件采用左右分栏布局: - **左侧**: 文件选择区,支持拖拽和点击选择 - **右侧**: 转换设置区,选择输出格式并开始转换 ## 注意事项 1. **视频转换需要 FFmpeg**: 如果不安装 FFmpeg,视频转换功能将不可用,图片转换不受影响 2. **输出目录**: 转换后的文件保存在 `文档/格式转换输出/` 文件夹 3. **权限提示**: 首次运行可能需要授权文件访问权限 4. **文件名冲突**: 如果文件名冲突,会自动添加时间戳 ## 技术栈 - Flutter 3.0+ - FFmpeg (视频处理) - image 包 (图片处理) - desktop_drop (拖拽支持) - file_picker (文件选择) ## 常见问题 ### Q: 视频转换失败,提示 "FFmpeg 未找到"? A: 请确保 FFmpeg 已安装并添加到系统 PATH。重启终端后运行 `ffmpeg -version` 验证。 ### Q: 构建 Windows 版本时报错? A: 确保已安装 Visual Studio Build Tools 和 C++ 桌面开发工作负载。 ### Q: 文件选择后无法转换? A: 请将文件放到桌面或下载文件夹,避免沙盒权限问题。