fix: unnecessary structs
This commit is contained in:
+6
-9
@@ -101,9 +101,8 @@ static void start_video_background_read(VideoCapture *video_capture,
|
||||
Context *context, int input_index,
|
||||
bool trace_fps) {
|
||||
pthread_t thread;
|
||||
struct VideoBackgroundReadArgs *process_args =
|
||||
(struct VideoBackgroundReadArgs *)malloc(
|
||||
sizeof(struct VideoBackgroundReadArgs));
|
||||
VideoBackgroundReadArgs *process_args =
|
||||
(VideoBackgroundReadArgs *)malloc(sizeof(VideoBackgroundReadArgs));
|
||||
process_args->capture = video_capture;
|
||||
process_args->context = context;
|
||||
process_args->input_index = input_index;
|
||||
@@ -201,9 +200,8 @@ static void midi_callback(unsigned char code, unsigned char value) {
|
||||
|
||||
static void start_state_background_write() {
|
||||
pthread_t thread;
|
||||
struct StateBackgroundWriteArgs *process_args =
|
||||
(struct StateBackgroundWriteArgs *)malloc(
|
||||
sizeof(struct StateBackgroundWriteArgs));
|
||||
StateBackgroundWriteArgs *process_args =
|
||||
(StateBackgroundWriteArgs *)malloc(sizeof(StateBackgroundWriteArgs));
|
||||
process_args->context = &context;
|
||||
process_args->state_config = project.state_config;
|
||||
process_args->midi = &midi;
|
||||
@@ -218,9 +216,8 @@ static void start_state_background_write() {
|
||||
|
||||
static void start_midi_background_listen() {
|
||||
pthread_t thread;
|
||||
struct MidiBackgroundListenArgs *process_args =
|
||||
(struct MidiBackgroundListenArgs *)malloc(
|
||||
sizeof(struct MidiBackgroundListenArgs));
|
||||
MidiBackgroundListenArgs *process_args =
|
||||
(MidiBackgroundListenArgs *)malloc(sizeof(MidiBackgroundListenArgs));
|
||||
process_args->device = &midi;
|
||||
process_args->context = &context;
|
||||
process_args->event_callback = midi_callback;
|
||||
|
||||
Reference in New Issue
Block a user