Merge branch 'c' of https://106.52.207.92:9103/limingjie/OmniSocketGo into c
This commit is contained in:
@@ -180,6 +180,13 @@ static void video_pipeline_set_errno_error(video_pipeline_stats_t *stats, const
|
||||
video_pipeline_set_error(stats, buffer);
|
||||
}
|
||||
|
||||
static void video_pipeline_report_progress(const video_pipeline_config_t *config) {
|
||||
if (config == NULL || config->progress_callback == NULL) {
|
||||
return;
|
||||
}
|
||||
config->progress_callback(config->progress_context);
|
||||
}
|
||||
|
||||
void video_pipeline_config_init(video_pipeline_config_t *config) {
|
||||
if (config == NULL) {
|
||||
return;
|
||||
@@ -853,6 +860,7 @@ int video_pipeline_run(const video_pipeline_config_t *config, video_pipeline_sta
|
||||
|
||||
memset(&transport_stats, 0, sizeof(transport_stats));
|
||||
memset(&packet_metadata, 0, sizeof(packet_metadata));
|
||||
video_pipeline_report_progress(config);
|
||||
|
||||
if (config->max_frames > 0 && frame_index >= config->max_frames) {
|
||||
break;
|
||||
|
||||
@@ -161,6 +161,13 @@ static void video_pipeline_set_errno_error(video_pipeline_stats_t *stats, const
|
||||
video_pipeline_set_error(stats, buffer);
|
||||
}
|
||||
|
||||
static void video_pipeline_report_progress(const video_pipeline_config_t *config) {
|
||||
if (config == NULL || config->progress_callback == NULL) {
|
||||
return;
|
||||
}
|
||||
config->progress_callback(config->progress_context);
|
||||
}
|
||||
|
||||
void video_pipeline_config_init(video_pipeline_config_t *config) {
|
||||
if (config == NULL) {
|
||||
return;
|
||||
@@ -757,6 +764,8 @@ int video_pipeline_run(const video_pipeline_config_t *config, video_pipeline_sta
|
||||
double send_end_ms = 0.0;
|
||||
int frame_number = frame_index + 1;
|
||||
|
||||
video_pipeline_report_progress(config);
|
||||
|
||||
if (config->max_frames > 0 && frame_index >= config->max_frames) {
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user