Update binding, more compatibility informations.

This commit is contained in:
Astie Teddy 2020-09-05 16:15:31 +02:00
parent 03673975d8
commit 8d7f4b0dbc
8 changed files with 19 additions and 6 deletions

View File

@ -110,9 +110,11 @@ rl.CloseWindow()
### Compatibility
raylib-lua (raylua) currently uses raylib 3.0 API.
raylib-lua (raylua) currently uses raylib 3.1-dev API with some 3.0 API compatibility
(see [compat.lua](https://github.com/TSnake41/raylib-lua/blob/master/src/compat.lua)).
physac and rlgl modules are built-in by default.
There is currently no support for raygui but it may be considered in the future.
raygui is supported, but is minimally tested, please report any issues you have
with raygui with raylib-lua (raylua) on GitHub or raylib Discord (#raylib-lua channel)
#### Global API

View File

@ -7,7 +7,7 @@ LUA ?= luajit/src/luajit
WINDRES ?= windres
CFLAGS += -Iluajit/src -Iraylib/src -Iraygui/src
LDFLAGS += -Lluajit/src -Lraylib/src -lraylib
LDFLAGS += -Lluajit/src -Lraylib -lraylib
MODULES := raymath rlgl easings gestures physac raygui

2
raylib

@ -1 +1 @@
Subproject commit ccdd8b5f28f4aaffda2b637e9cb7602ca167ba5f
Subproject commit be03613d1b6f9b0051d78c790f97df069150c65f

View File

@ -24,6 +24,9 @@ rawset(rl, "LoadImageEx", function (pixels, width, height)
return image
end)
-- rlUnproject moved to Vector3Unproject
rawset(rl, "rlUnproject", rl.Vector3Unproject)
-- math metamethods
local new = ffi.new

View File

@ -563,7 +563,9 @@ ffi.cdef [[
BLEND_ALPHA = 0,
BLEND_ADDITIVE,
BLEND_MULTIPLIED,
BLEND_ADD_COLORS
BLEND_ADD_COLORS,
BLEND_SUBTRACT_COLORS,
BLEND_CUSTOM
} BlendMode;
typedef enum {

View File

@ -3,6 +3,7 @@ bool WindowShouldClose(void)
void CloseWindow(void)
bool IsWindowReady(void)
bool IsWindowMinimized(void)
bool IsWindowMaximized(void)
bool IsWindowFocused(void)
bool IsWindowResized(void)
bool IsWindowHidden(void)
@ -10,6 +11,10 @@ bool IsWindowFullscreen(void)
void ToggleFullscreen(void)
void UnhideWindow(void)
void HideWindow(void)
void DecorateWindow(void)
void UndecorateWindow(void)
void MaximizeWindow(void)
void RestoreWindow(void)
void SetWindowIcon(Image image)
void SetWindowTitle(const char *title)
void SetWindowPosition(int x, int y)

View File

@ -88,3 +88,4 @@ void QuaternionToAxisAngle(Quaternion q, Vector3 *outAxis, float *outAngle)
Quaternion QuaternionFromEuler(float roll, float pitch, float yaw)
Vector3 QuaternionToEuler(Quaternion q)
Quaternion QuaternionTransform(Quaternion q, Matrix mat)
Vector3 Vector3Unproject(Vector3 source, Matrix projection, Matrix view)

View File

@ -49,8 +49,8 @@ void rlCheckErrors(void)
int rlGetVersion(void)
bool rlCheckBufferLimit(int vCount)
void rlSetDebugMarker(const char *text)
void rlSetBlendMode(int glSrcFactor, int glDstFactor, int glEquation)
void rlLoadExtensions(void *loader)
Vector3 rlUnproject(Vector3 source, Matrix proj, Matrix view)
unsigned int rlLoadTexture(void *data, int width, int height, int format, int mipmapCount)
unsigned int rlLoadTextureDepth(int width, int height, int bits, bool useRenderBuffer)
unsigned int rlLoadTextureCubemap(void *data, int size, int format)