-
Notifications
You must be signed in to change notification settings - Fork 73
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #812 from hypar-io/tess-boost
16% memory reduction and small speed improvements for glTF creation.
- Loading branch information
Showing
24 changed files
with
277 additions
and
174 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
using Elements.Geometry; | ||
|
||
namespace Elements | ||
{ | ||
/// <summary> | ||
/// A generic container for graphics data. This is broken out primarily to facilitate | ||
/// simpler testing of graphics buffers. | ||
/// </summary> | ||
internal interface IGraphicsBuffers | ||
{ | ||
/// <summary> | ||
/// Initialize a graphics buffer to a sepcific vertex size. | ||
/// </summary> | ||
/// <param name="vertexCount">The number of vertices.</param> | ||
/// <param name="indexCount">The number of indices.</param> | ||
void Initialize(int vertexCount, int indexCount); | ||
|
||
/// <summary> | ||
/// Add a vertex to the graphics buffers. | ||
/// </summary> | ||
/// <param name="position">The position of the vertex.</param> | ||
/// <param name="normal">The normal of the vertex.</param> | ||
/// <param name="uv">The UV of the vertex.</param> | ||
/// <param name="color">The vertex color.</param> | ||
void AddVertex(Vector3 position, Vector3 normal, UV uv, Color? color = null); | ||
|
||
/// <summary> | ||
/// Add a vertex to the graphics buffers. | ||
/// </summary> | ||
/// <param name="x"></param> | ||
/// <param name="y"></param> | ||
/// <param name="z"></param> | ||
/// <param name="nx"></param> | ||
/// <param name="ny"></param> | ||
/// <param name="nz"></param> | ||
/// <param name="u"></param> | ||
/// <param name="v"></param> | ||
/// <param name="color"></param> | ||
void AddVertex(double x, double y, double z, double nx, double ny, double nz, double u, double v, Color? color = null); | ||
|
||
/// <summary> | ||
/// Add an index to the graphics buffers. | ||
/// </summary> | ||
/// <param name="index">The index to add.</param> | ||
void AddIndex(ushort index); | ||
} | ||
} |
Oops, something went wrong.