65 color_printf(
"Filter " TBOLD(
"ratelimite")
" limits frame rate of video stream.\n"
66 "This filter is related to a capture filter " TBOLD(
"every")
".\n\n");
67 printf(
"ratelimit usage:\n\n");
75 if (strlen(cfg) == 0 || strcasecmp(cfg,
"help") == 0) {
77 return strlen(cfg) == 0 ? -1 : 1;
81 s->
fps = strtod(cfg, NULL);
struct video_frame * frame
void vf_free(struct video_frame *buf)
Frees video_frame structure.
struct video_desc video_desc_from_frame(const struct video_frame *frame)
Returns struct video_desc from video frame.
struct video_frame * vf_alloc_desc(struct video_desc desc)
Allocates video frame accordig given desc.
#define CAPTURE_FILTER_ABI_VERSION
int color_printf(const char *format,...)
@ LIBRARY_CLASS_CAPTURE_FILTER
#define REGISTER_MODULE(name, info, lclass, abi)
Registers module to global modules' registry.
static struct video_frame * filter(void *state, struct video_frame *in)
static const struct capture_filter_info capture_filter_ratelimit
static void done(void *state)
static void dispose_frame(struct video_frame *f)
static int init(struct module *parent, const char *cfg, void **state)
time_ns_t next_frame_time
Struct tile is an area of video_frame.
void(* dispose)(struct video_frame *)
Struct video_frame represents a video frame and contains video description.
struct tile tiles[FLEXIBLE_ARRAY_MEMBER]
struct video_frame_callbacks callbacks
static time_ns_t get_time_in_ns()
This is an umbrella header for video functions.
#define VIDEO_FRAME_DISPOSE(frame)