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

Unified Diff: tools/PictureRenderingFlags.cpp

Issue 1306823003: skia: add ability to load command_buffer_gles2 (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: and NULL->nullptr, just because. Created 5 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/PictureRenderer.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/PictureRenderingFlags.cpp
diff --git a/tools/PictureRenderingFlags.cpp b/tools/PictureRenderingFlags.cpp
index b0456baa8260ba2755623eca2e542fa3e8d39f0e..ea316843a9429c590902d189df8a5e665a57343d 100644
--- a/tools/PictureRenderingFlags.cpp
+++ b/tools/PictureRenderingFlags.cpp
@@ -42,6 +42,11 @@ static const char kGpuAPINameGLES[] = "gles";
#else
#define ANGLE_CONFIG_STRING ""
#endif
+#if SK_COMMAND_BUFFER
+#define COMMAND_BUFFER_CONFIG_STRING "|commandbuffer"
+#else
+#define COMMAND_BUFFER_CONFIG_STRING ""
+#endif
#if SK_MESA
#define MESA_CONFIG_STRING "|mesa"
#else
@@ -51,7 +56,7 @@ static const char kGpuAPINameGLES[] = "gles";
// Although this config does not support all the same options as gm, the names should be kept
// consistent.
DEFINE_string(config, "8888", "["
- "8888" GPU_CONFIG_STRING ANGLE_CONFIG_STRING MESA_CONFIG_STRING
+ "8888" GPU_CONFIG_STRING ANGLE_CONFIG_STRING COMMAND_BUFFER_CONFIG_STRING MESA_CONFIG_STRING
"]: Use the corresponding config.");
DEFINE_bool(deferImageDecoding, false, "Defer decoding until drawing images. "
@@ -314,6 +319,11 @@ sk_tools::PictureRenderer* parseRenderer(SkString& error, PictureTool tool) {
deviceType = sk_tools::PictureRenderer::kAngle_DeviceType;
}
#endif
+#if SK_COMMAND_BUFFER
+ else if (0 == strcmp(FLAGS_config[0], "commandbuffer")) {
+ deviceType = sk_tools::PictureRenderer::kCommandBuffer_DeviceType;
+ }
+#endif
#if SK_MESA
else if (0 == strcmp(FLAGS_config[0], "mesa")) {
deviceType = sk_tools::PictureRenderer::kMesa_DeviceType;
« no previous file with comments | « tools/PictureRenderer.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698