Mercurial > libavcodec.hg
comparison mpegvideo_enc.c @ 10368:59ec306245a4 libavcodec
Remove casts that are useless since the argument is void *.
author | reimar |
---|---|
date | Tue, 06 Oct 2009 06:33:18 +0000 |
parents | 30e57cd5d5f5 |
children | 8cf141fae2f3 |
comparison
equal
deleted
inserted
replaced
10367:b790df0d7046 | 10368:59ec306245a4 |
---|---|
2770 if(s->pict_type != FF_I_TYPE){ | 2770 if(s->pict_type != FF_I_TYPE){ |
2771 s->lambda = (s->lambda * s->avctx->me_penalty_compensation + 128)>>8; | 2771 s->lambda = (s->lambda * s->avctx->me_penalty_compensation + 128)>>8; |
2772 s->lambda2= (s->lambda2* (int64_t)s->avctx->me_penalty_compensation + 128)>>8; | 2772 s->lambda2= (s->lambda2* (int64_t)s->avctx->me_penalty_compensation + 128)>>8; |
2773 if(s->pict_type != FF_B_TYPE && s->avctx->me_threshold==0){ | 2773 if(s->pict_type != FF_B_TYPE && s->avctx->me_threshold==0){ |
2774 if((s->avctx->pre_me && s->last_non_b_pict_type==FF_I_TYPE) || s->avctx->pre_me==2){ | 2774 if((s->avctx->pre_me && s->last_non_b_pict_type==FF_I_TYPE) || s->avctx->pre_me==2){ |
2775 s->avctx->execute(s->avctx, pre_estimate_motion_thread, (void**)&(s->thread_context[0]), NULL, s->avctx->thread_count, sizeof(void*)); | 2775 s->avctx->execute(s->avctx, pre_estimate_motion_thread, &s->thread_context[0], NULL, s->avctx->thread_count, sizeof(void*)); |
2776 } | 2776 } |
2777 } | 2777 } |
2778 | 2778 |
2779 s->avctx->execute(s->avctx, estimate_motion_thread, (void**)&(s->thread_context[0]), NULL, s->avctx->thread_count, sizeof(void*)); | 2779 s->avctx->execute(s->avctx, estimate_motion_thread, &s->thread_context[0], NULL, s->avctx->thread_count, sizeof(void*)); |
2780 }else /* if(s->pict_type == FF_I_TYPE) */{ | 2780 }else /* if(s->pict_type == FF_I_TYPE) */{ |
2781 /* I-Frame */ | 2781 /* I-Frame */ |
2782 for(i=0; i<s->mb_stride*s->mb_height; i++) | 2782 for(i=0; i<s->mb_stride*s->mb_height; i++) |
2783 s->mb_type[i]= CANDIDATE_MB_TYPE_INTRA; | 2783 s->mb_type[i]= CANDIDATE_MB_TYPE_INTRA; |
2784 | 2784 |
2785 if(!s->fixed_qscale){ | 2785 if(!s->fixed_qscale){ |
2786 /* finding spatial complexity for I-frame rate control */ | 2786 /* finding spatial complexity for I-frame rate control */ |
2787 s->avctx->execute(s->avctx, mb_var_thread, (void**)&(s->thread_context[0]), NULL, s->avctx->thread_count, sizeof(void*)); | 2787 s->avctx->execute(s->avctx, mb_var_thread, &s->thread_context[0], NULL, s->avctx->thread_count, sizeof(void*)); |
2788 } | 2788 } |
2789 } | 2789 } |
2790 for(i=1; i<s->avctx->thread_count; i++){ | 2790 for(i=1; i<s->avctx->thread_count; i++){ |
2791 merge_context_after_me(s, s->thread_context[i]); | 2791 merge_context_after_me(s, s->thread_context[i]); |
2792 } | 2792 } |
2922 s->header_bits= bits - s->last_bits; | 2922 s->header_bits= bits - s->last_bits; |
2923 | 2923 |
2924 for(i=1; i<s->avctx->thread_count; i++){ | 2924 for(i=1; i<s->avctx->thread_count; i++){ |
2925 update_duplicate_context_after_me(s->thread_context[i], s); | 2925 update_duplicate_context_after_me(s->thread_context[i], s); |
2926 } | 2926 } |
2927 s->avctx->execute(s->avctx, encode_thread, (void**)&(s->thread_context[0]), NULL, s->avctx->thread_count, sizeof(void*)); | 2927 s->avctx->execute(s->avctx, encode_thread, &s->thread_context[0], NULL, s->avctx->thread_count, sizeof(void*)); |
2928 for(i=1; i<s->avctx->thread_count; i++){ | 2928 for(i=1; i<s->avctx->thread_count; i++){ |
2929 merge_context_after_encode(s, s->thread_context[i]); | 2929 merge_context_after_encode(s, s->thread_context[i]); |
2930 } | 2930 } |
2931 emms_c(); | 2931 emms_c(); |
2932 return 0; | 2932 return 0; |