summaryrefslogtreecommitdiff
path: root/core/fxge/fx_dib.h
diff options
context:
space:
mode:
authorLei Zhang <thestig@chromium.org>2018-03-15 15:06:11 +0000
committerChromium commit bot <commit-bot@chromium.org>2018-03-15 15:06:11 +0000
commitc2d9e2d00ee871fa538bc46c8209e98ab9a30c44 (patch)
treee2d97c232971510f74bbf1a6d6e25045592c56b4 /core/fxge/fx_dib.h
parent9875889910585b08d2abd372ddc95469baf1a7e9 (diff)
downloadpdfium-c2d9e2d00ee871fa538bc46c8209e98ab9a30c44.tar.xz
Rename FX_COLORREF variables from "rgb" to "bgr".
FX_COLORREF should work like win32 COLORREF, which is BGR. Change-Id: I9f8bb3e2d30a64dc822ac6b8c46130358a03678a Reviewed-on: https://pdfium-review.googlesource.com/28574 Commit-Queue: Ryan Harrison <rharrison@chromium.org> Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Diffstat (limited to 'core/fxge/fx_dib.h')
-rw-r--r--core/fxge/fx_dib.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/core/fxge/fx_dib.h b/core/fxge/fx_dib.h
index f7626afd35..8134c5066d 100644
--- a/core/fxge/fx_dib.h
+++ b/core/fxge/fx_dib.h
@@ -70,7 +70,9 @@ extern const int16_t SDP_Table[513];
#define FXDIB_BLEND_LUMINOSITY 24
#define FXDIB_BLEND_UNSUPPORTED -1
+// TODO(thestig): Rename to FXSYS_BGR() and check callers.
#define FXSYS_RGB(r, g, b) ((r) | ((g) << 8) | ((b) << 16))
+// TODO(thestig): Rename parameter to |bgr| and check callers.
#define FXSYS_GetRValue(rgb) ((rgb)&0xff)
#define FXSYS_GetGValue(rgb) (((rgb) >> 8) & 0xff)
#define FXSYS_GetBValue(rgb) (((rgb) >> 16) & 0xff)
@@ -93,7 +95,8 @@ std::pair<int, FX_COLORREF> ArgbToColorRef(FX_ARGB argb);
inline FX_ARGB ArgbEncode(int a, int r, int g, int b) {
return (a << 24) | (r << 16) | (g << 8) | b;
}
-FX_ARGB ArgbEncode(int a, FX_COLORREF rgb);
+// TODO(thestig): Rename to AlphaAndColorRefToArgb().
+FX_ARGB ArgbEncode(int a, FX_COLORREF bgr);
FX_ARGB StringToFXARGB(const WideStringView& view);