更新记录
1.2.0(2025-11-04)
修复iOS编译问题。
1.1.9(2025-11-02)
修复安卓打包问题。
1.1.8(2025-10-01)
重新优化调整鸿蒙版本逻辑。
查看更多平台兼容性
uni-app(4.73)
| Vue2 | Vue2插件版本 | Vue3 | Vue2插件版本 | Chrome | Safari | app-vue | app-nvue | Android | Android插件版本 | iOS | iOS插件版本 | 鸿蒙 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| √ | 1.1.3 | √ | 1.1.3 | × | × | × | × | 5.0 | 1.1.3 | 12 | 1.1.3 | 12 |
| 微信小程序 | 支付宝小程序 | 抖音小程序 | 百度小程序 | 快手小程序 | 京东小程序 | 鸿蒙元服务 | QQ小程序 | 飞书小程序 | 快应用-华为 | 快应用-联盟 |
|---|---|---|---|---|---|---|---|---|---|---|
| × | × | × | × | × | × | × | × | × | × | × |
uni-app x(4.73)
| Chrome | Safari | Android | Android插件版本 | iOS | iOS插件版本 | 鸿蒙 | 微信小程序 |
|---|---|---|---|---|---|---|---|
| × | × | 5.0 | 1.1.3 | 12 | 1.1.3 | 12 | × |
概述
XF-ffmpegPlusUTS封装了在Android、iOS和鸿蒙系统中执行ffmpeg的命令对进行音视频处理的逻辑
插件接口
executeCommand
执行ffmpeg命令
uni-app项目中(nvue)调用示例:
import { executeCommand } from "@/uni_modules/XF-ffmpegPlusUTS"
executeCommand({
cmd: "",
complete: (res) => {
console.log(res)
}
});
uni-app x项目(uvue)中调用示例:
import { executeCommand } from "@/uni_modules/XF-ffmpegPlusUTS";
import { CommandOptions } from "@/uni_modules/XF-ffmpegPlusUTS/utssdk/interface.uts";
let options = {
cmd: "",
complete: (res : any) => {
console.log(res)
}
} as CommandOptions;
executeCommand(options);
可用性
iOS、Android、Harmony系统
可提供的1.0.0及更高版本
executeCommandSync
执行ffmpeg命令
uni-app项目中(nvue)调用示例:
import { executeCommandSync } from "@/uni_modules/XF-ffmpegPlusUTS"
executeCommandSync("");
uni-app x项目(uvue)中调用示例:
import { executeCommandSync } from "@/uni_modules/XF-ffmpegPlusUTS";
executeCommandSync("");
可用性
iOS、Android系统
可提供的1.0.0及更高版本
stopCommand
停止执行ffmpeg命令
uni-app项目中(nvue)调用示例:
import { stopCommand } from "@/uni_modules/XF-ffmpegPlusUTS"
stopCommand({
sessionId : 1,
complete: (res) => {
console.log(res)
}
});
uni-app x项目(uvue)中调用示例:
import { stopCommand } from "@/uni_modules/XF-ffmpegPlusUTS";
import { StopCommandOptions } from "@/uni_modules/XF-ffmpegPlusUTS/utssdk/interface.uts";
let options = {
sessionId : 1,
complete: (res : any) => {
console.log(res)
}
} as StopCommandOptions;
stopCommand(options);
可用性
iOS、Android、Harmony系统
可提供的1.0.0及更高版本
start
音乐合成
uni-app项目中(nvue)调用示例:
import { audioMerge } from "@/uni_modules/XF-ffmpegPlusUTS"
audioMerge({
onePath : "",
twoPath : "",
targetPath : "",
complete: (res) => {
console.log(res)
}
});
uni-app x项目(uvue)中调用示例:
import { audioMerge } from "@/uni_modules/XF-ffmpegPlusUTS";
import { AudioMergeOptions } from "@/uni_modules/XF-ffmpegPlusUTS/utssdk/interface.uts";
let options = {
onePath : "",
twoPath : "",
targetPath : "",
complete: (res : any) => {
console.log(res)
}
} as AudioMergeOptions;
audioMerge(options);
可用性
iOS、Android、Harmony系统
可提供的1.0.0及更高版本
videoMerge
视频合成
uni-app项目中(nvue)调用示例:
import { videoMerge } from "@/uni_modules/XF-ffmpegPlusUTS"
videoMerge({
videoPath : "",
audioPath : "",
argetPath : "",
complete: (res) => {
console.log(res)
}
});
uni-app x项目(uvue)中调用示例:
import { videoMerge } from "@/uni_modules/XF-ffmpegPlusUTS";
import { VideoMergeOptions } from "@/uni_modules/XF-ffmpegPlusUTS/utssdk/interface.uts";
let options = {
videoPath : "",
audioPath : "",
argetPath : "",
complete: (res : any) => {
console.log(res)
}
} as VideoMergeOptions;
videoMerge(options);
可用性
iOS、Android、Harmony系统
可提供的1.0.0及更高版本
getMediaFileInfo
获取文件信息
uni-app项目中(nvue)调用示例:
import { getMediaFileInfo } from "@/uni_modules/XF-ffmpegPlusUTS"
getMediaFileInfo({
path : "",
complete: (res) => {
console.log(res)
}
});
uni-app x项目(uvue)中调用示例:
import { getMediaFileInfo } from "@/uni_modules/XF-ffmpegPlusUTS";
import { FileOptions } from "@/uni_modules/XF-ffmpegPlusUTS/utssdk/interface.uts";
let options = {
path : "",
complete: (res : any) => {
console.log(res)
}
} as FileOptions;
getMediaFileInfo(options);
可用性
iOS、Android系统
可提供的1.0.0及更高版本
getMediaFileInfoSync
获取文件信息
uni-app项目中(nvue)调用示例:
import { getMediaFileInfoSync } from "@/uni_modules/XF-ffmpegPlusUTS"
getMediaFileInfoSync("");
uni-app x项目(uvue)中调用示例:
import { getMediaFileInfoSync } from "@/uni_modules/XF-ffmpegPlusUTS";
getMediaFileInfoSync("");
可用性
iOS、Android系统
可提供的1.0.0及更高版本
executeFFprobeCommand
执行ffprobe命令
uni-app项目中(nvue)调用示例:
import { executeFFprobeCommand } from "@/uni_modules/XF-ffmpegPlusUTS"
executeFFprobeCommand({
cmd: "",
complete: (res) => {
console.log(res)
}
});
uni-app x项目(uvue)中调用示例:
import { executeFFprobeCommand } from "@/uni_modules/XF-ffmpegPlusUTS";
import { CommandOptions } from "@/uni_modules/XF-ffmpegPlusUTS/utssdk/interface.uts";
let options = {
cmd: "",
complete: (res : any) => {
console.log(res)
}
} as CommandOptions;
executeFFprobeCommand(options);
可用性
iOS、Android、Harmony系统
可提供的1.0.0及更高版本

收藏人数:
购买普通授权版(
试用
赞赏(0)
下载 192
赞赏 0
下载 10976950
赞赏 1800
赞赏
京公网安备:11010802035340号