mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2025-01-13 04:22:05 +01:00
internal/graphicsdriver/playstation5: add ebitengine_SetVertices
This commit is contained in:
parent
2bbceec451
commit
7f1e6cb538
@ -32,6 +32,9 @@ ebitengine_NewScreenFramebufferImage(int *image, int width, int height) {
|
||||
|
||||
extern "C" void ebitengine_DisposeImage(int id) {}
|
||||
|
||||
void ebitengine_SetVertices(float *vertices, int vertexCount, int *indices,
|
||||
int indexCount) {}
|
||||
|
||||
ebitengine_Error
|
||||
ebitengine_DrawTriangles(int dst, int *srcs, int srcCount, int shader,
|
||||
ebitengine_DstRegion *dstRegions, int dstRegionCount,
|
||||
|
@ -72,6 +72,9 @@ func (g *Graphics) SetTransparent(transparent bool) {
|
||||
}
|
||||
|
||||
func (g *Graphics) SetVertices(vertices []float32, indices []uint32) error {
|
||||
defer runtime.KeepAlive(vertices)
|
||||
defer runtime.KeepAlive(indices)
|
||||
C.ebitengine_SetVertices((*C.float)(&vertices[0]), C.int(len(vertices)), (*C.uint32_t)(&indices[0]), C.int(len(indices)))
|
||||
return nil
|
||||
}
|
||||
|
||||
|
@ -57,6 +57,9 @@ ebitengine_Error ebitengine_NewScreenFramebufferImage(int *image, int width,
|
||||
int height);
|
||||
void ebitengine_DisposeImage(int id);
|
||||
|
||||
void ebitengine_SetVertices(float *vertices, int vertexCount, uint32_t *indices,
|
||||
int indexCount);
|
||||
|
||||
ebitengine_Error
|
||||
ebitengine_DrawTriangles(int dst, int *srcs, int srcCount, int shader,
|
||||
ebitengine_DstRegion *dstRegions, int dstRegionCount,
|
||||
|
Loading…
Reference in New Issue
Block a user