X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavformat%2Fircamdec.c;h=a05ca5c9c71a3848caa9a3ac630d723c7a8f01f0;hb=bc70684e74a185d7b80c8b80bdedda659cb581b8;hp=d376ffef63fe2d726ceed4aba5ab2917a5cb0165;hpb=03210fe138f3b3bd7f5272fe29aca810cf517329;p=ffmpeg diff --git a/libavformat/ircamdec.c b/libavformat/ircamdec.c index d376ffef63f..a05ca5c9c71 100644 --- a/libavformat/ircamdec.c +++ b/libavformat/ircamdec.c @@ -26,7 +26,7 @@ #include "pcm.h" #include "ircam.h" -static int ircam_probe(AVProbeData *p) +static int ircam_probe(const AVProbeData *p) { if ((p->buf[0] == 0x64 && p->buf[1] == 0xA3 && p->buf[3] == 0x00 && p->buf[2] >= 1 && p->buf[2] <= 4) || @@ -66,12 +66,12 @@ static int ircam_read_header(AVFormatContext *s) } if (le == 1) { - sample_rate = av_int2float(avio_rl32(s->pb)); + sample_rate = lrintf(av_int2float(avio_rl32(s->pb))); channels = avio_rl32(s->pb); tag = avio_rl32(s->pb); tags = ff_codec_ircam_le_tags; } else if (le == 0) { - sample_rate = av_int2float(avio_rb32(s->pb)); + sample_rate = lrintf(av_int2float(avio_rb32(s->pb))); channels = avio_rb32(s->pb); tag = avio_rb32(s->pb); tags = ff_codec_ircam_be_tags; @@ -106,7 +106,7 @@ static int ircam_read_header(AVFormatContext *s) return 0; } -AVInputFormat ff_ircam_demuxer = { +const AVInputFormat ff_ircam_demuxer = { .name = "ircam", .long_name = NULL_IF_CONFIG_SMALL("Berkeley/IRCAM/CARL Sound Format"), .read_probe = ircam_probe,