зеркало из https://github.com/mozilla/moz-skia.git
[PDF] Fix image references.
Chrome doesn't seem to honor the reference to the pixel ref. A copy is necessary for unpremultiplication anyway, so pull that part in now. BUG=chromium:279640 R=reed@google.com Author: vandebo@chromium.org Review URL: https://chromiumcodereview.appspot.com/23730003 git-svn-id: http://skia.googlecode.com/svn/trunk@11014 2bbb7eff-a529-9590-31e7-b0007b416f81
This commit is contained in:
Родитель
5587ac09be
Коммит
06822ea872
|
@ -391,11 +391,17 @@ SkPDFImage::SkPDFImage(SkStream* stream,
|
|||
bool isAlpha,
|
||||
const SkIRect& srcRect,
|
||||
EncodeToDCTStream encoder)
|
||||
: fBitmap(bitmap),
|
||||
fIsAlpha(isAlpha),
|
||||
: fIsAlpha(isAlpha),
|
||||
fSrcRect(srcRect),
|
||||
fEncoder(encoder) {
|
||||
|
||||
if (bitmap.isImmutable()) {
|
||||
fBitmap = bitmap;
|
||||
} else {
|
||||
bitmap.deepCopyTo(&fBitmap, bitmap.config());
|
||||
fBitmap.setImmutable();
|
||||
}
|
||||
|
||||
if (stream != NULL) {
|
||||
setData(stream);
|
||||
fStreamValid = true;
|
||||
|
|
Загрузка…
Ссылка в новой задаче