Skip to content

Commit cfbf963

Browse files
committed
Add GraphicsDevice.DrawUserIndexedPrimitivesPointerEXT() method; Bump versions
1 parent ef715d6 commit cfbf963

File tree

3 files changed

+39
-2
lines changed

3 files changed

+39
-2
lines changed

FNA.NET.UWP.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -405,7 +405,7 @@
405405
<PackageTags>fna;xna;net8</PackageTags>
406406
<PackageId>FNA.NET.UWP</PackageId>
407407
<Copyright>Copyright 2025 FNA-NET</Copyright>
408-
<VersionPrefix>2.1.1.2506</VersionPrefix>
408+
<VersionPrefix>2.1.2.2506</VersionPrefix>
409409
<VersionSuffix></VersionSuffix>
410410
<AllowedOutputExtensionsInPackageBuildOutputFolder>$(AllowedOutputExtensionsInPackageBuildOutputFolder);.pdb</AllowedOutputExtensionsInPackageBuildOutputFolder>
411411

FNA.NET.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -426,7 +426,7 @@
426426
<PackageTags>fna;xna;net8</PackageTags>
427427
<PackageId>FNA.NET</PackageId>
428428
<Copyright>Copyright 2025 FNA-NET</Copyright>
429-
<VersionPrefix>2.1.1.2506</VersionPrefix>
429+
<VersionPrefix>2.1.2.2506</VersionPrefix>
430430
<VersionSuffix></VersionSuffix>
431431
<AllowedOutputExtensionsInPackageBuildOutputFolder>$(AllowedOutputExtensionsInPackageBuildOutputFolder);.pdb</AllowedOutputExtensionsInPackageBuildOutputFolder>
432432

src/Graphics/GraphicsDevice.cs

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1470,6 +1470,43 @@ VertexDeclaration vertexDeclaration
14701470
);
14711471
}
14721472

1473+
public void DrawUserIndexedPrimitivesPointerEXT<T>(
1474+
PrimitiveType primitiveType,
1475+
IntPtr vertexData,
1476+
int vertexOffset,
1477+
int numVertices,
1478+
IntPtr indexData,
1479+
int indexOffset,
1480+
int primitiveCount
1481+
) where T : struct, IVertexType {
1482+
ApplyState();
1483+
1484+
PrepareUserVertexBuffer(
1485+
vertexData,
1486+
numVertices,
1487+
vertexOffset,
1488+
VertexDeclarationCache<T>.VertexDeclaration
1489+
);
1490+
PrepareUserIndexBuffer(
1491+
indexData,
1492+
PrimitiveVerts(primitiveType, primitiveCount),
1493+
indexOffset,
1494+
2
1495+
);
1496+
1497+
FNA3D.FNA3D_DrawIndexedPrimitives(
1498+
GLDevice,
1499+
primitiveType,
1500+
0,
1501+
0,
1502+
numVertices,
1503+
0,
1504+
primitiveCount,
1505+
userIndexBuffer,
1506+
IndexElementSize.SixteenBits
1507+
);
1508+
}
1509+
14731510
#endregion
14741511

14751512
#region DrawPrimitives: Vertex Arrays, No Indices

0 commit comments

Comments
 (0)