diff options
Diffstat (limited to 'metrics')
-rw-r--r-- | metrics/ignores/platform-linux.json | 3 | ||||
-rw-r--r-- | metrics/tests/location_indicator/change_image/expected.png | bin | 0 -> 12111 bytes | |||
-rw-r--r-- | metrics/tests/location_indicator/change_image/style.json | 104 |
3 files changed, 106 insertions, 1 deletions
diff --git a/metrics/ignores/platform-linux.json b/metrics/ignores/platform-linux.json index 29d06bfc3d..ec018eb805 100644 --- a/metrics/ignores/platform-linux.json +++ b/metrics/ignores/platform-linux.json @@ -21,5 +21,6 @@ "location_indicator/tilted_texture_shift_top_left": "Would need a different baseline when ran on llvmpipe not supporting anisotropic filtering", "location_indicator/tilted_texture_shift_top_right": "Would need a different baseline when ran on llvmpipe not supporting anisotropic filtering", "location_indicator/two_textures": "Would need a different baseline when ran on llvmpipe not supporting anisotropic filtering", - "location_indicator/image_pixel_ratio": "Would need a different baseline when ran on llvmpipe not supporting anisotropic filtering" + "location_indicator/image_pixel_ratio": "Would need a different baseline when ran on llvmpipe not supporting anisotropic filtering", + "location_indicator/change_image": "Would need a different baseline when ran on llvmpipe not supporting anisotropic filtering" } diff --git a/metrics/tests/location_indicator/change_image/expected.png b/metrics/tests/location_indicator/change_image/expected.png Binary files differnew file mode 100644 index 0000000000..ffd0542078 --- /dev/null +++ b/metrics/tests/location_indicator/change_image/expected.png diff --git a/metrics/tests/location_indicator/change_image/style.json b/metrics/tests/location_indicator/change_image/style.json new file mode 100644 index 0000000000..7aed158bc5 --- /dev/null +++ b/metrics/tests/location_indicator/change_image/style.json @@ -0,0 +1,104 @@ +{ + "version": 8, + "metadata": { + "test": { + "width": 512, + "height": 256, + "operations": [ + [ + "addImage", + "puck_hat", + "puck_hat.png", + {"pixelRatio": 2.0} + ], + [ + "addImage", + "puck", + "puck.png", + {"pixelRatio": 2.0} + + ], + [ + "addImage", + "puck_shadow", + "puck_shadow.png", + {"pixelRatio": 2.0} + ], + [ "sleep", 500 ], + [ + "addImage", + "puck_hat", + "puck_hat.png", + {"pixelRatio": 4.0} + ] + ] + } + }, + "sources": { + "geojson": { + "type": "geojson", + "data": { + "type": "FeatureCollection", + "features": [ + { + "type": "Feature", + "properties": { + }, + "geometry": { + "type": "Point", + "coordinates": [ + 139.766707, + 35.693055 + + ] + } + } + ] + } + } + }, + "center": [ 139.766707, 35.693055 ], + "zoom": 16, + "pitch" : 0, + "bearing" : 42, + "layers": [ + { + "id": "background", + "type": "background", + "paint": { + "background-color": "lightseagreen" + } + }, + { + "id": "puck123", + "type": "circle", + "source": "geojson", + "paint": { + "circle-radius": 40, + "circle-color" : "rgba(255,0,0,0.1)" + } + }, + { + "id": "puck124", + "type": "location-indicator", + "layout" : { + "bearing-image" : "puck", + "top-image" : "puck_hat", + "shadow-image" : "puck_shadow" + }, + "paint" : { + "bearing" : 45, + "perspective-compensation" : 1, + "image-tilt-displacement" : 6.5, + "location" : [ 35.693055, 139.766707, 0], + "accuracy-radius": 90.0, + "bearing-image-size" : 0.52, + "top-image-size" : 0.36, + "shadow-image-size" : 0.4, + + "accuracy-radius-color": "rgba(255,0,0,0.2)", + "accuracy-radius-border-color": "rgba(255,0,255,0.6)" + } + } + ] +} |