Skip to content

Commit

Permalink
use RSID option even if no ID set on parent filter
Browse files Browse the repository at this point in the history
  • Loading branch information
jeanlf committed Apr 9, 2024
1 parent 87c8171 commit 779b88a
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/filter_core/filter_pid.c
Expand Up @@ -4558,6 +4558,11 @@ static void gf_filter_pid_init_task(GF_FSTask *task)
if (!filter_dst->freg->configure_pid) continue;
if (filter_dst->finalized || filter_dst->removed || filter_dst->disabled || filter_dst->marked_for_removal || filter_dst->no_inputs) continue;
if (filter_dst->target_filter == pid->filter) continue;
//PID requires a sourceID on target filter and none is set, ignore
if (pid->require_source_id && !filter_dst->source_ids) {
GF_LOG(GF_LOG_DEBUG, GF_LOG_FILTER, ("PID %s requires source ID, not set for filter %s\n", pid->name, filter_dst->name));
continue;
}

//handle re-entrant filter registries (eg filter foo of type A output usually cannot connect to filter bar of type A)
if (pid->pid->filter->freg == filter_dst->freg) {
Expand Down Expand Up @@ -4900,11 +4905,14 @@ static void gf_filter_pid_init_task(GF_FSTask *task)
use_explicit_link = GF_TRUE;
}
//if no source ID on the dst filter, this means the dst filter accepts any possible connections from out filter

#if 0 //this is now checked above regardless of whether a filterID is set
//unless prevented for this pid
else if (pid->require_source_id) {
GF_LOG(GF_LOG_DEBUG, GF_LOG_FILTER, ("PID %s requires source ID, not set for filter %s\n", pid->name, filter_dst->name));
continue;
}
#endif
}
//no filterID and dst expects only specific filters, continue
else if (filter_dst->source_ids && !ignore_source_ids) {
Expand Down

0 comments on commit 779b88a

Please sign in to comment.