Create a plugin for infering buffer based on tutorial

I’ve created a plugin based on the guidelines, using TensorRT for inference within the component. However, after the inference is completed, I use a tee and queue to distribute the stream to a filesink and an rtmpsink for saving and streaming, but I’ve noticed that some frames are being dropped. My inference speed is 20ms. How can I resolve this issue or how can I check it?

I found that this problem seems to have occurred due to issues with DTS and PTS.when setting DTS error,flvmux and mp4mux dont know how to parse the order when the buffer is presented 。so i reset DTS and PTS of every buffer and reset queue1 and queue2, the pipeline works well.
,

due to this forum limits,i only post one picture .


Why did I set the DTS to 0? Because I found that after my live stream is decoded by avdec_h264, the DTS of each frame doesn’t change and is always 99:99:99, causing flvmux and mp4mux to parse the DTS and PTS of the buffer incorrectly."