From 896379daa5da936039511c5c3e06c92e6a59a50d Mon Sep 17 00:00:00 2001 From: John Firebaugh Date: Mon, 22 Sep 2014 13:39:43 -0700 Subject: Refactor tile cover to match JS --- include/mbgl/map/source.hpp | 3 +- include/mbgl/map/tile.hpp | 3 + src/map/source.cpp | 173 ++++++++++---------------------------------- src/map/tile.cpp | 88 ++++++++++++++++++++++ 4 files changed, 132 insertions(+), 135 deletions(-) diff --git a/include/mbgl/map/source.hpp b/include/mbgl/map/source.hpp index 4bc4c86dd0..cb069db272 100644 --- a/include/mbgl/map/source.hpp +++ b/include/mbgl/map/source.hpp @@ -44,7 +44,8 @@ public: private: bool findLoadedChildren(const Tile::ID& id, int32_t maxCoveringZoom, std::forward_list& retain); bool findLoadedParent(const Tile::ID& id, int32_t minCoveringZoom, std::forward_list& retain); - std::forward_list covering_tiles(const TransformState &state, int32_t clamped_zoom, const box& points); + int32_t coveringZoomLevel(const TransformState&) const; + std::forward_list coveringTiles(const TransformState&) const; bool updateTiles(Map &map); diff --git a/include/mbgl/map/tile.hpp b/include/mbgl/map/tile.hpp index 24845c81a0..75ced7e384 100644 --- a/include/mbgl/map/tile.hpp +++ b/include/mbgl/map/tile.hpp @@ -16,6 +16,7 @@ namespace mbgl { class TileData; +struct box; struct ClipID { inline ClipID() {} @@ -68,6 +69,8 @@ public: bool isChildOf(const Tile::ID &id) const; }; + static std::forward_list cover(int8_t z, const box& bounds); + public: explicit Tile(const ID& id); diff --git a/src/map/source.cpp b/src/map/source.cpp index 3fe5bf42fa..083e931b7a 100644 --- a/src/map/source.cpp +++ b/src/map/source.cpp @@ -8,6 +8,7 @@ #include #include #include +#include #include #include #include @@ -197,6 +198,37 @@ TileData::State Source::addTile(Map &map, const Tile::ID& id) { return new_tile.data->state; } +double Source::getZoom(const TransformState& state) const { + double offset = std::log(util::tileSize / info.tile_size) / std::log(2); + offset += (state.getPixelRatio() > 1.0 ? 1 :0); + return state.getZoom() + offset; +} + +int32_t Source::coveringZoomLevel(const TransformState& state) const { + return std::floor(getZoom(state)); +} + +std::forward_list Source::coveringTiles(const TransformState& state) const { + int32_t z = coveringZoomLevel(state); + + if (z < info.min_zoom) return {{}}; + if (z > info.max_zoom) z = info.max_zoom; + + // Map four viewport corners to pixel coordinates + box points = state.cornersToBox(z); + const vec2& center = points.center; + + std::forward_list tiles = Tile::cover(z, points); + + tiles.sort([¢er](const Tile::ID& a, const Tile::ID& b) { + // Sorts by distance from the box center + return std::fabs(a.x - center.x) + std::fabs(a.y - center.y) < + std::fabs(b.x - center.x) + std::fabs(b.y - center.y); + }); + + return tiles; +} + /** * Recursively find children of the given tile that are already loaded. * @@ -209,8 +241,6 @@ TileData::State Source::addTile(Map &map, const Tile::ID& id) { bool Source::findLoadedChildren(const Tile::ID& id, int32_t maxCoveringZoom, std::forward_list& retain) { bool complete = true; int32_t z = id.z; - - auto ids = id.children(z + 1); for (const Tile::ID& child_id : ids) { const TileData::State state = hasTile(child_id); @@ -251,24 +281,12 @@ bool Source::findLoadedParent(const Tile::ID& id, int32_t minCoveringZoom, std:: bool Source::updateTiles(Map &map) { bool changed = false; - // Figure out what tiles we need to load - int32_t clamped_zoom = map.getState().getIntegerZoom(); - if (clamped_zoom > info.max_zoom) clamped_zoom = info.max_zoom; - if (clamped_zoom < info.min_zoom) clamped_zoom = info.min_zoom; - - int32_t max_covering_zoom = clamped_zoom + 1; - if (max_covering_zoom > info.max_zoom) max_covering_zoom = info.max_zoom; - - int32_t min_covering_zoom = clamped_zoom - 10; - if (min_covering_zoom < info.min_zoom) min_covering_zoom = info.min_zoom; + int32_t zoom = std::floor(getZoom(map.getState())); + std::forward_list required = coveringTiles(map.getState()); - // Map four viewport corners to pixel coordinates - box box = map.getState().cornersToBox(clamped_zoom); - - // Performs a scanline algorithm search that covers the rectangle of the box - // and sorts them by proximity to the center. - - std::forward_list required = covering_tiles(map.getState(), clamped_zoom, box); + // Determine the overzooming/underzooming amounts. + int32_t minCoveringZoom = util::clamp(zoom - 10, info.min_zoom, info.max_zoom); + int32_t maxCoveringZoom = util::clamp(zoom + 1, info.min_zoom, info.max_zoom); // Retain is a list of tiles that we shouldn't delete, even if they are not // the most ideal tile for the current viewport. This may include tiles like @@ -280,20 +298,17 @@ bool Source::updateTiles(Map &map) { const TileData::State state = addTile(map, id); if (state != TileData::State::parsed) { -// if (use_raster && (transform.rotating || transform.scaling || transform.panning)) -// break; - // The tile we require is not yet loaded. Try to find a parent or // child tile that we already have. // First, try to find existing child tiles that completely cover the // missing tile. - bool complete = findLoadedChildren(id, max_covering_zoom, retain); + bool complete = findLoadedChildren(id, maxCoveringZoom, retain); // Then, if there are no complete child tiles, try to find existing // parent tiles that completely cover the missing tile. if (!complete) { - findLoadedParent(id, min_covering_zoom, retain); + findLoadedParent(id, minCoveringZoom, retain); } } @@ -337,114 +352,4 @@ bool Source::updateTiles(Map &map) { return changed; } -// Taken from polymaps src/Layer.js -// https://github.com/simplegeo/polymaps/blob/master/src/Layer.js#L333-L383 - -struct edge { - double x0 = 0, y0 = 0; - double x1 = 0, y1 = 0; - double dx = 0, dy = 0; - edge(double x0, double y0, double x1, double y1, double dx, double dy) - : x0(x0), y0(y0), x1(x1), y1(y1), dx(dx), dy(dy) {} -}; - -typedef const std::function ScanLine; - -// scan-line conversion -edge _edge(const mbgl::vec2 a, const mbgl::vec2 b) { - if (a.y > b.y) { - return { b.x, b.y, a.x, a.y, a.x - b.x, a.y - b.y }; - } else { - return { a.x, a.y, b.x, b.y, b.x - a.x, b.y - a.y }; - } -} - -// scan-line conversion -void _scanSpans(edge e0, edge e1, int32_t ymin, int32_t ymax, ScanLine scanLine) { - double y0 = std::fmax(ymin, std::floor(e1.y0)), - y1 = std::fmin(ymax, std::ceil(e1.y1)); - - // sort edges by x-coordinate - if ((e0.x0 == e1.x0 && e0.y0 == e1.y0) ? - (e0.x0 + e1.dy / e0.dy * e0.dx < e1.x1) : - (e0.x1 - e1.dy / e0.dy * e0.dx < e1.x0)) { - std::swap(e0, e1); - } - - // scan lines! - double m0 = e0.dx / e0.dy, - m1 = e1.dx / e1.dy, - d0 = e0.dx > 0, // use y + 1 to compute x0 - d1 = e1.dx < 0; // use y + 1 to compute x1 - for (int32_t y = y0; y < y1; y++) { - double x0 = m0 * std::fmax(0, std::fmin(e0.dy, y + d0 - e0.y0)) + e0.x0, - x1 = m1 * std::fmax(0, std::fmin(e1.dy, y + d1 - e1.y0)) + e1.x0; - scanLine(std::floor(x1), std::ceil(x0), y, ymax); - } -} - -// scan-line conversion -void _scanTriangle(const mbgl::vec2 a, const mbgl::vec2 b, const mbgl::vec2 c, int32_t ymin, int32_t ymax, ScanLine& scanLine) { - edge ab = _edge(a, b); - edge bc = _edge(b, c); - edge ca = _edge(c, a); - - // sort edges by y-length - if (ab.dy > bc.dy) { std::swap(ab, bc); } - if (ab.dy > ca.dy) { std::swap(ab, ca); } - if (bc.dy > ca.dy) { std::swap(bc, ca); } - - // scan span! scan span! - if (ab.dy) _scanSpans(ca, ab, ymin, ymax, scanLine); - if (bc.dy) _scanSpans(ca, bc, ymin, ymax, scanLine); -} - -double Source::getZoom(const TransformState &state) const { - double offset = log(util::tileSize / info.tile_size) / log(2); - offset += (state.getPixelRatio() > 1.0 ? 1 :0); - return state.getZoom() + offset; -} - -std::forward_list Source::covering_tiles(const TransformState &state, int32_t clamped_zoom, const box& points) { - int32_t dim = std::pow(2, clamped_zoom); - std::forward_list tiles; - bool is_raster = (info.type == SourceType::Raster); - double search_zoom = getZoom(state); - - auto scanLine = [&tiles, clamped_zoom, is_raster, search_zoom](int32_t x0, int32_t x1, int32_t y, int32_t ymax) { - int32_t x; - if (y >= 0 && y <= ymax) { - for (x = x0; x < x1; x++) { - if (is_raster) { - Tile::ID id = Tile::ID(clamped_zoom, x, y); - auto ids = id.children(search_zoom); - for (const Tile::ID& child_id : ids) { - tiles.emplace_front(child_id.z, child_id.x, child_id.y); - } - } else { - tiles.emplace_front(clamped_zoom, x, y); - } - } - } - }; - - // Divide the screen up in two triangles and scan each of them: - // \---+ - // | \ | - // +---\. - _scanTriangle(points.tl, points.tr, points.br, 0, dim, scanLine); - _scanTriangle(points.br, points.bl, points.tl, 0, dim, scanLine); - - const vec2& center = points.center; - tiles.sort([¢er](const Tile::ID& a, const Tile::ID& b) { - // Sorts by distance from the box center - return std::fabs(a.x - center.x) + std::fabs(a.y - center.y) < - std::fabs(b.x - center.x) + std::fabs(b.y - center.y); - }); - - tiles.unique(); - - return tiles; -} - } diff --git a/src/map/tile.cpp b/src/map/tile.cpp index e073960116..863fbfbece 100644 --- a/src/map/tile.cpp +++ b/src/map/tile.cpp @@ -1,4 +1,5 @@ #include +#include #include @@ -49,3 +50,90 @@ bool Tile::ID::isChildOf(const Tile::ID &parent) const { return parent.x == ((x < 0 ? x - scale + 1 : x) / scale) && parent.y == y / scale; } + + +// Taken from polymaps src/Layer.js +// https://github.com/simplegeo/polymaps/blob/master/src/Layer.js#L333-L383 + +struct edge { + double x0 = 0, y0 = 0; + double x1 = 0, y1 = 0; + double dx = 0, dy = 0; + + edge(vec2 a, vec2 b) { + if (a.y > b.y) { std::swap(a, b); } + x0 = a.x; + y0 = a.y; + x1 = b.x; + y1 = b.y; + dx = b.x - a.x; + dy = b.y - a.y; + } +}; + +typedef const std::function ScanLine; + +// scan-line conversion +static void scanSpans(edge e0, edge e1, int32_t ymin, int32_t ymax, ScanLine scanLine) { + double y0 = std::fmax(ymin, std::floor(e1.y0)); + double y1 = std::fmin(ymax, std::ceil(e1.y1)); + + // sort edges by x-coordinate + if ((e0.x0 == e1.x0 && e0.y0 == e1.y0) ? + (e0.x0 + e1.dy / e0.dy * e0.dx < e1.x1) : + (e0.x1 - e1.dy / e0.dy * e0.dx < e1.x0)) { + std::swap(e0, e1); + } + + // scan lines! + double m0 = e0.dx / e0.dy; + double m1 = e1.dx / e1.dy; + double d0 = e0.dx > 0; // use y + 1 to compute x0 + double d1 = e1.dx < 0; // use y + 1 to compute x1 + for (int32_t y = y0; y < y1; y++) { + double x0 = m0 * std::fmax(0, std::fmin(e0.dy, y + d0 - e0.y0)) + e0.x0; + double x1 = m1 * std::fmax(0, std::fmin(e1.dy, y + d1 - e1.y0)) + e1.x0; + scanLine(std::floor(x1), std::ceil(x0), y); + } +} + +// scan-line conversion +static void scanTriangle(const mbgl::vec2 a, const mbgl::vec2 b, const mbgl::vec2 c, int32_t ymin, int32_t ymax, ScanLine& scanLine) { + edge ab = edge(a, b); + edge bc = edge(b, c); + edge ca = edge(c, a); + + // sort edges by y-length + if (ab.dy > bc.dy) { std::swap(ab, bc); } + if (ab.dy > ca.dy) { std::swap(ab, ca); } + if (bc.dy > ca.dy) { std::swap(bc, ca); } + + // scan span! scan span! + if (ab.dy) scanSpans(ca, ab, ymin, ymax, scanLine); + if (bc.dy) scanSpans(ca, bc, ymin, ymax, scanLine); +} + +std::forward_list Tile::cover(int8_t z, const mbgl::box &bounds) { + int32_t tiles = 1 << z; + std::forward_list t; + + auto scanLine = [&](int32_t x0, int32_t x1, int32_t y) { + int32_t x; + if (y >= 0 && y <= tiles) { + for (x = x0; x < x1; x++) { + t.emplace_front(z, x, y); + } + } + }; + + // Divide the screen up in two triangles and scan each of them: + // \---+ + // | \ | + // +---\. + scanTriangle(bounds.tl, bounds.tr, bounds.br, 0, tiles, scanLine); + scanTriangle(bounds.br, bounds.bl, bounds.tl, 0, tiles, scanLine); + + t.unique(); + + return t; +} -- cgit v1.2.1 From 4b98870e99dfa0aaa63c15a225e971872f8ade71 Mon Sep 17 00:00:00 2001 From: John Firebaugh Date: Mon, 22 Sep 2014 14:05:15 -0700 Subject: Support pixelRatio parameter for render tests --- common/headless_view.cpp | 5 ++++- common/headless_view.hpp | 2 +- test/headless.cpp | 15 ++++++++++----- 3 files changed, 15 insertions(+), 7 deletions(-) diff --git a/common/headless_view.cpp b/common/headless_view.cpp index f790d90cec..ed00f48e82 100644 --- a/common/headless_view.cpp +++ b/common/headless_view.cpp @@ -65,9 +65,12 @@ HeadlessView::HeadlessView() { } -void HeadlessView::resize(int width, int height) { +void HeadlessView::resize(uint16_t width, uint16_t height, float pixelRatio) { clear_buffers(); + width *= pixelRatio; + height *= pixelRatio; + #if MBGL_USE_CGL make_active(); diff --git a/common/headless_view.hpp b/common/headless_view.hpp index 0b255b4a38..a8ce4aa325 100644 --- a/common/headless_view.hpp +++ b/common/headless_view.hpp @@ -19,7 +19,7 @@ public: HeadlessView(); ~HeadlessView(); - void resize(int width, int height); + void resize(uint16_t width, uint16_t height, float pixelRatio); void notify_map_change(MapChange change, timestamp delay = 0); void make_active(); diff --git a/test/headless.cpp b/test/headless.cpp index 4299fd79b9..3cc2607e47 100644 --- a/test/headless.cpp +++ b/test/headless.cpp @@ -65,6 +65,8 @@ TEST_P(HeadlessTest, render) { const double longitude = value.HasMember("center") ? value["center"][rapidjson::SizeType(1)].GetDouble() : 0; const unsigned int width = value.HasMember("width") ? value["width"].GetUint() : 512; const unsigned int height = value.HasMember("height") ? value["height"].GetUint() : 512; + const unsigned int pixelRatio = value.HasMember("pixelRatio") ? value["pixelRatio"].GetUint() : 1; + std::vector classes; if (value.HasMember("classes")) { const rapidjson::Value &js_classes = value["classes"]; @@ -82,18 +84,21 @@ TEST_P(HeadlessTest, render) { map.setStyleJSON(style, base_directory); map.setAppliedClasses(classes); - view.resize(width, height); - map.resize(width, height); + view.resize(width, height, pixelRatio); + map.resize(width, height, pixelRatio); map.setLonLatZoom(longitude, latitude, zoom); map.setBearing(bearing); // Run the loop. It will terminate when we don't have any further listeners. map.run(); - const std::unique_ptr pixels(new uint32_t[width * height]); - glReadPixels(0, 0, width, height, GL_RGBA, GL_UNSIGNED_BYTE, pixels.get()); + const unsigned int w = width * pixelRatio; + const unsigned int h = height * pixelRatio; + + const std::unique_ptr pixels(new uint32_t[w * h]); + glReadPixels(0, 0, w, h, GL_RGBA, GL_UNSIGNED_BYTE, pixels.get()); - const std::string image = util::compress_png(width, height, pixels.get(), true); + const std::string image = util::compress_png(w, h, pixels.get(), true); util::write_file(actual_image, image); } } -- cgit v1.2.1 From ee3e0827a20492ba0f91c5c5f60cf24b2e49cb32 Mon Sep 17 00:00:00 2001 From: John Firebaugh Date: Mon, 22 Sep 2014 11:36:30 -0700 Subject: =?UTF-8?q?transition-*=20=E2=87=A2=20*-transition?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit https://github.com/mapbox/mapbox-gl-style-spec/issues/148 --- src/style/style_parser.cpp | 62 +++++++++++++++++++++++----------------------- 1 file changed, 31 insertions(+), 31 deletions(-) diff --git a/src/style/style_parser.cpp b/src/style/style_parser.cpp index f0d6992318..7e695e71cb 100644 --- a/src/style/style_parser.cpp +++ b/src/style/style_parser.cpp @@ -565,78 +565,78 @@ void StyleParser::parseStyle(JSVal value, ClassProperties &klass) { parseOptionalProperty>("fill-antialias", Key::FillAntialias, klass, value); parseOptionalProperty>("fill-opacity", Key::FillOpacity, klass, value); - parseOptionalProperty("transition-fill-opacity", Key::FillOpacity, klass, value); + parseOptionalProperty("fill-opacity-transition", Key::FillOpacity, klass, value); parseOptionalProperty>("fill-color", Key::FillColor, klass, value); - parseOptionalProperty("transition-fill-color", Key::FillColor, klass, value); + parseOptionalProperty("fill-color-transition", Key::FillColor, klass, value); parseOptionalProperty>("fill-outline-color", Key::FillOutlineColor, klass, value); - parseOptionalProperty("transition-fill-outline-color", Key::FillOutlineColor, klass, value); + parseOptionalProperty("fill-outline-color-transition", Key::FillOutlineColor, klass, value); parseOptionalProperty>("fill-translate", { Key::FillTranslateX, Key::FillTranslateY }, klass, value); - parseOptionalProperty("transition-fill-translate", Key::FillTranslate, klass, value); + parseOptionalProperty("fill-translate-transition", Key::FillTranslate, klass, value); parseOptionalProperty("fill-translate-anchor", Key::FillTranslateAnchor, klass, value); parseOptionalProperty("fill-image", Key::FillImage, klass, value); parseOptionalProperty>("line-opacity", Key::LineOpacity, klass, value); - parseOptionalProperty("transition-line-opacity", Key::LineOpacity, klass, value); + parseOptionalProperty("line-opacity-transition", Key::LineOpacity, klass, value); parseOptionalProperty>("line-color", Key::LineColor, klass, value); - parseOptionalProperty("transition-line-color", Key::LineColor, klass, value); + parseOptionalProperty("line-color-transition", Key::LineColor, klass, value); parseOptionalProperty>("line-translate", { Key::LineTranslateX, Key::LineTranslateY }, klass, value); - parseOptionalProperty("transition-line-translate", Key::LineTranslate, klass, value); + parseOptionalProperty("line-translate-transition", Key::LineTranslate, klass, value); parseOptionalProperty("line-translate-anchor", Key::LineTranslateAnchor, klass, value); parseOptionalProperty>("line-width", Key::LineWidth, klass, value); - parseOptionalProperty("transition-line-width", Key::LineWidth, klass, value); + parseOptionalProperty("line-width-transition", Key::LineWidth, klass, value); parseOptionalProperty>("line-offset", Key::LineOffset, klass, value); - parseOptionalProperty("transition-line-offset", Key::LineOffset, klass, value); + parseOptionalProperty("line-offset-transition", Key::LineOffset, klass, value); parseOptionalProperty>("line-blur", Key::LineBlur, klass, value); - parseOptionalProperty("transition-line-blur", Key::LineBlur, klass, value); + parseOptionalProperty("line-blur-transition", Key::LineBlur, klass, value); parseOptionalProperty>("line-dasharray", { Key::LineDashLand, Key::LineDashGap }, klass, value); - parseOptionalProperty("transition-line-dasharray", Key::LineDashArray, klass, value); + parseOptionalProperty("line-dasharray-transition", Key::LineDashArray, klass, value); parseOptionalProperty("line-image", Key::LineImage, klass, value); parseOptionalProperty>("icon-opacity", Key::IconOpacity, klass, value); - parseOptionalProperty("transition-icon-opacity", Key::IconOpacity, klass, value); + parseOptionalProperty("icon-opacity-transition", Key::IconOpacity, klass, value); parseOptionalProperty>("icon-rotate", Key::IconRotate, klass, value); parseOptionalProperty>("icon-size", Key::IconSize, klass, value); - parseOptionalProperty("transition-icon-size", Key::IconSize, klass, value); + parseOptionalProperty("icon-size-transition", Key::IconSize, klass, value); parseOptionalProperty>("icon-color", Key::IconColor, klass, value); - parseOptionalProperty("transition-icon-color", Key::IconColor, klass, value); + parseOptionalProperty("icon-color-transition", Key::IconColor, klass, value); parseOptionalProperty>("icon-halo-color", Key::IconHaloColor, klass, value); - parseOptionalProperty("transition-icon-halo-color", Key::IconHaloColor, klass, value); + parseOptionalProperty("icon-halo-color-transition", Key::IconHaloColor, klass, value); parseOptionalProperty>("icon-halo-width", Key::IconHaloWidth, klass, value); - parseOptionalProperty("transition-icon-halo-width", Key::IconHaloWidth, klass, value); + parseOptionalProperty("icon-halo-width-transition", Key::IconHaloWidth, klass, value); parseOptionalProperty>("icon-halo-blur", Key::IconHaloBlur, klass, value); - parseOptionalProperty("transition-icon-halo-blur", Key::IconHaloBlur, klass, value); + parseOptionalProperty("icon-halo-blur-transition", Key::IconHaloBlur, klass, value); parseOptionalProperty>("icon-translate", { Key::IconTranslateX, Key::IconTranslateY }, klass, value); - parseOptionalProperty("transition-icon-translate", Key::IconTranslate, klass, value); + parseOptionalProperty("icon-translate-transition", Key::IconTranslate, klass, value); parseOptionalProperty("icon-translate-anchor", Key::IconTranslateAnchor, klass, value); parseOptionalProperty>("text-opacity", Key::TextOpacity, klass, value); - parseOptionalProperty("transition-text-opacity", Key::TextOpacity, klass, value); + parseOptionalProperty("text-opacity-transition", Key::TextOpacity, klass, value); parseOptionalProperty>("text-size", Key::TextSize, klass, value); - parseOptionalProperty("transition-text-size", Key::TextSize, klass, value); + parseOptionalProperty("text-size-transition", Key::TextSize, klass, value); parseOptionalProperty>("text-color", Key::TextColor, klass, value); - parseOptionalProperty("transition-text-color", Key::TextColor, klass, value); + parseOptionalProperty("text-color-transition", Key::TextColor, klass, value); parseOptionalProperty>("text-halo-color", Key::TextHaloColor, klass, value); - parseOptionalProperty("transition-text-halo-color", Key::TextHaloColor, klass, value); + parseOptionalProperty("text-halo-color-transition", Key::TextHaloColor, klass, value); parseOptionalProperty>("text-halo-width", Key::TextHaloWidth, klass, value); - parseOptionalProperty("transition-text-halo-width", Key::TextHaloWidth, klass, value); + parseOptionalProperty("text-halo-width-transition", Key::TextHaloWidth, klass, value); parseOptionalProperty>("text-halo-blur", Key::TextHaloBlur, klass, value); - parseOptionalProperty("transition-text-halo-blur", Key::TextHaloBlur, klass, value); + parseOptionalProperty("text-halo-blur-transition", Key::TextHaloBlur, klass, value); parseOptionalProperty>("text-translate", { Key::TextTranslateX, Key::TextTranslateY }, klass, value); - parseOptionalProperty("transition-text-translate", Key::TextTranslate, klass, value); + parseOptionalProperty("text-translate-transition", Key::TextTranslate, klass, value); parseOptionalProperty("text-translate-anchor", Key::TextTranslateAnchor, klass, value); parseOptionalProperty>("raster-opacity", Key::RasterOpacity, klass, value); - parseOptionalProperty("transition-raster-opacity", Key::RasterOpacity, klass, value); + parseOptionalProperty("raster-opacity-transition", Key::RasterOpacity, klass, value); parseOptionalProperty>("raster-hue-rotate", Key::RasterHueRotate, klass, value); - parseOptionalProperty("transition-raster-hue-rotate", Key::RasterHueRotate, klass, value); + parseOptionalProperty("raster-hue-rotate-transition", Key::RasterHueRotate, klass, value); parseOptionalProperty>("raster-brightness", { Key::RasterBrightnessLow, Key::RasterBrightnessHigh }, klass, value); - parseOptionalProperty("transition-raster-brightness", Key::RasterBrightness, klass, value); + parseOptionalProperty("raster-brightness-transition", Key::RasterBrightness, klass, value); parseOptionalProperty>("raster-saturation", Key::RasterSaturation, klass, value); - parseOptionalProperty("transition-raster-saturation", Key::RasterSaturation, klass, value); + parseOptionalProperty("raster-saturation-transition", Key::RasterSaturation, klass, value); parseOptionalProperty>("raster-contrast", Key::RasterContrast, klass, value); - parseOptionalProperty("transition-raster-contrast", Key::RasterContrast, klass, value); + parseOptionalProperty("raster-contrast-transition", Key::RasterContrast, klass, value); parseOptionalProperty>("raster-fade-duration", Key::RasterFade, klass, value); - parseOptionalProperty("transition-raster-fade-duration", Key::RasterFade, klass, value); + parseOptionalProperty("raster-fade-duration-transition", Key::RasterFade, klass, value); parseOptionalProperty>("background-opacity", Key::BackgroundOpacity, klass, value); parseOptionalProperty>("background-color", Key::BackgroundColor, klass, value); -- cgit v1.2.1