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

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

Issue 2059883004: Remove default arguments from IFX_RenderDeviceDriver. (Closed) Base URL: https://pdfium.googlesource.com/pdfium@master
Patch Set: rebase Created 4 years, 6 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 | « core/fxge/include/fx_ge.h ('k') | 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 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
45 pGraphState) // graphic state, for pen attributes 45 pGraphState) // graphic state, for pen attributes
46 override; 46 override;
47 47
48 /** Draw a path */ 48 /** Draw a path */
49 FX_BOOL DrawPath(const CFX_PathData* pPathData, 49 FX_BOOL DrawPath(const CFX_PathData* pPathData,
50 const CFX_Matrix* pObject2Device, 50 const CFX_Matrix* pObject2Device,
51 const CFX_GraphStateData* pGraphState, 51 const CFX_GraphStateData* pGraphState,
52 uint32_t fill_color, 52 uint32_t fill_color,
53 uint32_t stroke_color, 53 uint32_t stroke_color,
54 int fill_mode, 54 int fill_mode,
55 int alpha_flag = 0, 55 int blend_type) override;
56 void* pIccTransform = nullptr,
57 int blend_type = FXDIB_BLEND_NORMAL) override;
58 56
59 FX_BOOL FillRect(const FX_RECT* pRect, 57 FX_BOOL FillRectWithBlend(const FX_RECT* pRect,
60 uint32_t fill_color, 58 uint32_t fill_color,
61 int alpha_flag = 0, 59 int blend_type) override;
62 void* pIccTransform = nullptr,
63 int blend_type = FXDIB_BLEND_NORMAL) override;
64 60
65 /** Draw a single pixel (device dependant) line */ 61 /** Draw a single pixel (device dependant) line */
66 FX_BOOL DrawCosmeticLine(FX_FLOAT x1, 62 FX_BOOL DrawCosmeticLine(FX_FLOAT x1,
67 FX_FLOAT y1, 63 FX_FLOAT y1,
68 FX_FLOAT x2, 64 FX_FLOAT x2,
69 FX_FLOAT y2, 65 FX_FLOAT y2,
70 uint32_t color, 66 uint32_t color,
71 int alpha_flag = 0, 67 int blend_type) override {
72 void* pIccTransform = nullptr,
73 int blend_type = FXDIB_BLEND_NORMAL) override {
74 return FALSE; 68 return FALSE;
75 } 69 }
76 70
77 FX_BOOL GetClipBox(FX_RECT* pRect) override; 71 FX_BOOL GetClipBox(FX_RECT* pRect) override;
78 72
79 /** Load device buffer into a DIB */ 73 /** Load device buffer into a DIB */
80 FX_BOOL GetDIBits(CFX_DIBitmap* pBitmap, 74 FX_BOOL GetDIBits(CFX_DIBitmap* pBitmap, int left, int top) override;
81 int left,
82 int top,
83 void* pIccTransform = nullptr,
84 FX_BOOL bDEdge = FALSE) override;
85 75
86 CFX_DIBitmap* GetBackDrop() override { return m_pOriDevice; } 76 CFX_DIBitmap* GetBackDrop() override { return m_pOriDevice; }
87 77
88 FX_BOOL SetDIBits(const CFX_DIBSource* pBitmap, 78 FX_BOOL SetDIBits(const CFX_DIBSource* pBitmap,
89 uint32_t color, 79 uint32_t color,
90 const FX_RECT* pSrcRect, 80 const FX_RECT* pSrcRect,
91 int dest_left, 81 int dest_left,
92 int dest_top, 82 int dest_top,
93 int blend_type, 83 int blend_type) override;
94 int alpha_flag = 0,
95 void* pIccTransform = nullptr) override;
96 FX_BOOL StretchDIBits(const CFX_DIBSource* pBitmap, 84 FX_BOOL StretchDIBits(const CFX_DIBSource* pBitmap,
97 uint32_t color, 85 uint32_t color,
98 int dest_left, 86 int dest_left,
99 int dest_top, 87 int dest_top,
100 int dest_width, 88 int dest_width,
101 int dest_height, 89 int dest_height,
102 const FX_RECT* pClipRect, 90 const FX_RECT* pClipRect,
103 uint32_t flags, 91 uint32_t flags,
104 int alpha_flag = 0, 92 int blend_type) override;
105 void* pIccTransform = nullptr,
106 int blend_type = FXDIB_BLEND_NORMAL) override;
107 93
108 FX_BOOL StartDIBits(const CFX_DIBSource* pBitmap, 94 FX_BOOL StartDIBits(const CFX_DIBSource* pBitmap,
109 int bitmap_alpha, 95 int bitmap_alpha,
110 uint32_t color, 96 uint32_t color,
111 const CFX_Matrix* pMatrix, 97 const CFX_Matrix* pMatrix,
112 uint32_t flags, 98 uint32_t flags,
113 void*& handle, 99 void*& handle,
114 int alpha_flag = 0, 100 int blend_type) override;
115 void* pIccTransform = nullptr,
116 int blend_type = FXDIB_BLEND_NORMAL) override;
117 101
118 FX_BOOL ContinueDIBits(void* handle, IFX_Pause* pPause) override { 102 FX_BOOL ContinueDIBits(void* handle, IFX_Pause* pPause) override {
119 return FALSE; 103 return FALSE;
120 } 104 }
121 105
122 void CancelDIBits(void* handle) override {} 106 void CancelDIBits(void* handle) override {}
123 107
124 FX_BOOL DrawDeviceText(int nChars, 108 FX_BOOL DrawDeviceText(int nChars,
125 const FXTEXT_CHARPOS* pCharPos, 109 const FXTEXT_CHARPOS* pCharPos,
126 CFX_Font* pFont, 110 CFX_Font* pFont,
127 CFX_FontCache* pCache, 111 CFX_FontCache* pCache,
128 const CFX_Matrix* pObject2Device, 112 const CFX_Matrix* pObject2Device,
129 FX_FLOAT font_size, 113 FX_FLOAT font_size,
130 uint32_t color, 114 uint32_t color) override;
131 int alpha_flag = 0,
132 void* pIccTransform = nullptr) override;
133 115
134 FX_BOOL DrawShading(const CPDF_ShadingPattern* pPattern, 116 FX_BOOL DrawShading(const CPDF_ShadingPattern* pPattern,
135 const CFX_Matrix* pMatrix, 117 const CFX_Matrix* pMatrix,
136 const FX_RECT& clip_rect, 118 const FX_RECT& clip_rect,
137 int alpha, 119 int alpha,
138 FX_BOOL bAlphaMode) override; 120 FX_BOOL bAlphaMode) override;
139 121
140 virtual uint8_t* GetBuffer() const { return m_pBitmap->GetBuffer(); } 122 virtual uint8_t* GetBuffer() const { return m_pBitmap->GetBuffer(); }
141 void PaintStroke(SkPaint* spaint, 123 void PaintStroke(SkPaint* spaint,
142 const CFX_GraphStateData* pGraphState, 124 const CFX_GraphStateData* pGraphState,
143 const SkMatrix& matrix); 125 const SkMatrix& matrix);
144 SkPictureRecorder* GetRecorder() const { return m_pRecorder; } 126 SkPictureRecorder* GetRecorder() const { return m_pRecorder; }
145 void PreMultiply(); 127 void PreMultiply();
146 128
147 private: 129 private:
148 CFX_DIBitmap* m_pBitmap; 130 CFX_DIBitmap* m_pBitmap;
149 CFX_DIBitmap* m_pOriDevice; 131 CFX_DIBitmap* m_pOriDevice;
150 SkCanvas* m_pCanvas; 132 SkCanvas* m_pCanvas;
151 SkPictureRecorder* const m_pRecorder; 133 SkPictureRecorder* const m_pRecorder;
152 FX_BOOL m_bRgbByteOrder; 134 FX_BOOL m_bRgbByteOrder;
153 FX_BOOL m_bGroupKnockout; 135 FX_BOOL m_bGroupKnockout;
154 }; 136 };
155 #endif // defined(_SKIA_SUPPORT_) 137 #endif // defined(_SKIA_SUPPORT_)
156 138
157 #endif // CORE_FXGE_SKIA_FX_SKIA_DEVICE_H_ 139 #endif // CORE_FXGE_SKIA_FX_SKIA_DEVICE_H_
OLDNEW
« no previous file with comments | « core/fxge/include/fx_ge.h ('k') | core/fxge/skia/fx_skia_device.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698