Lines Matching defs:ast

67  * @param ast video stream of which to change parameters
72 AVStream *ast, int myth)
110 if (ast) {
113 ast->codecpar->codec_tag = avio_rl32(pb);
114 ast->codecpar->sample_rate = avio_rl32(pb);
115 if (ast->codecpar->sample_rate <= 0) {
116 av_log(s, AV_LOG_ERROR, "Invalid sample rate %d\n", ast->codecpar->sample_rate);
119 ast->codecpar->bits_per_coded_sample = avio_rl32(pb);
120 av_channel_layout_uninit(&ast->codecpar->ch_layout);
121 ast->codecpar->ch_layout.order = AV_CHANNEL_ORDER_UNSPEC;
122 ast->codecpar->ch_layout.nb_channels = avio_rl32(pb);
123 if (ast->codecpar->ch_layout.nb_channels <= 0) {
124 av_log(s, AV_LOG_ERROR, "Invalid channels %d\n", ast->codecpar->ch_layout.nb_channels);
128 id = ff_wav_codec_get_id(ast->codecpar->codec_tag,
129 ast->codecpar->bits_per_coded_sample);
131 id = ff_codec_get_id(nuv_audio_tags, ast->codecpar->codec_tag);
133 id = ff_get_pcm_codec_id(ast->codecpar->bits_per_coded_sample,
136 ast->codecpar->codec_id = id;
138 ffstream(ast)->need_parsing = AVSTREAM_PARSE_FULL;
166 AVStream *vst = NULL, *ast = NULL;
225 ast = avformat_new_stream(s, NULL);
226 if (!ast)
228 ctx->a_id = ast->index;
230 ast->codecpar->codec_type = AVMEDIA_TYPE_AUDIO;
231 ast->codecpar->codec_id = AV_CODEC_ID_PCM_S16LE;
232 ast->codecpar->ch_layout = (AVChannelLayout)AV_CHANNEL_LAYOUT_STEREO;
233 ast->codecpar->sample_rate = 44100;
234 ast->codecpar->bit_rate = 2 * 2 * 44100 * 8;
235 ast->codecpar->block_align = 2 * 2;
236 ast->codecpar->bits_per_coded_sample = 16;
237 avpriv_set_pts_info(ast, 32, 1, 1000);
241 if ((ret = get_codec_data(s, pb, vst, ast, is_mythtv)) < 0)