avformat/hlsenc: merge mpegts and fmp4 workflow to one workflow