-
Notifications
You must be signed in to change notification settings - Fork 47
/
filter_in_out.go
50 lines (41 loc) · 1.33 KB
/
filter_in_out.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
package astiav
//#include <libavfilter/avfilter.h>
import "C"
// https://ffmpeg.org/doxygen/7.0/structAVFilterInOut.html
type FilterInOut struct {
c *C.AVFilterInOut
}
func newFilterInOutFromC(c *C.AVFilterInOut) *FilterInOut {
if c == nil {
return nil
}
return &FilterInOut{c: c}
}
// https://ffmpeg.org/doxygen/7.0/group__lavfi.html#ga6e1c2931e15eb4283c59c6ccc8b83919
func AllocFilterInOut() *FilterInOut {
return newFilterInOutFromC(C.avfilter_inout_alloc())
}
// https://ffmpeg.org/doxygen/7.0/group__lavfi.html#ga294500a9856260eb1552354fd9d9a6c4
func (i *FilterInOut) Free() {
C.avfilter_inout_free(&i.c)
}
// https://ffmpeg.org/doxygen/7.0/structAVFilterInOut.html#a88afecac258f51aab7e9a9db9e7a4d58
func (i *FilterInOut) SetName(n string) {
i.c.name = C.CString(n)
}
// https://ffmpeg.org/doxygen/7.0/structAVFilterInOut.html#a3227857d0b955b639f4950d13e4e6f40
func (i *FilterInOut) SetFilterContext(c *FilterContext) {
i.c.filter_ctx = (*C.AVFilterContext)(c.c)
}
// https://ffmpeg.org/doxygen/7.0/structAVFilterInOut.html#a386ff90d40aa22f5612dd5eca734ed48
func (i *FilterInOut) SetPadIdx(idx int) {
i.c.pad_idx = C.int(idx)
}
// https://ffmpeg.org/doxygen/7.0/structAVFilterInOut.html#af8c8cf9ffb650974d19e791f5bb7cf33
func (i *FilterInOut) SetNext(n *FilterInOut) {
var nc *C.AVFilterInOut
if n != nil {
nc = n.c
}
i.c.next = nc
}