*/
#include "Benchmark.h"
-#include "GrContext.h"
#include "sk_tool_utils.h"
#include "SkCanvas.h"
#include "SkImage.h"
#include "SkSurface.h"
+#if SK_SUPPORT_GPU
+
+#include "GrContext.h"
+
/** These benchmarks were designed to measure changes to GrResourceCache's replacement policy */
//////////////////////////////////////////////////////////////////////////////
DEF_BENCH( return new ImageCacheBudgetDynamicBench(ImageCacheBudgetDynamicBench::Mode::kPingPong); )
DEF_BENCH( return new ImageCacheBudgetDynamicBench(ImageCacheBudgetDynamicBench::Mode::kFlipFlop); )
+
+#endif
}
}
+// disable warning : switch statement contains default but no 'case' labels
+#if defined _WIN32
+#pragma warning ( push )
+#pragma warning ( disable : 4065 )
+#endif
+
// If bench is enabled for config, returns a Target* for it, otherwise nullptr.
static Target* is_enabled(Benchmark* bench, const Config& config) {
if (!bench->isSuitableFor(config.backend)) {
return target;
}
+#if defined _WIN32
+#pragma warning ( pop )
+#endif
+
static bool valid_brd_bench(sk_sp<SkData> encoded, SkColorType colorType, uint32_t sampleSize,
uint32_t minOutputSize, int* width, int* height) {
SkAutoTDelete<SkBitmapRegionDecoder> brd(