Added Summeries

This commit is contained in:
Michel Fedde 2021-03-19 20:59:02 +01:00
parent 71a22df8bd
commit 8296d9b8a9
47 changed files with 812 additions and 177 deletions

View file

@ -13,9 +13,7 @@ namespace SM.OGL.Mesh
public abstract class GenericMesh : GLObject
{
private bool _boundingBoxUpdated = false;
public static int LastID { get; internal set; } = -1;
/// <inheritdoc />
protected override bool AutoCompile { get; set; } = true;
@ -71,12 +69,18 @@ namespace SM.OGL.Mesh
};
}
/// <summary>
/// Updates the object bounding box.
/// </summary>
public void UpdateBoundingBox()
{
BoundingBox.Update(this);
_boundingBoxUpdated = true;
}
/// <summary>
/// Activates the object to be rendered.
/// </summary>
public void Activate()
{
GL.BindVertexArray(ID);
@ -99,6 +103,7 @@ namespace SM.OGL.Mesh
GL.BindVertexArray(0);
}
/// <inheritdoc />
public override void Dispose()
{
GL.DeleteVertexArray(_id);