daily update on 20231016 by nitload youmu, vao,vbo,ebo struct added

This commit is contained in:
Nitload
2023-10-17 01:22:30 +08:00
parent 6c3349f5a2
commit 614fabe26c
135 changed files with 28619 additions and 5432 deletions
@@ -3,7 +3,7 @@ using StgSharp.Math;
namespace StgSharp.Geometries
{
internal class Parallelogram : Polygon4
public class Parallelogram : Polygon4
{
internal Point center;
@@ -11,13 +11,35 @@ namespace StgSharp.Geometries
public sealed override Point RefPoint1 => new Point(vertexMat.mat.colum0);
public sealed override Point RefPoint2 => new Point(vertexMat.mat.colum1);
internal readonly GetLocationHandler movCenterOperation = new GetLocationHandler(GeometryOperation.DefualtMotion);
internal readonly GetLocationHandler movCenterOperation =
new GetLocationHandler(GeometryOperation.DefualtMotion);
public GetLocationHandler MovCenterOperation { get { return movCenterOperation; } }
public GetLocationHandler MovVertex01Operation { get { return moveVertex0Operation; } }
public GetLocationHandler MovVertex02Operation { get { return moveVertex1Operation; } }
public virtual Vec3d MovCenter(uint tick)
public Parallelogram(
float v0x, float v0y, float v0z,
float v1x, float v1y, float v1z,
float v2x, float v2y, float v2z,
float v3x, float v3y, float v3z
) : base(
v0x, v0y, v0z,
v1x, v1y, v1z,
v2x, v2y, v2z,
v3x, v2y, v3z
)
{
if (
vertexMat.Colum0 + vertexMat.Colum2 !=
vertexMat.Colum1 + vertexMat.Colum3
)
{
internalIO.InternalWriteLog("Init of geometry item failed, because four vertices cannot form a rectangle.", LogType.Warning);
}
}
public virtual vec3d MovCenter(uint tick)
{
return movCenterOperation.Invoke(tick);
}
@@ -28,7 +50,7 @@ namespace StgSharp.Geometries
/// <param name="tick">Current time tick</param>
/// <returns></returns>
/// <exception cref="UnusedVertexException">Geometry overdefined</exception>
public sealed override Vec3d MoveVertex2(uint tick)
public sealed override vec3d MoveVertex2(uint tick)
{
throw new UnusedVertexException();
}
@@ -39,7 +61,7 @@ namespace StgSharp.Geometries
/// <param name="tick">Current time tick</param>
/// <returns></returns>
/// <exception cref="UnusedVertexException">Geometry overdefined</exception>
public sealed override Vec3d MoveVertex3(uint tick)
public sealed override vec3d MoveVertex3(uint tick)
{
throw new UnusedVertexException();
}