lucasvr / demuxfs

The MPEG-2 demultiplexer filesystem
Other
19 stars 3 forks source link

Freezing Video when PES feed to Gstreamer #5

Open artemies opened 3 years ago

artemies commented 3 years ago

Hi,

We tried feeding the video FIFO of one of the subprogram and we observed that the video is freezing. Is this due to the fact that the all subprogram are being processed by demuxfs? is there a way that we can choose only a subprogram to process?

lucasvr commented 3 years ago

I don't remember having seen this problem in the recent past. Which stream are you feeding to Gstreamer: ES or PES?

DemuxFS processes all input packets, indeed, and currently there's no way to configure it to filter only specific PIDs. You can try to make a one-liner modification to ts.c:325 and include the specific PID that you care about. Something along these lines:

    } else if (ts_is_pes_packet(header->pid, priv) && header->pid == 0x123) {

Another thing you can do is to attach a GDB process to DemuxFS to inspect what's going on by calling thread apply all bt. That should show which function is being called by each of its threads.

artemies commented 3 years ago

Hi Lucas,

We tried both ES and PES in Gstreamer and we got same results. Thanks for the insights on the PID filtering.