mirror of
https://github.com/overte-org/overte.git
synced 2025-08-08 06:57:37 +02:00
cleanups
This commit is contained in:
parent
8f7f5efade
commit
6e40f03c8e
1 changed files with 7 additions and 8 deletions
|
@ -217,8 +217,6 @@ model::MeshPointer Mesh::map(std::function<glm::vec3(glm::vec3)> vertexFunc,
|
||||||
void Mesh::forEach(std::function<void(glm::vec3)> vertexFunc,
|
void Mesh::forEach(std::function<void(glm::vec3)> vertexFunc,
|
||||||
std::function<void(glm::vec3)> normalFunc,
|
std::function<void(glm::vec3)> normalFunc,
|
||||||
std::function<void(uint32_t)> indexFunc) {
|
std::function<void(uint32_t)> indexFunc) {
|
||||||
int attributeTypeNormal = gpu::Stream::InputSlot::NORMAL; // libraries/gpu/src/gpu/Stream.h
|
|
||||||
|
|
||||||
// vertex data
|
// vertex data
|
||||||
const gpu::BufferView& vertexBufferView = getVertexBuffer();
|
const gpu::BufferView& vertexBufferView = getVertexBuffer();
|
||||||
gpu::BufferView::Index numVertices = (gpu::BufferView::Index)getNumVertices();
|
gpu::BufferView::Index numVertices = (gpu::BufferView::Index)getNumVertices();
|
||||||
|
@ -227,6 +225,7 @@ void Mesh::forEach(std::function<void(glm::vec3)> vertexFunc,
|
||||||
}
|
}
|
||||||
|
|
||||||
// normal data
|
// normal data
|
||||||
|
int attributeTypeNormal = gpu::Stream::InputSlot::NORMAL; // libraries/gpu/src/gpu/Stream.h
|
||||||
const gpu::BufferView& normalsBufferView = getAttributeBuffer(attributeTypeNormal);
|
const gpu::BufferView& normalsBufferView = getAttributeBuffer(attributeTypeNormal);
|
||||||
gpu::BufferView::Index numNormals = (gpu::BufferView::Index)normalsBufferView.getNumElements();
|
gpu::BufferView::Index numNormals = (gpu::BufferView::Index)normalsBufferView.getNumElements();
|
||||||
for (gpu::BufferView::Index i = 0; i < numNormals; i++) {
|
for (gpu::BufferView::Index i = 0; i < numNormals; i++) {
|
||||||
|
|
Loading…
Reference in a new issue