mirror of
https://thingvellir.net/git/overte
synced 2025-03-27 23:52:03 +01:00
vive coordinates in clip space
This commit is contained in:
parent
4e4526fbb2
commit
8d2495ef7a
1 changed files with 2 additions and 1 deletions
|
@ -802,7 +802,8 @@ DisplayPlugin::StencilMaskMeshOperator OpenVrDisplayPlugin::getStencilMaskMeshOp
|
|||
indices.reserve(numIndices);
|
||||
for (int i = 0; i < numIndices; i++) {
|
||||
vr::HmdVector2_t vertex2D = stencilMesh.pVertexData[i];
|
||||
vertices.emplace_back(vertex2D.v[0], vertex2D.v[1], 0.0f);
|
||||
// We need the vertices in clip space
|
||||
vertices.emplace_back(vertex2D.v[0] - (1.0f - (float)eye), 2.0f * vertex2D.v[1] - 1.0f, 0.0f);
|
||||
indices.push_back(i);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue