MCPcopy Create free account
hub / github.com/FFmpeg/FFmpeg / open_parser

Function open_parser

ffserver.c:2115–2128  ·  view source on GitHub ↗

check if the parser needs to be opened for stream i */

Source from the content-addressed store, hash-verified

2113
2114/* check if the parser needs to be opened for stream i */
2115static void open_parser(AVFormatContext *s, int i)
2116{
2117 AVStream *st = s->streams[i];
2118 AVCodec *codec;
2119
2120 if (!st->codec->codec) {
2121 codec = avcodec_find_decoder(st->codec->codec_id);
2122 if (codec && (codec->capabilities & CODEC_CAP_PARSE_ONLY)) {
2123 st->codec->parse_only = 1;
2124 if (avcodec_open(st->codec, codec) < 0)
2125 st->codec->parse_only = 0;
2126 }
2127 }
2128}
2129
2130static int open_input_stream(HTTPContext *c, const char *info)
2131{

Callers 1

open_input_streamFunction · 0.85

Calls 2

avcodec_find_decoderFunction · 0.85
avcodec_openFunction · 0.85

Tested by

no test coverage detected