FFmpeg - Extracting video and audio from transport stream file (.ts)
I wish to extract the audio and video of a certain program in a transport stream file (.ts) by specifying its PID without losing quality and using the same codec in the resulting file (the output file is a MPEG). Is that even possible with FFmpeg? If so, how can I do it? So far, I've come to this command: ffmpeg -i tsfile.ts -vcodec copy -acodec copy -q:v 1 output.mpg Edit : Note that the file output.mpg is created. The file contains the video but the audio isn't attached (no sound). Also, I am unable to specify the program PID to extract. Edit 2 : Here's the output of ffmpeg -i tsfile.ts