diff options
author | Tom Sepez <tsepez@chromium.org> | 2018-08-10 00:13:37 +0000 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2018-08-10 00:13:37 +0000 |
commit | 4174b5ab6ac9024acb9b42acbb61d628a2a679e3 (patch) | |
tree | 0d73f6ad6d85fd7fead7fdc6ddfc647479511bcd /core/fxcodec/codec/ccodec_tiffmodule.cpp | |
parent | fd7cede17e027a83de2aff3bc0f5ee875271e444 (diff) | |
download | pdfium-4174b5ab6ac9024acb9b42acbb61d628a2a679e3.tar.xz |
Add CFX_DIBSource::GetWritableScanline().
Remove a bunch of const_cast<uint8_t*> or equivalent. This will also
help when we convert to span<>, since casting spans is a nuisance.
Change-Id: I330e5041cbaf33a84425fc4242a3dfacf5ca8011
Reviewed-on: https://pdfium-review.googlesource.com/39831
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
Diffstat (limited to 'core/fxcodec/codec/ccodec_tiffmodule.cpp')
-rw-r--r-- | core/fxcodec/codec/ccodec_tiffmodule.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/fxcodec/codec/ccodec_tiffmodule.cpp b/core/fxcodec/codec/ccodec_tiffmodule.cpp index 1a7a51af80..5f74b28cdc 100644 --- a/core/fxcodec/codec/ccodec_tiffmodule.cpp +++ b/core/fxcodec/codec/ccodec_tiffmodule.cpp @@ -463,7 +463,7 @@ bool CTiffContext::Decode(const RetainPtr<CFX_DIBitmap>& pDIBitmap) { (uint32*)pDIBitmap->GetBuffer(), rotation, 1)) { for (uint32_t row = 0; row < img_height; row++) { - uint8_t* row_buf = (uint8_t*)pDIBitmap->GetScanline(row); + uint8_t* row_buf = pDIBitmap->GetWritableScanline(row); TiffBGRA2RGBA(row_buf, img_width, 4); } return true; |