- Fixed bug in builder when no content files exist

This commit is contained in:
2024-07-12 23:10:44 +02:00
parent d45f7c3b8c
commit 1096597161
23 changed files with 1096 additions and 32 deletions
+33
View File
@@ -0,0 +1,33 @@
using Nerfed.Runtime.Graphics;
using System.Numerics;
using System.Runtime.InteropServices;
namespace Nerfed.Runtime.Gui;
[StructLayout(LayoutKind.Sequential)]
public struct Position2DTextureColorVertex(Vector2 position, Vector2 texcoord, Color color) : IVertexType
{
public Vector2 Position = position;
public Vector2 TexCoord = texcoord;
public Color Color = color;
public static VertexElementFormat[] Formats { get; } = new VertexElementFormat[3]
{
VertexElementFormat.Vector2,
VertexElementFormat.Vector2,
VertexElementFormat.Color
};
public static uint[] Offsets { get; } = new uint[3]
{
0,
8,
16
};
}
[StructLayout(LayoutKind.Sequential)]
public struct TransformVertexUniform(Matrix4x4 projectionMatrix)
{
public Matrix4x4 ProjectionMatrix = projectionMatrix;
}