skia2/tools/flags/SkCommonFlags.h
Chris Dalton 7a0ebfc033 Add a tooling flag for path mask caching
Adds the flag and a disables caching on the CCPR bots.

Bug: skia:
Change-Id: Icb85e77f89634dda1d419dacac5b8a93340723f0
Reviewed-on: https://skia-review.googlesource.com/59740
Reviewed-by: Eric Boren <borenet@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2017-10-13 22:31:12 +00:00

60 lines
1.6 KiB
C

/*
* Copyright 2014 Google Inc.
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#ifndef SK_COMMON_FLAGS_H
#define SK_COMMON_FLAGS_H
#include "../private/SkTArray.h"
#include "SkCommandLineFlags.h"
#include "SkString.h"
DECLARE_bool(cpu);
DECLARE_bool(dryRun);
DECLARE_bool(gpu);
DECLARE_string(images);
DECLARE_string(colorImages);
DECLARE_bool(simpleCodec);
DECLARE_string(match);
DECLARE_bool(quiet);
DECLARE_bool(preAbandonGpuContext);
DECLARE_bool(abandonGpuContext);
DECLARE_bool(releaseAndAbandonGpuContext);
DECLARE_string(skps);
DECLARE_bool(ddl);
DECLARE_string(svgs);
DECLARE_int32(threads);
DECLARE_string(resourcePath);
DECLARE_bool(verbose);
DECLARE_bool(veryVerbose);
DECLARE_string(writePath);
DECLARE_bool(pre_log);
DECLARE_bool(analyticAA);
DECLARE_bool(forceAnalyticAA);
DECLARE_bool(deltaAA);
DECLARE_bool(forceDeltaAA);
#if SK_SUPPORT_GPU
DECLARE_bool(cachePathMasks);
#endif
DECLARE_string(key);
DECLARE_string(properties);
/**
* Helper to assist in collecting image paths from |dir| specified through a command line flag.
*
* Populates |output|, an array of strings with paths to images to test.
*
* Returns true if each argument to the images flag is meaningful:
* - If the file/directory does not exist, return false.
* - If |dir| does not have any supported images (based on file type), return false.
* - If |dir| is a single file, assume the user is deliberately testing this image,
* regardless of file type.
*/
bool CollectImages(SkCommandLineFlags::StringArray dir, SkTArray<SkString>* output);
#endif