mkstemp
mm_empty
mmap
+ mprotect
msvcrt
nanosleep
+ PeekNamedPipe
+ perl
+ pod2man
poll_h
posix_memalign
+ pthread_cancel
rdtsc
rint
round
/* initialise offset */
switch (s->internal_ftype)
{
+ case TYPE_U8:
+ s->avctx->sample_fmt = AV_SAMPLE_FMT_U8;
+ mean = 0x80;
+ break;
case TYPE_S16HL:
case TYPE_S16LH:
- s->avctx->sample_fmt = AV_SAMPLE_FMT_S16;
- mean = 0;
++ s->avctx->sample_fmt = AV_SAMPLE_FMT_S16P;
break;
default:
- av_log(s->avctx, AV_LOG_ERROR, "unknown audio type");
+ av_log(s->avctx, AV_LOG_ERROR, "unknown audio type\n");
return AVERROR_INVALIDDATA;
}
av_log(avctx, AV_LOG_ERROR, "get_buffer() failed\n");
return ret;
}
- samples_u8 = (uint8_t *)s->frame.data[0];
- samples_s16 = (int16_t *)s->frame.data[0];
-- /* interleave output */
- for (i = 0; i < s->blocksize; i++) {
- for (chan = 0; chan < s->channels; chan++) {
- output_buffer((int16_t **)s->frame.extended_data, s->channels,
- s->blocksize, s->decoded);
++
++ for (chan = 0; chan < s->channels; chan++) {
++ samples_u8 = ((uint8_t **)s->frame.extended_data)[chan];
++ samples_s16 = ((int16_t **)s->frame.extended_data)[chan];
++ for (i = 0; i < s->blocksize; i++) {
+ switch (s->internal_ftype) {
+ case TYPE_U8:
+ *samples_u8++ = av_clip_uint8(s->decoded[chan][i]);
+ break;
+ case TYPE_S16HL:
+ case TYPE_S16LH:
+ *samples_s16++ = av_clip_int16(s->decoded[chan][i]);
+ break;
+ }
+ }
+ }
+
+
*got_frame_ptr = 1;
*(AVFrame *)data = s->frame;
}
.flush = flush,
.capabilities = CODEC_CAP_DR1,
.long_name = NULL_IF_CONFIG_SMALL("Windows Media Audio 1"),
+ .sample_fmts = (const enum AVSampleFormat[]) { AV_SAMPLE_FMT_FLTP,
+ AV_SAMPLE_FMT_NONE },
};
-
+#endif
+#if CONFIG_WMAV2_DECODER
AVCodec ff_wmav2_decoder = {
.name = "wmav2",
.type = AVMEDIA_TYPE_AUDIO,
.flush = flush,
.capabilities = CODEC_CAP_DR1,
.long_name = NULL_IF_CONFIG_SMALL("Windows Media Audio 2"),
+ .sample_fmts = (const enum AVSampleFormat[]) { AV_SAMPLE_FMT_FLTP,
+ AV_SAMPLE_FMT_NONE },
};
+#endif
FF_ALLOCZ_OR_GOTO(c, c->hLumFilterPos, (dstW / 2 / 8 + 8) * sizeof(int32_t), fail);
FF_ALLOCZ_OR_GOTO(c, c->hChrFilterPos, (c->chrDstW / 2 / 4 + 8) * sizeof(int32_t), fail);
- initMMX2HScaler(dstW, c->lumXInc, c->lumMmx2FilterCode,
- c->hLumFilter, c->hLumFilterPos, 8);
+ initMMX2HScaler( dstW, c->lumXInc, c->lumMmx2FilterCode,
+ c->hLumFilter, (uint32_t*)c->hLumFilterPos, 8);
initMMX2HScaler(c->chrDstW, c->chrXInc, c->chrMmx2FilterCode,
- c->hChrFilter, c->hChrFilterPos, 4);
+ c->hChrFilter, (uint32_t*)c->hChrFilterPos, 4);
- #ifdef MAP_ANONYMOUS
+ #if USE_MMAP
mprotect(c->lumMmx2FilterCode, c->lumMmx2FilterCodeSize, PROT_EXEC | PROT_READ);
mprotect(c->chrMmx2FilterCode, c->chrMmx2FilterCodeSize, PROT_EXEC | PROT_READ);
#endif