]>
git.ipfire.org Git - thirdparty/util-linux.git/blob - term-utils/script-playutils.h
f3bce5fe4ffe13a3c3674d8b493fa2ee0893b2ea
1 #ifndef UTIL_LINUX_SCRIPT_PLAYUTILS_H
2 #define UTIL_LINUX_SCRIPT_PLAYUTILS_H
9 #define SCRIPTREPLAY_DEBUG_INIT (1 << 1)
10 #define SCRIPTREPLAY_DEBUG_TIMING (1 << 2)
11 #define SCRIPTREPLAY_DEBUG_LOG (1 << 3)
12 #define SCRIPTREPLAY_DEBUG_MISC (1 << 4)
13 #define SCRIPTREPLAY_DEBUG_ALL 0xFFFF
15 UL_DEBUG_DECLARE_MASK(scriptreplay
);
17 #define DBG(m, x) __UL_DBG(scriptreplay, SCRIPTREPLAY_DEBUG_, m, x)
18 #define ON_DBG(m, x) __UL_DBG_CALL(scriptreplay, SCRIPTREPLAY_DEBUG_, m, x)
22 REPLAY_CRMODE_AUTO
= 0,
30 void replay_init_debug(void);
31 struct replay_setup
*replay_new_setup(void);
32 void replay_free_setup(struct replay_setup
*stp
);
34 int replay_set_default_type(struct replay_setup
*stp
, char type
);
35 int replay_set_crmode(struct replay_setup
*stp
, int mode
);
36 int replay_set_timing_file(struct replay_setup
*stp
, const char *filename
);
37 const char *replay_get_timing_file(struct replay_setup
*setup
);
38 int replay_get_timing_line(struct replay_setup
*setup
);
39 int replay_associate_log(struct replay_setup
*stp
, const char *streams
, const char *filename
);
41 int replay_set_delay_min(struct replay_setup
*stp
, const struct timeval
*tv
);
42 int replay_set_delay_max(struct replay_setup
*stp
, const struct timeval
*tv
);
43 int replay_set_delay_div(struct replay_setup
*stp
, const double divi
);
45 struct timeval
*replay_step_get_delay(struct replay_step
*step
);
46 const char *replay_step_get_filename(struct replay_step
*step
);
47 int replay_step_is_empty(struct replay_step
*step
);
48 int replay_get_next_step(struct replay_setup
*stp
, char *streams
, struct replay_step
**xstep
);
50 int replay_emit_step_data(struct replay_setup
*stp
, struct replay_step
*step
, int fd
);
52 bool replay_get_is_paused(struct replay_setup
*setup
);
53 void replay_toggle_pause(struct replay_setup
*setup
);
55 #endif /* UTIL_LINUX_SCRIPT_PLAYUTILS_H */