Bump to Zig 0.12/raylib 5.1-dev (#81)

* Update to Zig 0.12.0 and raylib 5.1-dev

* More build.zig fixes for 0.12

* Get module with target and optimization

* Add examples to build step when compiling for emscripten

* Remove unused function

* Add build.* and emcc.zig to the zon paths (#83)

As per some info found through https://github.com/ziglang/zig/issues/18282,
this is apparently necessary to use this library as a dependency.

Co-authored-by: Drum Ogilvie <me@daogilvie.com>

* Update binding
This commit is contained in:
Nikolas 2024-04-28 22:52:24 +02:00 committed by Not-Nik
parent 6eeb304ff3
commit ae751ce82e
Failed to generate hash of commit
17 changed files with 1161 additions and 327 deletions

View file

@ -14,6 +14,9 @@ pub extern "c" fn rlMultMatrixf(matf: [*c]const f32) void;
pub extern "c" fn rlFrustum(left: f64, right: f64, bottom: f64, top: f64, znear: f64, zfar: f64) void;
pub extern "c" fn rlOrtho(left: f64, right: f64, bottom: f64, top: f64, znear: f64, zfar: f64) void;
pub extern "c" fn rlViewport(x: c_int, y: c_int, width: c_int, height: c_int) void;
pub extern "c" fn rlSetClipPlanes(near: f64, far: f64) void;
pub extern "c" fn rlGetCullDistanceNear() f64;
pub extern "c" fn rlGetCullDistanceFar() f64;
pub extern "c" fn rlBegin(mode: c_int) void;
pub extern "c" fn rlEnd() void;
pub extern "c" fn rlVertex2i(x: c_int, y: c_int) void;
@ -45,8 +48,10 @@ pub extern "c" fn rlEnableShader(id: c_uint) void;
pub extern "c" fn rlDisableShader() void;
pub extern "c" fn rlEnableFramebuffer(id: c_uint) void;
pub extern "c" fn rlDisableFramebuffer() void;
pub extern "c" fn rlGetActiveFramebuffer() c_uint;
pub extern "c" fn rlActiveDrawBuffers(count: c_int) void;
pub extern "c" fn rlBlitFramebuffer(srcX: c_int, srcY: c_int, srcWidth: c_int, srcHeight: c_int, dstX: c_int, dstY: c_int, dstWidth: c_int, dstHeight: c_int, bufferMask: c_int) void;
pub extern "c" fn rlBindFramebuffer(target: c_uint, framebuffer: c_uint) void;
pub extern "c" fn rlEnableColorBlend() void;
pub extern "c" fn rlDisableColorBlend() void;
pub extern "c" fn rlEnableDepthTest() void;
@ -55,6 +60,7 @@ pub extern "c" fn rlEnableDepthMask() void;
pub extern "c" fn rlDisableDepthMask() void;
pub extern "c" fn rlEnableBackfaceCulling() void;
pub extern "c" fn rlDisableBackfaceCulling() void;
pub extern "c" fn rlColorMask(r: bool, g: bool, b: bool, a: bool) void;
pub extern "c" fn rlSetCullFace(mode: c_int) void;
pub extern "c" fn rlEnableScissorTest() void;
pub extern "c" fn rlDisableScissorTest() void;
@ -100,7 +106,7 @@ pub extern "c" fn rlUpdateVertexBuffer(bufferId: c_uint, data: *const anyopaque,
pub extern "c" fn rlUpdateVertexBufferElements(id: c_uint, data: *const anyopaque, dataSize: c_int, offset: c_int) void;
pub extern "c" fn rlUnloadVertexArray(vaoId: c_uint) void;
pub extern "c" fn rlUnloadVertexBuffer(vboId: c_uint) void;
pub extern "c" fn rlSetVertexAttribute(index: c_uint, compSize: c_int, ty: c_int, normalized: bool, stride: c_int, pointer: *const anyopaque) void;
pub extern "c" fn rlSetVertexAttribute(index: c_uint, compSize: c_int, ty: c_int, normalized: bool, stride: c_int, offset: c_int) void;
pub extern "c" fn rlSetVertexAttributeDivisor(index: c_uint, divisor: c_int) void;
pub extern "c" fn rlSetVertexAttributeDefault(locIndex: c_int, value: *const anyopaque, attribType: c_int, count: c_int) void;
pub extern "c" fn rlDrawVertexArray(offset: c_int, count: c_int) void;
@ -117,7 +123,7 @@ pub extern "c" fn rlUnloadTexture(id: c_uint) void;
pub extern "c" fn rlGenTextureMipmaps(id: c_uint, width: c_int, height: c_int, format: c_int, mipmaps: [*c]c_int) void;
pub extern "c" fn rlReadTexturePixels(id: c_uint, width: c_int, height: c_int, format: c_int) *anyopaque;
pub extern "c" fn rlReadScreenPixels(width: c_int, height: c_int) [*c]u8;
pub extern "c" fn rlLoadFramebuffer(width: c_int, height: c_int) c_uint;
pub extern "c" fn rlLoadFramebuffer() c_uint;
pub extern "c" fn rlFramebufferAttach(fboId: c_uint, texId: c_uint, attachType: c_int, texType: c_int, mipLevel: c_int) void;
pub extern "c" fn rlFramebufferComplete(id: c_uint) bool;
pub extern "c" fn rlUnloadFramebuffer(id: c_uint) void;