检查视频文件是否有效 - IsValidVideoFile
函数简介
检查视频文件是否有效。
接口名称
IsValidVideoFile
DLL调用
int32_t IsValidVideoFile(int64_t instance, string videoPath)
参数说明
| 参数名 | 类型 | 说明 |
|---|---|---|
| instance | 长整数型 | OLAPlug对象的指针,由 CreateCOLAPlugInterFace 接口生成。 |
| videoPath | 字符串 | 视频文件路径 |
示例
int64_t instance = CreateCOLAPlugInterFace();
int32_t isValid = IsValidVideoFile(instance, "test.mp4");
if (isValid == 1) {
printf("视频文件有效\n");
} else {
printf("视频文件无效\n");
}
DestroyCOLAPlugInterFace(instance);
返回值
- 0: 无效
- 1: 有效
