Update RingRayLib - raylib.c - Add Function : TextureCubemap LoadTextureCubemap(Image image, int layoutType)
@@ -2697,6 +2697,27 @@ RING_FUNC(ring_LoadTextureFromImage)
}
}
+
+RING_FUNC(ring_LoadTextureCubemap)
+{
+ if ( RING_API_PARACOUNT != 2 ) {
+ RING_API_ERROR(RING_API_MISS2PARA);
+ return ;
+ }
+ if ( ! RING_API_ISNUMBER(2) ) {
+ RING_API_ERROR(RING_API_BADPARATYPE);
+ return ;
+ }
+ {
+ TextureCubemap *pValue ;
+ pValue = (TextureCubemap *) ring_state_malloc(((VM *) pPointer)->pRingState,sizeof(TextureCubemap)) ;
+ *pValue = LoadTextureCubemap(* (Image *) RING_API_GETCPOINTER(1,"Image"), (int ) RING_API_GETNUMBER(2));
+ if (RING_API_ISCPOINTERNOTASSIGNED(1))
+ ring_state_free(((VM *) pPointer)->pRingState,RING_API_GETCPOINTER(1,"Image"));
+ RING_API_RETMANAGEDCPOINTER(pValue,"TextureCubemap",ring_state_free);
+ }
+}
+
RING_API void ringlib_init(RingState *pRingState)
{
ring_vm_funcregister("initwindow",ring_InitWindow);
@@ -2868,4 +2889,5 @@ RING_API void ringlib_init(RingState *pRingState)
ring_vm_funcregister("exportimageascode",ring_ExportImageAsCode);
ring_vm_funcregister("loadtexture",ring_LoadTexture);
ring_vm_funcregister("loadtexturefromimage",ring_LoadTextureFromImage);
+ ring_vm_funcregister("loadtexturecubemap",ring_LoadTextureCubemap);
}
