Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/miyako/ffmpeg
https://github.com/miyako/ffmpeg
4d-class 4d-component ffmpeg
Last synced: 12 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/miyako/ffmpeg
- Owner: miyako
- License: mit
- Created: 2024-11-11T00:36:46.000Z (about 2 months ago)
- Default Branch: main
- Last Pushed: 2024-11-28T06:44:10.000Z (about 1 month ago)
- Last Synced: 2024-11-28T07:29:31.390Z (about 1 month ago)
- Topics: 4d-class, 4d-component, ffmpeg
- Language: 4D
- Homepage: https://miyako.github.io/ffmpeg/
- Size: 93.8 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
![version](https://img.shields.io/badge/version-20%2B-E23089)
![platform](https://img.shields.io/static/v1?label=platform&message=mac-intel%20|%20mac-arm%20|%20win-64&color=blue)
[![license](https://img.shields.io/github/license/miyako/ffmpeg)](LICENSE)
![downloads](https://img.shields.io/github/downloads/miyako/ffmpeg/total)### Licensing
* the source code of this component is licensed under the [MIT license](https://github.com/miyako/ffmpeg/blob/master/LICENSE).
* see [ffmpeg.org](https://www.ffmpeg.org/legal.html) for the licensing of **ffmpeg**.# ffmpeg
based on [eugeneware/ffmpeg-static](https://github.com/eugeneware/ffmpeg-static)
## dependencies.json
```json
{
"dependencies": {
"ffmpeg": {
"github": "miyako/ffmpeg",
"version": "*"
}
}
}
```the macOS executable targets Apple Silicon. you may download a universal binary edition from releases.
---
example of a synchronous call
```4d
var $in : 4D.File
$in:=Folder(fk desktop folder).file("sample.mov")var $ffmpeg : cs.FFmpeg.FFmpeg
$ffmpeg:=cs.FFmpeg.FFmpeg.new()var $info : Text
$info:=$ffmpeg.start(["-i"; $in]).worker.wait().errorALERT($info)
```example of an asynchronous call
```4d
#DECLARE($params : Object)If ($params=Null)
/*
async calls must be performed in a worker or form
*/
CALL WORKER(1; Current method name; {})
Else
$in:=Folder(fk desktop folder).file("sample.mov")
$out:=Folder(fk desktop folder).file("sample.mp4")
var $ffmpeg : cs.FFmpeg.FFmpeg
$ffmpeg:=cs.FFmpeg.FFmpeg.new()
$ffmpeg.start(["-i"; $in; "-vcodec"; "libx264"; $out])
End if
```## note on notarisation
need to increase size when creating `.dmg`. `ffmpeg` needs `1GB`, `ffprobe` needs `5GB`.
```
hdiutil create -format UDBZ -plist -srcfolder {in} {out} -size {size}
```else possible "resource is busy" error.
```
hdiutil: create failed - リソースが使用中です
```