Affected every usage of this filter; in particular, it affected the FATE-tests filter-2xbr, filter-3xbr and filter-4xbr.
Showing the changes to libavfilter (1 of 1 file). Show all
Unified · Split
| @@ -523,7 +523,7 @@ static av_cold int init(AVFilterContext *ctx) · 522 unmodified lines | |||
| 523 | int startg = FFMAX3(-bg, -rg, 0); | 523 | int startg = FFMAX3(-bg, -rg, 0); |
| 524 | int endg = FFMIN3(255-bg, 255-rg, 255); | 524 | int endg = FFMIN3(255-bg, 255-rg, 255); |
| 525 | uint32_t y = (uint32_t)(( 299*rg + 1000*startg + 114*bg)/1000); | 525 | uint32_t y = (uint32_t)(( 299*rg + 1000*startg + 114*bg)/1000); |
| 526 | c = bg + (rg<<16) + 0x010101 * startg; | 526 | c = bg + rg * (1 << 16) + 0x010101 * startg; |
| 527 | for (g = startg; g <= endg; g++) { | 527 | for (g = startg; g <= endg; g++) { |
| 528 | hqx->rgbtoyuv[c] = ((y++) << 16) + (u << 8) + v; | 528 | hqx->rgbtoyuv[c] = ((y++) << 16) + (u << 8) + v; |
| 529 | c+= 0x010101; | 529 | c+= 0x010101; |