--- libavcodec/jvdec.c | 26 +++++++++++++------------- libavformat/jvdec.c | 6 +++--- 2 files changed, 16 insertions(+), 16 deletions(-)
diff --git a/libavcodec/jvdec.c b/libavcodec/jvdec.c index 5c86cb5..8a0f595 100644 --- a/libavcodec/jvdec.c +++ b/libavcodec/jvdec.c @@ -62,19 +62,19 @@ static inline void decode2x2(GetBitContext *gb, uint8_t *dst, int linesize) case 1: v[0] = get_bits(gb, 8); for (j = 0; j < 2; j++) - memset(dst + j*linesize, v[0], 2); + memset(dst + j * linesize, v[0], 2); break; case 2: v[0] = get_bits(gb, 8); v[1] = get_bits(gb, 8); for (j = 0; j < 2; j++) for (i = 0; i < 2; i++) - dst[j*linesize + i] = v[get_bits1(gb)]; + dst[j * linesize + i] = v[get_bits1(gb)]; break; case 3: for (j = 0; j < 2; j++) for (i = 0; i < 2; i++) - dst[j*linesize + i] = get_bits(gb, 8); + dst[j * linesize + i] = get_bits(gb, 8); } } @@ -89,22 +89,22 @@ static inline void decode4x4(GetBitContext *gb, uint8_t *dst, int linesize) case 1: v[0] = get_bits(gb, 8); for (j = 0; j < 4; j++) - memset(dst + j*linesize, v[0], 4); + memset(dst + j * linesize, v[0], 4); break; case 2: v[0] = get_bits(gb, 8); v[1] = get_bits(gb, 8); for (j = 2; j >= 0; j -= 2) { for (i = 0; i < 4; i++) - dst[j*linesize + i] = v[get_bits1(gb)]; + dst[j * linesize + i] = v[get_bits1(gb)]; for (i = 0; i < 4; i++) - dst[(j+1)*linesize + i] = v[get_bits1(gb)]; + dst[(j + 1) * linesize + i] = v[get_bits1(gb)]; } break; case 3: for (j = 0; j < 4; j += 2) for (i = 0; i < 4; i += 2) - decode2x2(gb, dst + j*linesize + i, linesize); + decode2x2(gb, dst + j * linesize + i, linesize); } } @@ -124,13 +124,13 @@ static inline void decode8x8(GetBitContext *gb, uint8_t *dst, int linesize, DSPC v[0] = get_bits(gb, 8); v[1] = get_bits(gb, 8); for (j = 7; j >= 0; j--) - for (i = 0; i < 8; i++) - dst[j*linesize + i] = v[get_bits1(gb)]; + for (i = 0; i < 8; i++) + dst[j * linesize + i] = v[get_bits1(gb)]; break; case 3: for (j = 0; j < 8; j += 4) for (i = 0; i < 8; i += 4) - decode4x4(gb, dst + j*linesize + i, linesize); + decode4x4(gb, dst + j * linesize + i, linesize); } } @@ -160,7 +160,7 @@ static int decode_frame(AVCodecContext *avctx, for (j = 0; j < avctx->height; j += 8) for (i = 0; i < avctx->width; i += 8) - decode8x8(&gb, s->frame->data[0] + j*s->frame->linesize[0] + i, + decode8x8(&gb, s->frame->data[0] + j * s->frame->linesize[0] + i, s->frame->linesize[0], &s->dsp); buf += video_size; @@ -168,7 +168,7 @@ static int decode_frame(AVCodecContext *avctx, if (buf + 1 <= buf_end) { int v = *buf++; for (j = 0; j < avctx->height; j++) - memset(s->frame->data[0] + j*s->frame->linesize[0], v, avctx->width); + memset(s->frame->data[0] + j * s->frame->linesize[0], v, avctx->width); } } else { av_log(avctx, AV_LOG_WARNING, "unsupported frame type %i\n", video_type); @@ -188,7 +188,7 @@ static int decode_frame(AVCodecContext *avctx, s->frame->key_frame = 1; s->frame->pict_type = AV_PICTURE_TYPE_I; s->frame->palette_has_changed = s->palette_has_changed; - s->palette_has_changed = 0; + s->palette_has_changed = 0; memcpy(s->frame->data[1], s->palette, AVPALETTE_SIZE); if ((ret = av_frame_ref(data, s->frame)) < 0) diff --git a/libavformat/jvdec.c b/libavformat/jvdec.c index cf9df8c..9776b13 100644 --- a/libavformat/jvdec.c +++ b/libavformat/jvdec.c @@ -106,7 +106,7 @@ static int read_header(AVFormatContext *s) return AVERROR(ENOMEM); offset = 0x68 + ast->nb_index_entries * 16; - for(i = 0; i < ast->nb_index_entries; i++) { + for (i = 0; i < ast->nb_index_entries; i++) { AVIndexEntry *e = ast->index_entries + i; JVFrame *jvf = jv->frames + i; @@ -149,7 +149,7 @@ static int read_packet(AVFormatContext *s, AVPacket *pkt) switch(jv->state) { case JV_AUDIO: jv->state++; - if (jvf->audio_size ) { + if (jvf->audio_size) { if (av_get_packet(s->pb, pkt, jvf->audio_size) < 0) return AVERROR(ENOMEM); pkt->stream_index = 0; @@ -197,7 +197,7 @@ static int read_seek(AVFormatContext *s, int stream_index, if (flags & (AVSEEK_FLAG_BYTE|AVSEEK_FLAG_FRAME)) return AVERROR(ENOSYS); - switch(stream_index) { + switch (stream_index) { case 0: i = av_index_search_timestamp(ast, ts, flags); break; -- 1.7.9.5 _______________________________________________ libav-devel mailing list libav-devel@libav.org https://lists.libav.org/mailman/listinfo/libav-devel