mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Backout patch from bug 389366 because it does not have M9 approval.
This commit is contained in:
parent
59c9ec8400
commit
d69579e8aa
@ -2465,13 +2465,6 @@ nsCanvasRenderingContext2D::GetImageData()
|
||||
PRUint8 g = *row++;
|
||||
PRUint8 b = *row++;
|
||||
#endif
|
||||
// Convert to non-premultiplied color
|
||||
if (a != 0) {
|
||||
r = (r * 255) / a;
|
||||
g = (g * 255) / a;
|
||||
b = (b * 255) / a;
|
||||
}
|
||||
|
||||
*dest++ = INT_TO_JSVAL(r);
|
||||
*dest++ = INT_TO_JSVAL(g);
|
||||
*dest++ = INT_TO_JSVAL(b);
|
||||
@ -2595,11 +2588,6 @@ nsCanvasRenderingContext2D::PutImageData()
|
||||
else if (JSVAL_IS_DOUBLE(va)) ia = (PRUint8) (*JSVAL_TO_DOUBLE(va));
|
||||
else return NS_ERROR_DOM_SYNTAX_ERR;
|
||||
|
||||
// Convert to premultiplied color (losslessly if the input came from getImageData)
|
||||
ir = (ir*ia + 254) / 255;
|
||||
ig = (ig*ia + 254) / 255;
|
||||
ib = (ib*ia + 254) / 255;
|
||||
|
||||
#ifdef IS_LITTLE_ENDIAN
|
||||
*imgPtr++ = ib;
|
||||
*imgPtr++ = ig;
|
||||
|
Loading…
Reference in New Issue
Block a user