[core] sizeof(SymbolBucket) 2312 -> 2296
This commit is contained in:
@@ -25,10 +25,16 @@ SymbolBucket::SymbolBucket(style::SymbolLayoutProperties::PossiblyEvaluated layo
|
||||
const std::vector<SymbolInstance>&& symbolInstances_,
|
||||
float tilePixelRatio_)
|
||||
: layout(std::move(layout_)),
|
||||
bucketLeaderID(std::move(bucketName_)),
|
||||
sdfIcons(sdfIcons_),
|
||||
iconsNeedLinear(iconsNeedLinear_ || iconSize.isDataDriven() || !iconSize.isZoomConstant()),
|
||||
sortFeaturesByY(sortFeaturesByY_),
|
||||
bucketLeaderID(std::move(bucketName_)),
|
||||
staticUploaded(false),
|
||||
placementChangesUploaded(false),
|
||||
dynamicUploaded(false),
|
||||
sortUploaded(false),
|
||||
justReloaded(false),
|
||||
hasVariablePlacement(false),
|
||||
symbolInstances(std::move(symbolInstances_)),
|
||||
textSizeBinder(SymbolSizeBinder::create(zoom, textSize, TextSize::defaultValue())),
|
||||
iconSizeBinder(SymbolSizeBinder::create(zoom, iconSize, IconSize::defaultValue())),
|
||||
@@ -170,8 +176,9 @@ void SymbolBucket::sortFeatures(const float angle) {
|
||||
if (!sortFeaturesByY) {
|
||||
return;
|
||||
}
|
||||
assert (angle != std::numeric_limits<float>::max());
|
||||
|
||||
if (sortedAngle && *sortedAngle == angle) {
|
||||
if (sortedAngle == angle) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -73,18 +73,19 @@ public:
|
||||
std::vector<std::reference_wrapper<SymbolInstance>> getSortedSymbols(const float angle);
|
||||
|
||||
const style::SymbolLayoutProperties::PossiblyEvaluated layout;
|
||||
const bool sdfIcons;
|
||||
const bool iconsNeedLinear;
|
||||
const bool sortFeaturesByY;
|
||||
|
||||
const std::string bucketLeaderID;
|
||||
float sortedAngle = std::numeric_limits<float>::max();
|
||||
|
||||
optional<float> sortedAngle;
|
||||
|
||||
bool staticUploaded = false;
|
||||
bool placementChangesUploaded = false;
|
||||
bool dynamicUploaded = false;
|
||||
bool sortUploaded = false;
|
||||
// Flags
|
||||
const bool sdfIcons : 1;
|
||||
const bool iconsNeedLinear : 1;
|
||||
const bool sortFeaturesByY : 1;
|
||||
bool staticUploaded : 1;
|
||||
bool placementChangesUploaded : 1;
|
||||
bool dynamicUploaded : 1;
|
||||
bool sortUploaded : 1;
|
||||
bool justReloaded : 1;
|
||||
bool hasVariablePlacement : 1;
|
||||
|
||||
std::vector<SymbolInstance> symbolInstances;
|
||||
|
||||
@@ -137,8 +138,7 @@ public:
|
||||
|
||||
const float tilePixelRatio;
|
||||
uint32_t bucketInstanceId;
|
||||
bool justReloaded = false;
|
||||
bool hasVariablePlacement = false;
|
||||
|
||||
mutable optional<bool> hasFormatSectionOverrides_;
|
||||
|
||||
std::shared_ptr<std::vector<size_t>> featureSortOrder;
|
||||
|
||||
Reference in New Issue
Block a user