mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-10 22:24:33 +00:00
initial commit jolt
This commit is contained in:
parent
0c2aa5328c
commit
8acf7da95b
1086 changed files with 214612 additions and 4 deletions
|
|
@ -0,0 +1,43 @@
|
|||
// Jolt Physics Library (https://github.com/jrouwe/JoltPhysics)
|
||||
// SPDX-FileCopyrightText: 2021 Jorrit Rouwe
|
||||
// SPDX-License-Identifier: MIT
|
||||
|
||||
#include <TestFramework.h>
|
||||
|
||||
#include <Renderer/RenderPrimitive.h>
|
||||
|
||||
void RenderPrimitive::ReleaseVertexBuffer()
|
||||
{
|
||||
mNumVtx = 0;
|
||||
mNumVtxToDraw = 0;
|
||||
mVtxSize = 0;
|
||||
}
|
||||
|
||||
void RenderPrimitive::ReleaseIndexBuffer()
|
||||
{
|
||||
mNumIdx = 0;
|
||||
mNumIdxToDraw = 0;
|
||||
}
|
||||
|
||||
void RenderPrimitive::Clear()
|
||||
{
|
||||
ReleaseVertexBuffer();
|
||||
ReleaseIndexBuffer();
|
||||
}
|
||||
|
||||
void RenderPrimitive::CreateVertexBuffer(int inNumVtx, int inVtxSize, const void *inData)
|
||||
{
|
||||
ReleaseVertexBuffer();
|
||||
|
||||
mNumVtx = inNumVtx;
|
||||
mNumVtxToDraw = inNumVtx;
|
||||
mVtxSize = inVtxSize;
|
||||
}
|
||||
|
||||
void RenderPrimitive::CreateIndexBuffer(int inNumIdx, const uint32 *inData)
|
||||
{
|
||||
ReleaseIndexBuffer();
|
||||
|
||||
mNumIdx = inNumIdx;
|
||||
mNumIdxToDraw = inNumIdx;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue