OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (c) 2008, 2009, Google Inc. All rights reserved. | 2 * Copyright (c) 2008, 2009, Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 337 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
348 | 348 |
349 // The coordinate to which we've decoded the image. | 349 // The coordinate to which we've decoded the image. |
350 IntPoint m_coord; | 350 IntPoint m_coord; |
351 | 351 |
352 // Variables that track whether we've seen pixels with alpha values != 0 | 352 // Variables that track whether we've seen pixels with alpha values != 0 |
353 // and == 0, respectively. See comments in processNonRLEData() on how | 353 // and == 0, respectively. See comments in processNonRLEData() on how |
354 // these are used. | 354 // these are used. |
355 bool m_seenNonZeroAlphaPixel; | 355 bool m_seenNonZeroAlphaPixel; |
356 bool m_seenZeroAlphaPixel; | 356 bool m_seenZeroAlphaPixel; |
357 | 357 |
358 // Variables m_seenNonZeroAlphaPixel and m_seenZeroAlphaPixel are tracking | |
359 // values used for alpha channel. m_hasPixelsWithAlpha tracks if decoding | |
360 // saw pixels that are transparent. | |
scroggo_chromium
2016/05/16 20:32:08
I think this comment is confusing. It describes th
aleksandar.stojiljkovic
2016/05/22 15:41:53
reverted the code.
| |
361 bool m_hasPixelsWithAlpha; | |
362 | |
358 // BMPs-in-ICOs have a few differences from standalone BMPs, so we need to | 363 // BMPs-in-ICOs have a few differences from standalone BMPs, so we need to |
359 // know if we're in an ICO container. | 364 // know if we're in an ICO container. |
360 bool m_isInICO; | 365 bool m_isInICO; |
361 | 366 |
362 // ICOs store a 1bpp "mask" immediately after the main bitmap image data | 367 // ICOs store a 1bpp "mask" immediately after the main bitmap image data |
363 // (and, confusingly, add its height to the biHeight value in the info | 368 // (and, confusingly, add its height to the biHeight value in the info |
364 // header, thus doubling it). If |m_isInICO| is true, this variable tracks | 369 // header, thus doubling it). If |m_isInICO| is true, this variable tracks |
365 // whether we've begun decoding this mask yet. | 370 // whether we've begun decoding this mask yet. |
366 bool m_decodingAndMask; | 371 bool m_decodingAndMask; |
367 }; | 372 }; |
368 | 373 |
369 } // namespace blink | 374 } // namespace blink |
370 | 375 |
371 #endif | 376 #endif |
OLD | NEW |