History

fix warning about implicit cast from 64 to 32 bits

Andrew Meadows committed 9 years ago

Commit d9ba75c1 parent 886422c1 file · +4 −4Browse files

Showing the changes to libraries/render-utils/src/GeometryCache.cpp (1 of 1 file). Show all

Unified · Split

libraries/render-utils/src/GeometryCache.cpp+4−4
@@ -120,7 +120,7 @@ void GeometryCache::ShapeData::setupBatch(gpu::Batch& batch) const { · 119 unmodified lines
120120 }
121121
122122 void GeometryCache::ShapeData::draw(gpu::Batch& batch) const {
123− gpu::Buffer::Size numIndices = _indicesView.getNumElements();
123+ uint32_t numIndices = (uint32_t)_indicesView.getNumElements();
124124 if (numIndices > 0) {
125125 setupBatch(batch);
126126 batch.drawIndexed(gpu::TRIANGLES, numIndices, 0);
@@ -128,7 +128,7 @@ void GeometryCache::ShapeData::draw(gpu::Batch& batch) const { · 1 unmodified line
128128 }
129129
130130 void GeometryCache::ShapeData::drawWire(gpu::Batch& batch) const {
131− gpu::Buffer::Size numIndices = _wireIndicesView.getNumElements();
131+ uint32_t numIndices = (uint32_t)_wireIndicesView.getNumElements();
132132 if (numIndices > 0) {
133133 batch.setInputBuffer(gpu::Stream::POSITION, _positionView);
134134 batch.setInputBuffer(gpu::Stream::NORMAL, _normalView);
@@ -138,7 +138,7 @@ void GeometryCache::ShapeData::drawWire(gpu::Batch& batch) const { · 3 unmodified lines
138138 }
139139
140140 void GeometryCache::ShapeData::drawInstances(gpu::Batch& batch, size_t count) const {
141− gpu::Buffer::Size numIndices = _indicesView.getNumElements();
141+ uint32_t numIndices = (uint32_t)_indicesView.getNumElements();
142142 if (numIndices > 0) {
143143 setupBatch(batch);
144144 batch.drawIndexedInstanced((gpu::uint32)count, gpu::TRIANGLES, numIndices, 0);
@@ -146,7 +146,7 @@ void GeometryCache::ShapeData::drawInstances(gpu::Batch& batch, size_t count) co · 1 unmodified line
146146 }
147147
148148 void GeometryCache::ShapeData::drawWireInstances(gpu::Batch& batch, size_t count) const {
149− gpu::Buffer::Size numIndices = _wireIndicesView.getNumElements();
149+ uint32_t numIndices = (uint32_t)_wireIndicesView.getNumElements();
150150 if (numIndices > 0) {
151151 batch.setInputBuffer(gpu::Stream::POSITION, _positionView);
152152 batch.setInputBuffer(gpu::Stream::NORMAL, _normalView);

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t