Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(343)

Side by Side Diff: core/fxge/skia/fx_skia_device.h

Issue 1865883002: remove agg from skia driver (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | core/fxge/skia/fx_skia_device.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 PDFium Authors. All rights reserved. 1 // Copyright 2014 PDFium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CORE_FXGE_SKIA_FX_SKIA_DEVICE_H_ 5 #ifndef CORE_FXGE_SKIA_FX_SKIA_DEVICE_H_
6 #define CORE_FXGE_SKIA_FX_SKIA_DEVICE_H_ 6 #define CORE_FXGE_SKIA_FX_SKIA_DEVICE_H_
7 7
8 #if defined(_SKIA_SUPPORT_) 8 #if defined(_SKIA_SUPPORT_)
9 9
10 class SkCanvas; 10 class SkCanvas;
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 77
78 FX_BOOL GetClipBox(FX_RECT* pRect) override; 78 FX_BOOL GetClipBox(FX_RECT* pRect) override;
79 79
80 /** Load device buffer into a DIB */ 80 /** Load device buffer into a DIB */
81 FX_BOOL GetDIBits(CFX_DIBitmap* pBitmap, 81 FX_BOOL GetDIBits(CFX_DIBitmap* pBitmap,
82 int left, 82 int left,
83 int top, 83 int top,
84 void* pIccTransform = NULL, 84 void* pIccTransform = NULL,
85 FX_BOOL bDEdge = FALSE) override; 85 FX_BOOL bDEdge = FALSE) override;
86 86
87 CFX_DIBitmap* GetBackDrop() override { return m_pAggDriver->GetBackDrop(); } 87 CFX_DIBitmap* GetBackDrop() override { return m_pOriDevice; }
88 88
89 FX_BOOL SetDIBits(const CFX_DIBSource* pBitmap, 89 FX_BOOL SetDIBits(const CFX_DIBSource* pBitmap,
90 uint32_t color, 90 uint32_t color,
91 const FX_RECT* pSrcRect, 91 const FX_RECT* pSrcRect,
92 int dest_left, 92 int dest_left,
93 int dest_top, 93 int dest_top,
94 int blend_type, 94 int blend_type,
95 int alpha_flag = 0, 95 int alpha_flag = 0,
96 void* pIccTransform = NULL) override; 96 void* pIccTransform = NULL) override;
97 FX_BOOL StretchDIBits(const CFX_DIBSource* pBitmap, 97 FX_BOOL StretchDIBits(const CFX_DIBSource* pBitmap,
(...skipping 28 matching lines...) Expand all
126 FX_FLOAT font_size, 126 FX_FLOAT font_size,
127 uint32_t color, 127 uint32_t color,
128 int alpha_flag = 0, 128 int alpha_flag = 0,
129 void* pIccTransform = NULL) override; 129 void* pIccTransform = NULL) override;
130 130
131 FX_BOOL DrawShading(CPDF_ShadingPattern* pPattern, 131 FX_BOOL DrawShading(CPDF_ShadingPattern* pPattern,
132 CFX_Matrix* pMatrix, 132 CFX_Matrix* pMatrix,
133 int alpha, 133 int alpha,
134 FX_BOOL bAlphaMode) override; 134 FX_BOOL bAlphaMode) override;
135 135
136 virtual uint8_t* GetBuffer() const { return m_pAggDriver->GetBuffer(); } 136 virtual uint8_t* GetBuffer() const { return m_pBitmap->GetBuffer(); }
137 void PaintStroke(SkPaint* spaint, 137 void PaintStroke(SkPaint* spaint,
138 const CFX_GraphStateData* pGraphState, 138 const CFX_GraphStateData* pGraphState,
139 const SkMatrix& matrix); 139 const SkMatrix& matrix);
140 SkPictureRecorder* GetRecorder() const { return m_pRecorder; } 140 SkPictureRecorder* GetRecorder() const { return m_pRecorder; }
141 141
142 private: 142 private:
143 CFX_AggDeviceDriver* m_pAggDriver; 143 CFX_DIBitmap* m_pBitmap;
144 CFX_DIBitmap* m_pOriDevice;
144 SkCanvas* m_pCanvas; 145 SkCanvas* m_pCanvas;
145 SkPictureRecorder* const m_pRecorder; 146 SkPictureRecorder* const m_pRecorder;
146 int m_ditherBits; 147 int m_ditherBits;
148 FX_BOOL m_bRgbByteOrder;
149 FX_BOOL m_bGroupKnockout;
147 }; 150 };
148 #endif // defined(_SKIA_SUPPORT_) 151 #endif // defined(_SKIA_SUPPORT_)
149 152
150 #endif // CORE_FXGE_SKIA_FX_SKIA_DEVICE_H_ 153 #endif // CORE_FXGE_SKIA_FX_SKIA_DEVICE_H_
OLDNEW
« no previous file with comments | « no previous file | core/fxge/skia/fx_skia_device.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698