WIP: Fixing unsafe threading in VP8 encoder. Use the passed in macroblock instead of the macroblock located in cpi.
Unified · Split
| @@ -1234,8 +1234,8 @@ int vp8cx_encode_inter_macroblock · 1233 unmodified lines | |||
| 1234 | /* Are we using the fast quantizer for the mode selection? */ | 1234 | /* Are we using the fast quantizer for the mode selection? */ |
| 1235 | if(cpi->sf.use_fastquant_for_pick) | 1235 | if(cpi->sf.use_fastquant_for_pick) |
| 1236 | { | 1236 | { |
| 1237 | cpi->mb.quantize_b = vp8_fast_quantize_b; | 1237 | x->quantize_b = vp8_fast_quantize_b; |
| 1238 | cpi->mb.quantize_b_pair = vp8_fast_quantize_b_pair; | 1238 | x->quantize_b_pair = vp8_fast_quantize_b_pair; |
| 1239 | 1239 | ||
| 1240 | /* the fast quantizer does not use zbin_extra, so | 1240 | /* the fast quantizer does not use zbin_extra, so |
| 1241 | * do not recalculate */ | 1241 | * do not recalculate */ |
| @@ -1247,8 +1247,8 @@ int vp8cx_encode_inter_macroblock · 5 unmodified lines | |||
| 1247 | /* switch back to the regular quantizer for the encode */ | 1247 | /* switch back to the regular quantizer for the encode */ |
| 1248 | if (cpi->sf.improved_quant) | 1248 | if (cpi->sf.improved_quant) |
| 1249 | { | 1249 | { |
| 1250 | cpi->mb.quantize_b = vp8_regular_quantize_b; | 1250 | x->quantize_b = vp8_regular_quantize_b; |
| 1251 | cpi->mb.quantize_b_pair = vp8_regular_quantize_b_pair; | 1251 | x->quantize_b_pair = vp8_regular_quantize_b_pair; |
| 1252 | } | 1252 | } |
| 1253 | 1253 | ||
| 1254 | /* restore cpi->zbin_mode_boost_enabled */ | 1254 | /* restore cpi->zbin_mode_boost_enabled */ |