• Home
  • Raw
  • Download

Lines Matching refs:avf

39     AVFormatContext *avf;  member
123 AVFormatContext *avf; in close_slave() local
127 avf = tee_slave->avf; in close_slave()
128 if (!avf) in close_slave()
132 ret = av_write_trailer(avf); in close_slave()
135 for (i = 0; i < avf->nb_streams; ++i) in close_slave()
141 ff_format_io_close(avf, &avf->pb); in close_slave()
142 avformat_free_context(avf); in close_slave()
143 tee_slave->avf = NULL; in close_slave()
147 static void close_slaves(AVFormatContext *avf) in close_slaves() argument
149 TeeContext *tee = avf->priv_data; in close_slaves()
158 static int open_slave(AVFormatContext *avf, char *slave, TeeSlave *tee_slave) in open_slave() argument
172 if ((ret = ff_tee_parse_slave_options(avf, slave, &options, &filename)) < 0) in open_slave()
197 av_log(avf, AV_LOG_ERROR, in open_slave()
204 av_log(avf, AV_LOG_ERROR, "Error parsing fifo options: %s\n", av_err2str(ret)); in open_slave()
237 tee_slave->avf = avf2; in open_slave()
238 av_dict_copy(&avf2->metadata, avf->metadata, 0); in open_slave()
239 avf2->opaque = avf->opaque; in open_slave()
240 avf2->io_open = avf->io_open; in open_slave()
241 avf2->io_close = avf->io_close; in open_slave()
242 avf2->interrupt_callback = avf->interrupt_callback; in open_slave()
243 avf2->flags = avf->flags; in open_slave()
244 avf2->strict_std_compliance = avf->strict_std_compliance; in open_slave()
246 tee_slave->stream_map = av_calloc(avf->nb_streams, sizeof(*tee_slave->stream_map)); in open_slave()
253 for (i = 0; i < avf->nb_streams; i++) { in open_slave()
254 st = avf->streams[i]; in open_slave()
267 ret = avformat_match_stream_specifier(avf, avf->streams[i], subselect); in open_slave()
269 av_log(avf, AV_LOG_ERROR, in open_slave()
300 av_log(avf, AV_LOG_ERROR, "Slave '%s': error opening: %s\n", slave, in open_slave()
306 av_log(avf, AV_LOG_ERROR, "Slave '%s': error writing header: %s\n", in open_slave()
323 av_log(avf, AV_LOG_ERROR, in open_slave()
335 av_log(avf, AV_LOG_ERROR, in open_slave()
342 av_log(avf, AV_LOG_DEBUG, "spec:%s bsfs:%s matches stream %d of slave " in open_slave()
345 av_log(avf, AV_LOG_WARNING, in open_slave()
352 av_log(avf, AV_LOG_ERROR, in open_slave()
363 for (i = 0; i < avf->nb_streams; i++){ in open_slave()
372 av_log(avf, AV_LOG_ERROR, in open_slave()
379 tee_slave->bsfs[target_stream]->time_base_in = avf->streams[i]->time_base; in open_slave()
381 avf->streams[i]->codecpar); in open_slave()
387 av_log(avf, AV_LOG_ERROR, in open_slave()
416 slave->avf->url, slave->avf->oformat->name); in log_slave()
417 for (i = 0; i < slave->avf->nb_streams; i++) { in log_slave()
418 AVStream *st = slave->avf->streams[i]; in log_slave()
432 static int tee_process_slave_failure(AVFormatContext *avf, unsigned slave_idx, int err_n) in tee_process_slave_failure() argument
434 TeeContext *tee = avf->priv_data; in tee_process_slave_failure()
442 av_log(avf, AV_LOG_ERROR, "All tee outputs failed.\n"); in tee_process_slave_failure()
445 av_log(avf, AV_LOG_ERROR, "Slave muxer #%u failed, aborting.\n", slave_idx); in tee_process_slave_failure()
448 av_log(avf, AV_LOG_ERROR, "Slave muxer #%u failed: %s, continuing with %u/%u slaves.\n", in tee_process_slave_failure()
454 static int tee_write_header(AVFormatContext *avf) in tee_write_header() argument
456 TeeContext *tee = avf->priv_data; in tee_write_header()
458 const char *filename = avf->url; in tee_write_header()
490 if ((ret = open_slave(avf, slaves[i], &tee->slaves[i])) < 0) { in tee_write_header()
491 ret = tee_process_slave_failure(avf, i, ret); in tee_write_header()
495 log_slave(&tee->slaves[i], avf, AV_LOG_VERBOSE); in tee_write_header()
500 for (i = 0; i < avf->nb_streams; i++) { in tee_write_header()
503 if (tee->slaves[j].avf) in tee_write_header()
506 av_log(avf, AV_LOG_WARNING, "Input stream #%d is not mapped " in tee_write_header()
515 close_slaves(avf); in tee_write_header()
520 static int tee_write_trailer(AVFormatContext *avf) in tee_write_trailer() argument
522 TeeContext *tee = avf->priv_data; in tee_write_trailer()
528 ret = tee_process_slave_failure(avf, i, ret); in tee_write_trailer()
537 static int tee_write_packet(AVFormatContext *avf, AVPacket *pkt) in tee_write_packet() argument
539 TeeContext *tee = avf->priv_data; in tee_write_packet()
548 if (!(avf2 = tee->slaves[i].avf)) in tee_write_packet()
555 ret = tee_process_slave_failure(avf, i, ret); in tee_write_packet()
577 av_log(avf, AV_LOG_ERROR, "Error while sending packet to bitstream filter: %s\n", in tee_write_packet()
579 ret = tee_process_slave_failure(avf, i, ret); in tee_write_packet()
601 ret = tee_process_slave_failure(avf, i, ret); in tee_write_packet()