Commit f38e7566 authored by Clément Bœsch's avatar Clément Bœsch

Merge commit 'c00a11ab'

* commit 'c00a11ab':
  examples/encode_audio: constify AVCodec instances
Merged-by: 's avatarClément Bœsch <u@pkh.me>
parents b785af48 c00a11ab
......@@ -39,7 +39,7 @@
#include "libavutil/samplefmt.h"
/* check that a given sample format is supported by the encoder */
static int check_sample_fmt(AVCodec *codec, enum AVSampleFormat sample_fmt)
static int check_sample_fmt(const AVCodec *codec, enum AVSampleFormat sample_fmt)
{
const enum AVSampleFormat *p = codec->sample_fmts;
......@@ -52,7 +52,7 @@ static int check_sample_fmt(AVCodec *codec, enum AVSampleFormat sample_fmt)
}
/* just pick the highest supported samplerate */
static int select_sample_rate(AVCodec *codec)
static int select_sample_rate(const AVCodec *codec)
{
const int *p;
int best_samplerate = 0;
......@@ -69,7 +69,7 @@ static int select_sample_rate(AVCodec *codec)
}
/* select layout with the highest channel count */
static int select_channel_layout(AVCodec *codec)
static int select_channel_layout(const AVCodec *codec)
{
const uint64_t *p;
uint64_t best_ch_layout = 0;
......@@ -94,7 +94,7 @@ static int select_channel_layout(AVCodec *codec)
int main(int argc, char **argv)
{
const char *filename;
AVCodec *codec;
const AVCodec *codec;
AVCodecContext *c= NULL;
AVFrame *frame;
AVPacket pkt;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment