summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKonstantin Käfer <mail@kkaefer.com>2019-03-05 15:37:01 +0100
committerKonstantin Käfer <mail@kkaefer.com>2019-03-06 16:12:51 +0100
commitf13c2b86e427e29a856ca8f0f79379203c61f431 (patch)
treeb41fd7ab9d8d9b0e20caa31c161df684a844a3ae
parent2f646af255bf05bd50070deb83bb89e48509afc4 (diff)
downloadqtlocation-mapboxgl-f13c2b86e427e29a856ca8f0f79379203c61f431.tar.gz
[core] unify *Buffer/Vector naming
-rw-r--r--src/mbgl/gfx/index_vector.hpp4
-rw-r--r--src/mbgl/gfx/vertex_vector.hpp4
-rw-r--r--src/mbgl/gl/context.hpp16
-rw-r--r--src/mbgl/gl/index_buffer.hpp2
-rw-r--r--src/mbgl/gl/vertex_buffer.hpp2
-rw-r--r--src/mbgl/layout/symbol_layout.cpp10
-rw-r--r--src/mbgl/programs/collision_box_program.hpp2
-rw-r--r--src/mbgl/programs/symbol_program.hpp4
-rw-r--r--src/mbgl/renderer/buckets/circle_bucket.cpp4
-rw-r--r--src/mbgl/renderer/buckets/debug_bucket.cpp6
-rw-r--r--src/mbgl/renderer/buckets/fill_bucket.cpp10
-rw-r--r--src/mbgl/renderer/buckets/fill_extrusion_bucket.cpp8
-rw-r--r--src/mbgl/renderer/buckets/heatmap_bucket.cpp4
-rw-r--r--src/mbgl/renderer/buckets/hillshade_bucket.cpp2
-rw-r--r--src/mbgl/renderer/buckets/line_bucket.cpp16
-rw-r--r--src/mbgl/renderer/buckets/raster_bucket.cpp2
-rw-r--r--src/mbgl/renderer/paint_property_binder.hpp8
17 files changed, 52 insertions, 52 deletions
diff --git a/src/mbgl/gfx/index_vector.hpp b/src/mbgl/gfx/index_vector.hpp
index b477c29782..dc760feb90 100644
--- a/src/mbgl/gfx/index_vector.hpp
+++ b/src/mbgl/gfx/index_vector.hpp
@@ -18,11 +18,11 @@ public:
util::ignore({ (v.emplace_back(std::forward<Args>(args)), 0)... });
}
- std::size_t indexSize() const {
+ std::size_t elements() const {
return v.size();
}
- std::size_t byteSize() const {
+ std::size_t bytes() const {
return v.size() * sizeof(uint16_t);
}
diff --git a/src/mbgl/gfx/vertex_vector.hpp b/src/mbgl/gfx/vertex_vector.hpp
index 5d892e9136..f41f842294 100644
--- a/src/mbgl/gfx/vertex_vector.hpp
+++ b/src/mbgl/gfx/vertex_vector.hpp
@@ -18,11 +18,11 @@ public:
util::ignore({ (v.emplace_back(std::forward<Args>(args)), 0)... });
}
- std::size_t vertexSize() const {
+ std::size_t elements() const {
return v.size();
}
- std::size_t byteSize() const {
+ std::size_t bytes() const {
return v.size() * sizeof(Vertex);
}
diff --git a/src/mbgl/gl/context.hpp b/src/mbgl/gl/context.hpp
index 85e35d4d70..ad62853495 100644
--- a/src/mbgl/gl/context.hpp
+++ b/src/mbgl/gl/context.hpp
@@ -68,29 +68,29 @@ public:
template <class Vertex>
VertexBuffer<Vertex> createVertexBuffer(gfx::VertexVector<Vertex>&& v, const BufferUsage usage = BufferUsage::StaticDraw) {
return VertexBuffer<Vertex> {
- v.vertexSize(),
- createVertexBuffer(v.data(), v.byteSize(), usage)
+ v.elements(),
+ createVertexBuffer(v.data(), v.bytes(), usage)
};
}
template <class Vertex>
void updateVertexBuffer(VertexBuffer<Vertex>& buffer, gfx::VertexVector<Vertex>&& v) {
- assert(v.vertexSize() == buffer.vertexCount);
- updateVertexBuffer(buffer.buffer, v.data(), v.byteSize());
+ assert(v.elements() == buffer.elements);
+ updateVertexBuffer(buffer.buffer, v.data(), v.bytes());
}
template <class DrawMode>
IndexBuffer createIndexBuffer(gfx::IndexVector<DrawMode>&& v, const BufferUsage usage = BufferUsage::StaticDraw) {
return IndexBuffer {
- v.indexSize(),
- createIndexBuffer(v.data(), v.byteSize(), usage)
+ v.elements(),
+ createIndexBuffer(v.data(), v.bytes(), usage)
};
}
template <class DrawMode>
void updateIndexBuffer(IndexBuffer& buffer, gfx::IndexVector<DrawMode>&& v) {
- assert(v.indexSize() == buffer.indexCount);
- updateIndexBuffer(buffer.buffer, v.data(), v.byteSize());
+ assert(v.elements() == buffer.elements);
+ updateIndexBuffer(buffer.buffer, v.data(), v.bytes());
}
template <RenderbufferType type>
diff --git a/src/mbgl/gl/index_buffer.hpp b/src/mbgl/gl/index_buffer.hpp
index a506c5eacd..3b66e2b69c 100644
--- a/src/mbgl/gl/index_buffer.hpp
+++ b/src/mbgl/gl/index_buffer.hpp
@@ -7,7 +7,7 @@ namespace gl {
class IndexBuffer {
public:
- std::size_t indexCount;
+ std::size_t elements;
UniqueBuffer buffer;
};
diff --git a/src/mbgl/gl/vertex_buffer.hpp b/src/mbgl/gl/vertex_buffer.hpp
index b65e7f9a01..94963ce878 100644
--- a/src/mbgl/gl/vertex_buffer.hpp
+++ b/src/mbgl/gl/vertex_buffer.hpp
@@ -8,7 +8,7 @@ namespace gl {
template <class V>
class VertexBuffer {
public:
- std::size_t vertexCount;
+ std::size_t elements;
UniqueBuffer buffer;
};
diff --git a/src/mbgl/layout/symbol_layout.cpp b/src/mbgl/layout/symbol_layout.cpp
index edacaf9dda..4041b16a65 100644
--- a/src/mbgl/layout/symbol_layout.cpp
+++ b/src/mbgl/layout/symbol_layout.cpp
@@ -470,8 +470,8 @@ void SymbolLayout::createBucket(const ImagePositions&, std::unique_ptr<FeatureIn
}
for (auto& pair : bucket->paintProperties) {
- pair.second.iconBinders.populateVertexVectors(feature, bucket->icon.vertices.vertexSize(), {}, {});
- pair.second.textBinders.populateVertexVectors(feature, bucket->text.vertices.vertexSize(), {}, {});
+ pair.second.iconBinders.populateVertexVectors(feature, bucket->icon.vertices.elements(), {}, {});
+ pair.second.textBinders.populateVertexVectors(feature, bucket->text.vertices.elements(), {}, {});
}
}
@@ -504,7 +504,7 @@ size_t SymbolLayout::addSymbol(Buffer& buffer,
const auto &tex = symbol.tex;
if (buffer.segments.empty() || buffer.segments.back().vertexLength + vertexLength > std::numeric_limits<uint16_t>::max()) {
- buffer.segments.emplace_back(buffer.vertices.vertexSize(), buffer.triangles.indexSize());
+ buffer.segments.emplace_back(buffer.vertices.elements(), buffer.triangles.elements());
}
// We're generating triangle fans, so we always start with the first
@@ -568,8 +568,8 @@ void SymbolLayout::addToDebugBuffers(SymbolBucket& bucket) {
const std::size_t indexLength = feature.alongLine ? 6 : 8;
if (collisionBuffer.segments.empty() || collisionBuffer.segments.back().vertexLength + vertexLength > std::numeric_limits<uint16_t>::max()) {
- collisionBuffer.segments.emplace_back(collisionBuffer.vertices.vertexSize(),
- feature.alongLine? bucket.collisionCircle.triangles.indexSize() : bucket.collisionBox.lines.indexSize());
+ collisionBuffer.segments.emplace_back(collisionBuffer.vertices.elements(),
+ feature.alongLine? bucket.collisionCircle.triangles.elements() : bucket.collisionBox.lines.elements());
}
auto& segment = collisionBuffer.segments.back();
diff --git a/src/mbgl/programs/collision_box_program.hpp b/src/mbgl/programs/collision_box_program.hpp
index b8b5c7e054..ce672705f8 100644
--- a/src/mbgl/programs/collision_box_program.hpp
+++ b/src/mbgl/programs/collision_box_program.hpp
@@ -78,7 +78,7 @@ public:
.concat(gl::Attributes<CollisionBoxDynamicAttributes>::bindings(dynamicVertexBuffer))
.concat(paintPropertyBinders.attributeBindings(currentProperties));
- assert(layoutVertexBuffer.vertexCount == dynamicVertexBuffer.vertexCount);
+ assert(layoutVertexBuffer.elements == dynamicVertexBuffer.elements);
for (auto& segment : segments) {
auto vertexArrayIt = segment.vertexArrays.find(layerID);
diff --git a/src/mbgl/programs/symbol_program.hpp b/src/mbgl/programs/symbol_program.hpp
index 2eb1c0b4cd..1bb2580c1e 100644
--- a/src/mbgl/programs/symbol_program.hpp
+++ b/src/mbgl/programs/symbol_program.hpp
@@ -291,8 +291,8 @@ public:
const gl::VertexBuffer<gfx::Vertex<SymbolOpacityAttributes>>& opacityVertexBuffer,
const Binders& paintPropertyBinders,
const typename PaintProperties::PossiblyEvaluated& currentProperties) {
- assert(layoutVertexBuffer.vertexCount == dynamicLayoutVertexBuffer.vertexCount &&
- layoutVertexBuffer.vertexCount == opacityVertexBuffer.vertexCount);
+ assert(layoutVertexBuffer.elements == dynamicLayoutVertexBuffer.elements &&
+ layoutVertexBuffer.elements == opacityVertexBuffer.elements);
return gl::Attributes<LayoutAttributeList>::bindings(layoutVertexBuffer)
.concat(gl::Attributes<SymbolDynamicLayoutAttributes>::bindings(dynamicLayoutVertexBuffer))
.concat(gl::Attributes<SymbolOpacityAttributes>::bindings(opacityVertexBuffer))
diff --git a/src/mbgl/renderer/buckets/circle_bucket.cpp b/src/mbgl/renderer/buckets/circle_bucket.cpp
index bf54205978..8ebc685df3 100644
--- a/src/mbgl/renderer/buckets/circle_bucket.cpp
+++ b/src/mbgl/renderer/buckets/circle_bucket.cpp
@@ -62,7 +62,7 @@ void CircleBucket::addFeature(const GeometryTileFeature& feature,
if (segments.empty() || segments.back().vertexLength + vertexLength > std::numeric_limits<uint16_t>::max()) {
// Move to a new segments because the old one can't hold the geometry.
- segments.emplace_back(vertices.vertexSize(), triangles.indexSize());
+ segments.emplace_back(vertices.elements(), triangles.elements());
}
// this geometry will be of the Point type, and we'll derive
@@ -94,7 +94,7 @@ void CircleBucket::addFeature(const GeometryTileFeature& feature,
}
for (auto& pair : paintPropertyBinders) {
- pair.second.populateVertexVectors(feature, vertices.vertexSize(), {}, {});
+ pair.second.populateVertexVectors(feature, vertices.elements(), {}, {});
}
}
diff --git a/src/mbgl/renderer/buckets/debug_bucket.cpp b/src/mbgl/renderer/buckets/debug_bucket.cpp
index ca96bb62d2..0de6cccdb2 100644
--- a/src/mbgl/renderer/buckets/debug_bucket.cpp
+++ b/src/mbgl/renderer/buckets/debug_bucket.cpp
@@ -46,8 +46,8 @@ DebugBucket::DebugBucket(const OverscaledTileID& id,
vertices.emplace_back(FillProgram::layoutVertex(p));
if (prev) {
- indices.emplace_back(vertices.vertexSize() - 2,
- vertices.vertexSize() - 1);
+ indices.emplace_back(vertices.elements() - 2,
+ vertices.elements() - 1);
}
prev = p;
@@ -74,7 +74,7 @@ DebugBucket::DebugBucket(const OverscaledTileID& id,
addText(expiresText, 50, baseline + 200, 5);
}
- segments.emplace_back(0, 0, vertices.vertexSize(), indices.indexSize());
+ segments.emplace_back(0, 0, vertices.elements(), indices.elements());
vertexBuffer = context.createVertexBuffer(std::move(vertices));
indexBuffer = context.createIndexBuffer(std::move(indices));
diff --git a/src/mbgl/renderer/buckets/fill_bucket.cpp b/src/mbgl/renderer/buckets/fill_bucket.cpp
index 517c9b184a..302b708713 100644
--- a/src/mbgl/renderer/buckets/fill_bucket.cpp
+++ b/src/mbgl/renderer/buckets/fill_bucket.cpp
@@ -60,7 +60,7 @@ void FillBucket::addFeature(const GeometryTileFeature& feature,
throw GeometryTooLongException();
}
- std::size_t startVertices = vertices.vertexSize();
+ std::size_t startVertices = vertices.elements();
for (const auto& ring : polygon) {
std::size_t nVertices = ring.size();
@@ -69,7 +69,7 @@ void FillBucket::addFeature(const GeometryTileFeature& feature,
continue;
if (lineSegments.empty() || lineSegments.back().vertexLength + nVertices > std::numeric_limits<uint16_t>::max()) {
- lineSegments.emplace_back(vertices.vertexSize(), lines.indexSize());
+ lineSegments.emplace_back(vertices.elements(), lines.elements());
}
auto& lineSegment = lineSegments.back();
@@ -94,7 +94,7 @@ void FillBucket::addFeature(const GeometryTileFeature& feature,
assert(nIndicies % 3 == 0);
if (triangleSegments.empty() || triangleSegments.back().vertexLength + totalVertices > std::numeric_limits<uint16_t>::max()) {
- triangleSegments.emplace_back(startVertices, triangles.indexSize());
+ triangleSegments.emplace_back(startVertices, triangles.elements());
}
auto& triangleSegment = triangleSegments.back();
@@ -114,9 +114,9 @@ void FillBucket::addFeature(const GeometryTileFeature& feature,
for (auto& pair : paintPropertyBinders) {
const auto it = patternDependencies.find(pair.first);
if (it != patternDependencies.end()){
- pair.second.populateVertexVectors(feature, vertices.vertexSize(), patternPositions, it->second);
+ pair.second.populateVertexVectors(feature, vertices.elements(), patternPositions, it->second);
} else {
- pair.second.populateVertexVectors(feature, vertices.vertexSize(), patternPositions, {});
+ pair.second.populateVertexVectors(feature, vertices.elements(), patternPositions, {});
}
}
}
diff --git a/src/mbgl/renderer/buckets/fill_extrusion_bucket.cpp b/src/mbgl/renderer/buckets/fill_extrusion_bucket.cpp
index 7b932e6b2b..77d9bfd907 100644
--- a/src/mbgl/renderer/buckets/fill_extrusion_bucket.cpp
+++ b/src/mbgl/renderer/buckets/fill_extrusion_bucket.cpp
@@ -71,12 +71,12 @@ void FillExtrusionBucket::addFeature(const GeometryTileFeature& feature,
std::vector<uint32_t> flatIndices;
flatIndices.reserve(totalVertices);
- std::size_t startVertices = vertices.vertexSize();
+ std::size_t startVertices = vertices.elements();
if (triangleSegments.empty() ||
triangleSegments.back().vertexLength + (5 * (totalVertices - 1) + 1) >
std::numeric_limits<uint16_t>::max()) {
- triangleSegments.emplace_back(startVertices, triangles.indexSize());
+ triangleSegments.emplace_back(startVertices, triangles.elements());
}
auto& triangleSegment = triangleSegments.back();
@@ -158,9 +158,9 @@ void FillExtrusionBucket::addFeature(const GeometryTileFeature& feature,
for (auto& pair : paintPropertyBinders) {
const auto it = patternDependencies.find(pair.first);
if (it != patternDependencies.end()){
- pair.second.populateVertexVectors(feature, vertices.vertexSize(), patternPositions, it->second);
+ pair.second.populateVertexVectors(feature, vertices.elements(), patternPositions, it->second);
} else {
- pair.second.populateVertexVectors(feature, vertices.vertexSize(), patternPositions, {});
+ pair.second.populateVertexVectors(feature, vertices.elements(), patternPositions, {});
}
}
}
diff --git a/src/mbgl/renderer/buckets/heatmap_bucket.cpp b/src/mbgl/renderer/buckets/heatmap_bucket.cpp
index 28d2efe302..ca1264305f 100644
--- a/src/mbgl/renderer/buckets/heatmap_bucket.cpp
+++ b/src/mbgl/renderer/buckets/heatmap_bucket.cpp
@@ -61,7 +61,7 @@ void HeatmapBucket::addFeature(const GeometryTileFeature& feature,
if (segments.empty() || segments.back().vertexLength + vertexLength > std::numeric_limits<uint16_t>::max()) {
// Move to a new segments because the old one can't hold the geometry.
- segments.emplace_back(vertices.vertexSize(), triangles.indexSize());
+ segments.emplace_back(vertices.elements(), triangles.elements());
}
// this geometry will be of the Point type, and we'll derive
@@ -93,7 +93,7 @@ void HeatmapBucket::addFeature(const GeometryTileFeature& feature,
}
for (auto& pair : paintPropertyBinders) {
- pair.second.populateVertexVectors(feature, vertices.vertexSize(), {}, {});
+ pair.second.populateVertexVectors(feature, vertices.elements(), {}, {});
}
}
diff --git a/src/mbgl/renderer/buckets/hillshade_bucket.cpp b/src/mbgl/renderer/buckets/hillshade_bucket.cpp
index 8dda9dd376..6affd53196 100644
--- a/src/mbgl/renderer/buckets/hillshade_bucket.cpp
+++ b/src/mbgl/renderer/buckets/hillshade_bucket.cpp
@@ -84,7 +84,7 @@ void HillshadeBucket::setMask(TileMask&& mask_) {
if (segments.back().vertexLength + vertexLength > std::numeric_limits<uint16_t>::max()) {
// Move to a new segments because the old one can't hold the geometry.
- segments.emplace_back(vertices.vertexSize(), indices.indexSize());
+ segments.emplace_back(vertices.elements(), indices.elements());
}
vertices.emplace_back(
diff --git a/src/mbgl/renderer/buckets/line_bucket.cpp b/src/mbgl/renderer/buckets/line_bucket.cpp
index f17a309163..8d13bf0793 100644
--- a/src/mbgl/renderer/buckets/line_bucket.cpp
+++ b/src/mbgl/renderer/buckets/line_bucket.cpp
@@ -41,9 +41,9 @@ void LineBucket::addFeature(const GeometryTileFeature& feature,
for (auto& pair : paintPropertyBinders) {
const auto it = patternDependencies.find(pair.first);
if (it != patternDependencies.end()){
- pair.second.populateVertexVectors(feature, vertices.vertexSize(), patternPositions, it->second);
+ pair.second.populateVertexVectors(feature, vertices.elements(), patternPositions, it->second);
} else {
- pair.second.populateVertexVectors(feature, vertices.vertexSize(), patternPositions, {});
+ pair.second.populateVertexVectors(feature, vertices.elements(), patternPositions, {});
}
}
}
@@ -164,7 +164,7 @@ void LineBucket::addGeometry(const GeometryCoordinates& coordinates, const Geome
nextNormal = util::perp(util::unit(convertPoint<double>(firstCoordinate - *currentCoordinate)));
}
- const std::size_t startVertex = vertices.vertexSize();
+ const std::size_t startVertex = vertices.elements();
std::vector<TriangleElement> triangleStore;
for (std::size_t i = first; i < len; ++i) {
@@ -421,11 +421,11 @@ void LineBucket::addGeometry(const GeometryCoordinates& coordinates, const Geome
startOfLine = false;
}
- const std::size_t endVertex = vertices.vertexSize();
+ const std::size_t endVertex = vertices.elements();
const std::size_t vertexCount = endVertex - startVertex;
if (segments.empty() || segments.back().vertexLength + vertexCount > std::numeric_limits<uint16_t>::max()) {
- segments.emplace_back(startVertex, triangles.indexSize());
+ segments.emplace_back(startVertex, triangles.elements());
}
auto& segment = segments.back();
@@ -455,7 +455,7 @@ void LineBucket::addCurrentVertex(const GeometryCoordinate& currentCoordinate,
if (endLeft)
extrude = extrude - (util::perp(normal) * endLeft);
vertices.emplace_back(LineProgram::layoutVertex(currentCoordinate, extrude, round, false, endLeft, scaledDistance * LINE_DISTANCE_SCALE));
- e3 = vertices.vertexSize() - 1 - startVertex;
+ e3 = vertices.elements() - 1 - startVertex;
if (e1 >= 0 && e2 >= 0) {
triangleStore.emplace_back(e1, e2, e3);
}
@@ -466,7 +466,7 @@ void LineBucket::addCurrentVertex(const GeometryCoordinate& currentCoordinate,
if (endRight)
extrude = extrude - (util::perp(normal) * endRight);
vertices.emplace_back(LineProgram::layoutVertex(currentCoordinate, extrude, round, true, -endRight, scaledDistance * LINE_DISTANCE_SCALE));
- e3 = vertices.vertexSize() - 1 - startVertex;
+ e3 = vertices.elements() - 1 - startVertex;
if (e1 >= 0 && e2 >= 0) {
triangleStore.emplace_back(e1, e2, e3);
}
@@ -496,7 +496,7 @@ void LineBucket::addPieSliceVertex(const GeometryCoordinate& currentVertex,
}
vertices.emplace_back(LineProgram::layoutVertex(currentVertex, flippedExtrude, false, lineTurnsLeft, 0, distance * LINE_DISTANCE_SCALE));
- e3 = vertices.vertexSize() - 1 - startVertex;
+ e3 = vertices.elements() - 1 - startVertex;
if (e1 >= 0 && e2 >= 0) {
triangleStore.emplace_back(e1, e2, e3);
}
diff --git a/src/mbgl/renderer/buckets/raster_bucket.cpp b/src/mbgl/renderer/buckets/raster_bucket.cpp
index 47d6d0b96f..a1884b8f7a 100644
--- a/src/mbgl/renderer/buckets/raster_bucket.cpp
+++ b/src/mbgl/renderer/buckets/raster_bucket.cpp
@@ -79,7 +79,7 @@ void RasterBucket::setMask(TileMask&& mask_) {
if (segments.back().vertexLength + vertexLength > std::numeric_limits<uint16_t>::max()) {
// Move to a new segments because the old one can't hold the geometry.
- segments.emplace_back(vertices.vertexSize(), indices.indexSize());
+ segments.emplace_back(vertices.elements(), indices.elements());
}
vertices.emplace_back(
diff --git a/src/mbgl/renderer/paint_property_binder.hpp b/src/mbgl/renderer/paint_property_binder.hpp
index cbf60ea679..cb4c3b5519 100644
--- a/src/mbgl/renderer/paint_property_binder.hpp
+++ b/src/mbgl/renderer/paint_property_binder.hpp
@@ -187,7 +187,7 @@ public:
auto evaluated = expression.evaluate(feature, defaultValue);
this->statistics.add(evaluated);
auto value = attributeValue(evaluated);
- for (std::size_t i = vertexVector.vertexSize(); i < length; ++i) {
+ for (std::size_t i = vertexVector.elements(); i < length; ++i) {
vertexVector.emplace_back(BaseVertex { value });
}
}
@@ -247,7 +247,7 @@ public:
AttributeValue value = zoomInterpolatedAttributeValue(
attributeValue(range.min),
attributeValue(range.max));
- for (std::size_t i = vertexVector.vertexSize(); i < length; ++i) {
+ for (std::size_t i = vertexVector.elements(); i < length; ++i) {
vertexVector.emplace_back(Vertex { value });
}
}
@@ -319,7 +319,7 @@ public:
// Unlike other propperties with expressions that evaluate to null, the default value for `*-pattern` properties is an empty
// string and will not have a valid entry in patternPositions. We still need to populate the attribute buffers to avoid crashes
// when we try to draw the layer because we don't know at draw time if all features were evaluated to valid pattern dependencies.
- for (std::size_t i = zoomInVertexVector.vertexSize(); i < length; ++i) {
+ for (std::size_t i = zoomInVertexVector.elements(); i < length; ++i) {
patternToVertexVector.emplace_back(Vertex { std::array<uint16_t, 4>{{0, 0, 0, 0}} });
zoomInVertexVector.emplace_back(Vertex2 { std::array<uint16_t, 4>{{0, 0, 0, 0}} } );
zoomOutVertexVector.emplace_back(Vertex2 { std::array<uint16_t, 4>{{0, 0, 0, 0}} });
@@ -336,7 +336,7 @@ public:
const ImagePosition imageMid = mid->second;
const ImagePosition imageMax = max->second;
- for (std::size_t i = zoomInVertexVector.vertexSize(); i < length; ++i) {
+ for (std::size_t i = zoomInVertexVector.elements(); i < length; ++i) {
patternToVertexVector.emplace_back(Vertex { imageMid.tlbr() });
zoomInVertexVector.emplace_back(Vertex2 { imageMin.tlbr() });
zoomOutVertexVector.emplace_back(Vertex2 { imageMax.tlbr() });