summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorzmiao <miao.zhao@mapbox.com>2020-02-19 14:22:38 +0200
committerzmiao <miao.zhao@mapbox.com>2020-02-21 21:39:48 +0200
commit385fcd52a0285dcd6008b823d4be303a4c864046 (patch)
treeeee2f06f5675398dcc789bc4c013e7dd40abed18
parentb9425dd4ecd112f0f455b6a6950039d77305a465 (diff)
downloadqtlocation-mapboxgl-385fcd52a0285dcd6008b823d4be303a4c864046.tar.gz
[test-runner] Add new metrics
-rw-r--r--metrics/android-render-test-runner/render-tests/within/paint-line/metrics.json35
-rw-r--r--metrics/ios-render-test-runner/render-tests/within/paint-line/metrics.json35
-rw-r--r--metrics/linux-clang8-release/render-tests/within/paint-line/metrics.json35
-rw-r--r--metrics/linux-gcc8-release/render-tests/within/paint-line/metrics.json35
-rw-r--r--src/mbgl/style/expression/within.cpp2
5 files changed, 141 insertions, 1 deletions
diff --git a/metrics/android-render-test-runner/render-tests/within/paint-line/metrics.json b/metrics/android-render-test-runner/render-tests/within/paint-line/metrics.json
new file mode 100644
index 0000000000..c32db503cb
--- /dev/null
+++ b/metrics/android-render-test-runner/render-tests/within/paint-line/metrics.json
@@ -0,0 +1,35 @@
+{
+ "network": [
+ [
+ "probeNetwork - default - end",
+ 0,
+ 0
+ ],
+ [
+ "probeNetwork - default - start",
+ 0,
+ 0
+ ]
+ ],
+ "gfx": [
+ [
+ "probeGFX - default - end",
+ 5,
+ 4,
+ 13,
+ 1,
+ [
+ 49152,
+ 49152
+ ],
+ [
+ 286,
+ 286
+ ],
+ [
+ 528,
+ 528
+ ]
+ ]
+ ]
+} \ No newline at end of file
diff --git a/metrics/ios-render-test-runner/render-tests/within/paint-line/metrics.json b/metrics/ios-render-test-runner/render-tests/within/paint-line/metrics.json
new file mode 100644
index 0000000000..c32db503cb
--- /dev/null
+++ b/metrics/ios-render-test-runner/render-tests/within/paint-line/metrics.json
@@ -0,0 +1,35 @@
+{
+ "network": [
+ [
+ "probeNetwork - default - end",
+ 0,
+ 0
+ ],
+ [
+ "probeNetwork - default - start",
+ 0,
+ 0
+ ]
+ ],
+ "gfx": [
+ [
+ "probeGFX - default - end",
+ 5,
+ 4,
+ 13,
+ 1,
+ [
+ 49152,
+ 49152
+ ],
+ [
+ 286,
+ 286
+ ],
+ [
+ 528,
+ 528
+ ]
+ ]
+ ]
+} \ No newline at end of file
diff --git a/metrics/linux-clang8-release/render-tests/within/paint-line/metrics.json b/metrics/linux-clang8-release/render-tests/within/paint-line/metrics.json
new file mode 100644
index 0000000000..c32db503cb
--- /dev/null
+++ b/metrics/linux-clang8-release/render-tests/within/paint-line/metrics.json
@@ -0,0 +1,35 @@
+{
+ "network": [
+ [
+ "probeNetwork - default - end",
+ 0,
+ 0
+ ],
+ [
+ "probeNetwork - default - start",
+ 0,
+ 0
+ ]
+ ],
+ "gfx": [
+ [
+ "probeGFX - default - end",
+ 5,
+ 4,
+ 13,
+ 1,
+ [
+ 49152,
+ 49152
+ ],
+ [
+ 286,
+ 286
+ ],
+ [
+ 528,
+ 528
+ ]
+ ]
+ ]
+} \ No newline at end of file
diff --git a/metrics/linux-gcc8-release/render-tests/within/paint-line/metrics.json b/metrics/linux-gcc8-release/render-tests/within/paint-line/metrics.json
new file mode 100644
index 0000000000..c32db503cb
--- /dev/null
+++ b/metrics/linux-gcc8-release/render-tests/within/paint-line/metrics.json
@@ -0,0 +1,35 @@
+{
+ "network": [
+ [
+ "probeNetwork - default - end",
+ 0,
+ 0
+ ],
+ [
+ "probeNetwork - default - start",
+ 0,
+ 0
+ ]
+ ],
+ "gfx": [
+ [
+ "probeGFX - default - end",
+ 5,
+ 4,
+ 13,
+ 1,
+ [
+ 49152,
+ 49152
+ ],
+ [
+ 286,
+ 286
+ ],
+ [
+ 528,
+ 528
+ ]
+ ]
+ ]
+} \ No newline at end of file
diff --git a/src/mbgl/style/expression/within.cpp b/src/mbgl/style/expression/within.cpp
index 7dc55eda7f..18d24b9250 100644
--- a/src/mbgl/style/expression/within.cpp
+++ b/src/mbgl/style/expression/within.cpp
@@ -165,7 +165,7 @@ ParseResult Within::parse(const Convertible& value, ParsingContext& ctx) {
mbgl::Feature f(geometrySet);
PolygonFeature polyFeature(f, CanonicalTileID(0, 0, 0));
auto refinedGeoSet = convertGeometry(polyFeature, CanonicalTileID(0, 0, 0));
- return ParseResult(std::make_unique<Within>(*parsedValue, refinedGeoSet));
+ return ParseResult(std::make_unique<Within>(*parsedValue, std::move(refinedGeoSet)));
},
[&ctx](const auto&) {
ctx.error("'within' expression requires geojson source that contains valid geometry data.");