commit qt6-qtpbfimageformat for openSUSE:Factory
Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package qt6-qtpbfimageformat for openSUSE:Factory checked in at 2024-10-06 17:53:12 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/qt6-qtpbfimageformat (Old) and /work/SRC/openSUSE:Factory/.qt6-qtpbfimageformat.new.19354 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Package is "qt6-qtpbfimageformat" Sun Oct 6 17:53:12 2024 rev:2 rq:1205963 version:3.2 Changes: -------- --- /work/SRC/openSUSE:Factory/qt6-qtpbfimageformat/qt6-qtpbfimageformat.changes 2024-06-27 16:02:12.376196443 +0200 +++ /work/SRC/openSUSE:Factory/.qt6-qtpbfimageformat.new.19354/qt6-qtpbfimageformat.changes 2024-10-06 17:53:18.352430806 +0200 @@ -1,0 +2,6 @@ +Sun Oct 6 13:55:00 CEST 2024 - tumic@cbox.cz + +- Update to version 3.2 + * Improved rendering performance. + +------------------------------------------------------------------- Old: ---- QtPBFImagePlugin-3.1.tar.gz New: ---- QtPBFImagePlugin-3.2.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ qt6-qtpbfimageformat.spec ++++++ --- /var/tmp/diff_new_pack.Nj10QA/_old 2024-10-06 17:53:19.068460562 +0200 +++ /var/tmp/diff_new_pack.Nj10QA/_new 2024-10-06 17:53:19.072460729 +0200 @@ -19,7 +19,7 @@ # See also http://en.opensuse.org/openSUSE:Specfile_guidelines Name: qt6-qtpbfimageformat -Version: 3.1 +Version: 3.2 Release: 1 Summary: Qt6 PBF Image Format Plugin License: LGPL-3.0-only ++++++ QtPBFImagePlugin-3.1.tar.gz -> QtPBFImagePlugin-3.2.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPBFImagePlugin-3.1/.appveyor.yml new/QtPBFImagePlugin-3.2/.appveyor.yml --- old/QtPBFImagePlugin-3.1/.appveyor.yml 2024-06-15 06:01:04.000000000 +0200 +++ new/QtPBFImagePlugin-3.2/.appveyor.yml 2024-10-06 13:24:08.000000000 +0200 @@ -1,4 +1,4 @@ -version: 3.1.{build} +version: 3.2.{build} configuration: - Release diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPBFImagePlugin-3.1/pbfplugin.pro new/QtPBFImagePlugin-3.2/pbfplugin.pro --- old/QtPBFImagePlugin-3.1/pbfplugin.pro 2024-06-15 06:01:04.000000000 +0200 +++ new/QtPBFImagePlugin-3.2/pbfplugin.pro 2024-10-06 13:24:08.000000000 +0200 @@ -2,7 +2,7 @@ TEMPLATE = lib CONFIG += plugin QT += gui -VERSION = 3.1 +VERSION = 3.2 PROTOS = protobuf/vector_tile.proto include(protobuf/vector_tile.pri) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPBFImagePlugin-3.1/src/pbf.cpp new/QtPBFImagePlugin-3.2/src/pbf.cpp --- old/QtPBFImagePlugin-3.1/src/pbf.cpp 2024-06-15 06:01:04.000000000 +0200 +++ new/QtPBFImagePlugin-3.2/src/pbf.cpp 2024-10-06 13:24:08.000000000 +0200 @@ -31,12 +31,12 @@ else if (val.has_double_value()) return QVariant(val.double_value()); else if (val.has_string_value()) - return QVariant(QString::fromStdString(val.string_value())); + return QVariant(QByteArray::fromStdString(val.string_value())); else return QVariant(); } -const QVariant *PBF::Feature::value(const QString &key) const +const QVariant *PBF::Feature::value(const QByteArray &key) const { const KeyHash &keys(_layer->keys()); KeyHash::const_iterator it(keys.find(key)); @@ -92,7 +92,7 @@ { _keys.reserve(data->keys_size()); for (int i = 0; i < data->keys_size(); i++) - _keys.insert(QString::fromStdString(data->keys(i)), i); + _keys.insert(QByteArray::fromStdString(data->keys(i)), i); _values.reserve(data->values_size()); for (int i = 0; i < data->values_size(); i++) _values.append(value(data->values(i))); @@ -107,7 +107,8 @@ { for (int i = 0; i < tile.layers_size(); i++) { const vector_tile::Tile_Layer &layer = tile.layers(i); - _layers.insert(QString::fromStdString(layer.name()), new Layer(&layer)); + _layers.insert(QByteArray::fromStdString(layer.name()), + new Layer(&layer)); } } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPBFImagePlugin-3.1/src/pbf.h new/QtPBFImagePlugin-3.2/src/pbf.h --- old/QtPBFImagePlugin-3.1/src/pbf.h 2024-06-15 06:01:04.000000000 +0200 +++ new/QtPBFImagePlugin-3.2/src/pbf.h 2024-10-06 13:24:08.000000000 +0200 @@ -8,7 +8,7 @@ #include "vector_tile.pb.h" -typedef QHash<QString, google::protobuf::uint32> KeyHash; +typedef QHash<QByteArray, google::protobuf::uint32> KeyHash; class PBF { @@ -22,7 +22,7 @@ Feature(const vector_tile::Tile_Feature *data, const Layer *layer) : _data(data), _layer(layer) {} - const QVariant *value(const QString &key) const; + const QVariant *value(const QByteArray &key) const; vector_tile::Tile_GeomType type() const {return _data->type();} QPainterPath path(const QSizeF &factor) const; @@ -55,10 +55,10 @@ PBF(const vector_tile::Tile &tile); ~PBF(); - const QHash<QString, Layer*> &layers() const {return _layers;} + const QHash<QByteArray, Layer*> &layers() const {return _layers;} private: - QHash<QString, Layer*> _layers; + QHash<QByteArray, Layer*> _layers; }; inline bool operator<(const PBF::Feature &f1, const PBF::Feature &f2) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPBFImagePlugin-3.1/src/style.cpp new/QtPBFImagePlugin-3.2/src/style.cpp --- old/QtPBFImagePlugin-3.1/src/style.cpp 2024-06-15 06:01:04.000000000 +0200 +++ new/QtPBFImagePlugin-3.2/src/style.cpp 2024-10-06 13:24:08.000000000 +0200 @@ -26,6 +26,20 @@ return vector_tile::Tile_GeomType_UNKNOWN; } +static QVariant variant(const QJsonValue &val) +{ + switch (val.type()) { + case QJsonValue::String: + return QVariant(val.toString().toUtf8()); + case QJsonValue::Double: + case QJsonValue::Bool: + return val.toVariant(); + default: + qWarning() << val << ": invalid filter value"; + return QVariant(); + } +} + Style::Layer::Filter::Filter(const QJsonArray &json) : _type(Unknown), _not(false) { @@ -35,50 +49,50 @@ if (json.isEmpty()) INVALID_FILTER(json); - QString type = json.at(0).toString(); + QString type(json.at(0).toString()); if (type == "==") { if (json.size() != 3) INVALID_FILTER(json); if (json.at(1).toString() == "$type") { _type = GeometryType; - _kv = QPair<QString, QVariant>(QString(), + _kv = QPair<QByteArray, QVariant>(QByteArray(), QVariant(geometryType(json.at(2).toString()))); } else { _type = EQ; - _kv = QPair<QString, QVariant>(json.at(1).toString(), - json.at(2).toVariant()); + _kv = QPair<QByteArray, QVariant>(json.at(1).toString().toUtf8(), + variant(json.at(2))); } } else if (type == "!=") { if (json.size() != 3) INVALID_FILTER(json); _type = NE; - _kv = QPair<QString, QVariant>(json.at(1).toString(), - json.at(2).toVariant()); + _kv = QPair<QByteArray, QVariant>(json.at(1).toString().toUtf8(), + variant(json.at(2))); } else if (type == "<") { if (json.size() != 3) INVALID_FILTER(json); _type = LT; - _kv = QPair<QString, QVariant>(json.at(1).toString(), - json.at(2).toVariant()); + _kv = QPair<QByteArray, QVariant>(json.at(1).toString().toUtf8(), + variant(json.at(2))); } else if (type == "<=") { if (json.size() != 3) INVALID_FILTER(json); _type = LE; - _kv = QPair<QString, QVariant>(json.at(1).toString(), - json.at(2).toVariant()); + _kv = QPair<QByteArray, QVariant>(json.at(1).toString().toUtf8(), + variant(json.at(2))); } else if (type == ">") { if (json.size() != 3) INVALID_FILTER(json); _type = GT; - _kv = QPair<QString, QVariant>(json.at(1).toString(), - json.at(2).toVariant()); + _kv = QPair<QByteArray, QVariant>(json.at(1).toString().toUtf8(), + variant(json.at(2))); } else if (type == ">=") { if (json.size() != 3) INVALID_FILTER(json); _type = GE; - _kv = QPair<QString, QVariant>(json.at(1).toString(), - json.at(2).toVariant()); + _kv = QPair<QByteArray, QVariant>(json.at(1).toString().toUtf8(), + variant(json.at(2))); } else if (type == "all") { _type = All; for (int i = 1; i < json.size(); i++) @@ -91,28 +105,32 @@ if (json.size() < 3) INVALID_FILTER(json); _type = In; - _kv = QPair<QString, QVariant>(json.at(1).toString(), QVariant()); + _kv = QPair<QByteArray, QVariant>(json.at(1).toString().toUtf8(), + QVariant()); for (int i = 2; i < json.size(); i++) - _set.insert(json.at(i).toString()); + _set.insert(json.at(i).toString().toUtf8()); } else if (type == "!in") { if (json.size() < 3) INVALID_FILTER(json); _type = In; _not = true; - _kv = QPair<QString, QVariant>(json.at(1).toString(), QVariant()); + _kv = QPair<QByteArray, QVariant>(json.at(1).toString().toUtf8(), + QVariant()); for (int i = 2; i < json.size(); i++) - _set.insert(json.at(i).toString()); + _set.insert(json.at(i).toString().toUtf8()); } else if (type == "has") { if (json.size() < 2) INVALID_FILTER(json); _type = Has; - _kv = QPair<QString, QVariant>(json.at(1).toString(), QVariant()); + _kv = QPair<QByteArray, QVariant>(json.at(1).toString().toUtf8(), + QVariant()); } else if (type == "!has") { if (json.size() < 2) INVALID_FILTER(json); _type = Has; _not = true; - _kv = QPair<QString, QVariant>(json.at(1).toString(), QVariant()); + _kv = QPair<QByteArray, QVariant>(json.at(1).toString().toUtf8(), + QVariant()); } else INVALID_FILTER(json); } @@ -182,7 +200,7 @@ if (!(v = feature.value(_kv.first))) return _not; else - return _set.contains((*v).toString()) ^ _not; + return _set.contains((*v).toByteArray()) ^ _not; case Has: return (feature.value(_kv.first) ? true : false) ^ _not; case All: @@ -216,7 +234,7 @@ } for (int i = 0; i < keys.size(); i++) { const QString &key = keys.at(i); - const QVariant *val = feature.value(key); + const QVariant *val = feature.value(key.toUtf8()); text.replace(QString("{%1}").arg(key), val ? val->toString() : ""); } @@ -486,7 +504,7 @@ _type = Symbol; // source-layer - _sourceLayer = json["source-layer"].toString(); + _sourceLayer = json["source-layer"].toString().toUtf8(); // zooms if (json.contains("minzoom") && json["minzoom"].isDouble()) @@ -572,7 +590,7 @@ if (QFileInfo::exists(spritesImg)) return sprites.load(spritesJSON, spritesImg); else { - qCritical() << spritesImg << ": no such file"; + qWarning() << spritesImg << ": no such file"; return false; } } @@ -684,7 +702,7 @@ drawBackground(tile); for (int i = 0; i < _layers.size(); i++) { - QHash<QString, PBF::Layer*>::const_iterator it = data.layers().find( + QHash<QByteArray, PBF::Layer*>::const_iterator it = data.layers().find( _layers.at(i).sourceLayer()); if (it == data.layers().constEnd()) continue; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPBFImagePlugin-3.1/src/style.h new/QtPBFImagePlugin-3.2/src/style.h --- old/QtPBFImagePlugin-3.1/src/style.h 2024-06-15 06:01:04.000000000 +0200 +++ new/QtPBFImagePlugin-3.2/src/style.h 2024-10-06 13:24:08.000000000 +0200 @@ -37,7 +37,7 @@ Layer() : _type(Unknown), _minZoom(0), _maxZoom(24) {} Layer(const QJsonObject &json); - const QString &sourceLayer() const {return _sourceLayer;} + const QByteArray &sourceLayer() const {return _sourceLayer;} bool isPath() const {return (_type == Line || _type == Fill);} bool isBackground() const {return (_type == Background);} bool isSymbol() const {return (_type == Symbol);} @@ -74,8 +74,8 @@ Type _type; bool _not; - QSet<QString> _set; - QPair<QString, QVariant> _kv; + QSet<QByteArray> _set; + QPair<QByteArray, QVariant> _kv; QVector<Filter> _filters; }; @@ -167,7 +167,7 @@ }; Type _type; - QString _sourceLayer; + QByteArray _sourceLayer; int _minZoom, _maxZoom; Filter _filter; Layout _layout; ++++++ debian.changelog ++++++ --- /var/tmp/diff_new_pack.Nj10QA/_old 2024-10-06 17:53:19.176465051 +0200 +++ /var/tmp/diff_new_pack.Nj10QA/_new 2024-10-06 17:53:19.180465216 +0200 @@ -1,3 +1,9 @@ +qt5-pbf-image-plugin (3.2) stable; urgency=low + + * Improved rendering performance. + + -- Martin Tuma <tumic@cbox.cz> Sun, 06 Oct 2024 13:58:00 +0200 + qt5-pbf-image-plugin (3.1) stable; urgency=low * Added support for SDF sprites. ++++++ qtpbfplugin.dsc ++++++ --- /var/tmp/diff_new_pack.Nj10QA/_old 2024-10-06 17:53:19.252468208 +0200 +++ /var/tmp/diff_new_pack.Nj10QA/_new 2024-10-06 17:53:19.256468375 +0200 @@ -1,10 +1,10 @@ Format: 1.0 Source: qt5-pbf-image-plugin -Version: 3.1-1 +Version: 3.2-1 Binary: qt5-pbf-image-plugin Maintainer: Martin Tuma <tumic@cbox.cz> Architecture: any Build-Depends: debhelper (>= 9), qtbase5-dev, qtbase5-dev-tools, qt5-qmake, libprotobuf-dev, protobuf-compiler, zlib1g-dev Files: - 00000000000000000000000000000000 0 QtPBFImagePlugin-3.1.tar.gz + 00000000000000000000000000000000 0 QtPBFImagePlugin-3.2.tar.gz
participants (1)
-
Source-Sync