Commit Graph

9676 Commits

Author SHA1 Message Date
Ray
29ded51ea4 Update rlgl.h 2026-03-29 00:43:50 +01:00
Jeffery Myers
bb78e98a71 Remove forced normalization of normal vectors in rlNormal3f, assume the user has set the correct input for the shader. (#5703) 2026-03-29 00:39:23 +01:00
Mr Josh
5915584cd6 Fix zig build and minor improvements (#5702)
- Added zig-pkg directory to gitignore
- Brought min zig version to recent nightly release these improvements
  were completed on
- For linux build, only add rglfw.c if the platform is glfw
- Add a None option to the LinuxDisplayBackend
- Fixed xcode-frameworks dependency and update to using most recent
  commit hash
2026-03-29 00:38:45 +01:00
Ray
8c44ea5032 Code gardening
REVIEWED: Some early returns, avoid if possible
REVIEWED: Some return variable names, for consistency, rename `success` to `result`
2026-03-29 00:37:01 +01:00
Ray
5fad835ff1 Update rcore.c 2026-03-28 23:54:51 +01:00
mjt
4142c89baa Update rcore.c comment (#5700) 2026-03-27 21:58:28 +01:00
github-actions[bot]
990a5e0cb4 rlparser: update raylib_api.* by CI 2026-03-27 20:56:45 +00:00
Ray
8a7aff509d WARNING: BREAKING: REDESIGNED: TextInsert(), TextReplace(), TextReplaceBetween(), using static buffers
Redesign has been conditioned by the usage of those functions on `rexm`, `rpc` and other tools; for many use cases a static buffer is enough and way more comfortable to use.
ADDED: `TextInsertAlloc()`, `TextReplaceAlloc()`, `TextReplaceBetweenAlloc()`, alternatives with internal allocations
2026-03-27 21:56:29 +01:00
Le Juez Victor
ba83bd33f3 simplify CheckCollisionSpheres using Vector3DistanceSqr (#5695) 2026-03-27 09:26:53 +01:00
mjt
98d6e24c44 remove comment (#5696) 2026-03-27 09:26:01 +01:00
Antonio Jose Ramos Marquez
51f4741912 [rmodel] fix for devices without VAO support (#5692) 2026-03-27 09:25:26 +01:00
github-actions[bot]
d7bd56ef1b rlparser: update raylib_api.* by CI 2026-03-26 17:29:18 +00:00
Maicon Santana
a693365bf2 Move DrawModelPoints methods to example - point rendering (#5697) 2026-03-26 18:29:05 +01:00
Lewis Lee
bd3a35ca21 [build.zig.zon] Fix: replace deleted hexops/xcode-frameworks with pkg.machengine.org mirror (#5693) 2026-03-26 09:20:44 +01:00
Ray
0f0983c065 Remove trailing spaces 2026-03-25 16:51:02 +01:00
Jordi Santonja
5dd4036ed0 Fix UI Cellular Automata (#5688) 2026-03-24 08:20:37 +01:00
Krzysztof Szenk
cb05ef7f03 [rcore_desktop_rgfw] [emscripten] fix typo (#5687)
* RGFW also requires RGBA8 images as window icons, as raylib already reports in raylib.h

* LibraryConfigurations.cmake: exchanged MATCHES -> STREQUAL in platform choosing if-statements

* WebRGFW: remapping mouse/touch position to canvas pixel coordinates

* fix 'typo'

* has to be done like that because of += in case of captured mouse

* [rcore_desktop_rgfw] [emscripten] fix typo
2026-03-23 22:22:21 +01:00
Ray
52d2158f49 Update ROADMAP.md 2026-03-23 18:28:09 +01:00
Charlie Tonneslan
0f1e14a600 Fix typo: dependant -> dependent in rlgl.h and rexm.c (#5685)
5 instances in src/rlgl.h comments and 1 in tools/rexm/rexm.c.
Skipped vendored raygui.h files in examples/.
2026-03-23 17:58:45 +01:00
Charlie Tonneslan
6cf71f565c Fix typo: dependant -> dependent in rlgl.h and rexm.c (#5685)
5 instances in src/rlgl.h comments and 1 in tools/rexm/rexm.c.
Skipped vendored raygui.h files in examples/.
2026-03-23 17:17:50 +01:00
Maicon Santana
e71633a0be Set textureWrapRepeat to avoid issue on web version (#5684) 2026-03-23 14:05:23 +01:00
Ray
ca1baca7c2 REVIEWED: examples memory allocators, using raylib provided macros 2026-03-23 11:53:57 +01:00
Ray
7e8aca00b6 Update textures_raw_data.c 2026-03-23 11:53:31 +01:00
Ray
c1dbfc87f3 REVIEWED: PR #5679 2026-03-23 11:52:01 +01:00
Ray
644e4adbe2 Update rcore.c 2026-03-23 11:51:37 +01:00
Krzysztof Szenk
1e74aba7c3 WebRGFW: remapping mouse/touch position to canvas pixel coordinates (#5679)
* RGFW also requires RGBA8 images as window icons, as raylib already reports in raylib.h

* LibraryConfigurations.cmake: exchanged MATCHES -> STREQUAL in platform choosing if-statements

* WebRGFW: remapping mouse/touch position to canvas pixel coordinates

* fix 'typo'

* has to be done like that because of += in case of captured mouse
2026-03-23 11:31:06 +01:00
Levent Kaya
83e35ba170 [rcore] refactor possible data loss on FileMove() (#5682) 2026-03-23 11:30:28 +01:00
Jopestpe
22cc2554b1 Fix Memory out of bounds in [shapes] example - ball physics (#5683)
Update screenshot to shapes_bouncing_ball.png
2026-03-23 11:28:28 +01:00
Thomas Anderson
1b084ff9f2 fixed error in readme, found by discord user the.enemy (#5680) 2026-03-22 09:06:03 +01:00
Le Juez Victor
8a685877eb [rlsw] Remove position attribute from sw_vertex_t (#5677)
* review `sw_vertex_t`

* fix comment

* fix pop matrix
2026-03-20 12:07:50 +01:00
Ray
8783e66e21 Update rlsw.h 2026-03-19 23:42:20 +01:00
Le Juez Victor
7ae46fb2e6 [rlsw] Micro-optimizations, tighter pipeline and cleanup (#5673)
* auto generates all combinations of blending factors
This adds a macro system that generate a function for each possible combination of blending factors, resulting in 11*11 functions, hence 121.
This then allows for only one indirection and function call instead of two previously (assuming the first call was inlined).

* rename dispatch tables for consistency

* change blend funcs validity check
Simplifies the validation of blend functions.
Can allow `SW_SRC_ALPHA_SATURATE` as dst factor, but hey

* disables blending when it requires alpha and there is none

* review immediate rendering functions and attribute layout

* prevent state changes during immediate record

* reduce number of op for each vertex push + review primitive struct

* simplified draw functions

* review `sw_vertex_t`
removes `float screen[2]`; each step stores the transformed coordinates in `float coord[4]`.
This also simplifies vertex interpolation during triangle rasterization.

* reduces unnecessary interpolation costs during triangle rasterization + cleanup

* extends the simd color conversion to more cases

* affine interpolation per blocks

* long side check for each triangle line
My mistake in a previous commit

* style tweaks

* select the read function on texture load
This removes the per-pixel switch; it's slightly more efficient on my hardware, but probably a poor prediction
Should remain profitable or at worst the same

* use optionnal LUT for uint8_t -> float conversion

* sets internal the number of vertices post-clipping and the epsilon clipping + a little cleanup

* moves color conversion to math part

* prevents sampling if it's a depth texture that is bound
2026-03-19 23:39:52 +01:00
Ray
04c5dc4493 REVIEWED: PR #5674 2026-03-19 23:35:18 +01:00
Juraj Michálek
bca4f83a02 required change for ESP-IDF 6 (#5674) 2026-03-19 23:19:44 +01:00
devel
7fef65a3fe Make fogColor in the fog tutorial a parameter (#5672)
* uniform fogColor

fogColor is now a parameter

* use new fog color parameter

* convert ambient to Vector4
2026-03-19 23:17:27 +01:00
Amine Laaboudi
da9e881092 Fix uninstall process to remove rcamera header file (#5671)
Co-authored-by: 0x00650a <Ox00650a@inter.net>
2026-03-18 21:09:27 +01:00
Ray
2a3b28b67a Reviewed some comments 2026-03-18 16:21:35 +01:00
Ray
2fd058c1e4 Update ROADMAP.md 2026-03-18 16:21:18 +01:00
Ray
528caf8b9d Added some libraries 2026-03-18 16:21:14 +01:00
Ray
85df4e7de5 REVIEWED: rlsw, use provided library information 2026-03-18 13:31:09 +01:00
Ray
f23319db3c Update ROADMAP.md 2026-03-18 13:29:51 +01:00
Ray
29e4b77580 RENAMED: rl_gputex to rltexgpu 2026-03-18 13:29:36 +01:00
Ray
2c39703d13 RENAMED: rl_gputex to rltexgpu 2026-03-18 13:28:45 +01:00
Le Juez Victor
d657e86043 [rlsw] Fix typos, update build scripts, and align style (#5669)
* fix typo that appeared during re-format

* fix build scripts for `GRAPHICS_API_OPENGL_SOFTWARE`

* consistency tweak
2026-03-17 20:01:45 +01:00
Ray
0de2e8092b REVIEWED: GetTime(), make sure division is with doubles #5668 2026-03-17 19:38:29 +01:00
Ray
48a34d63ed Update rlsw.h 2026-03-17 18:35:33 +01:00
Ray
fbce5e7541 Bump rlgl version to 6.0, after the low-level shaders API redesign, aligned with raylib 6.0 2026-03-17 18:33:53 +01:00
Ray
18756bb79d REVIEWED: Software renderer flag, renamed to GRAPHICS_API_OPENGL_SOFTWARE
Dropped the `11` relative to OpenGL 1.1 because latest `rlsw 1.5` also includes support for FBOs and could potentially implemented other higher level features in the feature, discerning from OpenGL 1.1 limitations
2026-03-17 18:33:15 +01:00
Ray
6ddf9a1885 Code review, format tweaks, defined version to 1.5 2026-03-17 18:30:48 +01:00
Le Juez Victor
e7d999e3c7 [rlsw] RenderTexture support (#5655)
* review texture formats
Added support for `R3G3B2`, `R5G6B5`, `R4G4B4A4` and `R5G5B5A1`
Added depth formats

* use of textures for the framebuffer
- Framebuffers can now use all texture types that are already available.
- The 24-bit depth format has been removed as it is no longer needed.
- Framebuffer formats are still defined at compile time.
- The allocated texture size is now preserved, which avoids frequent reallocations when resizing framebuffers and will allow the use of `glTexSubImage2D`.

* review framebuffer blit/copy
This greatly simplifies the framebuffer blit/copy logic while now supporting all pixel formats. It is slightly slower in debug builds, but this path is mainly kept for compatibility anyway. The `copy_fast` version is still used for the "normal" cases when presenting to the screen.

* review pixel get/set
less ops for certain formats + fixes

* fix depth write

* texture read/write cleanup + tweaks
I made the  pointers parameters `restrict` for reading/writing textures, which resulted in a slight improvement.
And I reviewed the `static inline` statements, which could potentially bias the compiler; no difference, but it's cleaner.

* style tweaks

* review uint8_t <-> float conversion

* added a reusable object pool system
will allow management of both textures and framebuffers
added support for `glTexSubImage2D`
added handling of 'GL_OUT_OF_MEMORY' errors
removed the default internal texture (unused)

* added FBO API + refactored rasterizer dispatch logic

* fix ndc projection + review presentation
and rename rlsw's resize/copy/blit

* add `glRenderbufferStorage` binding
+ tweaks and fixes

* fix quad sorting + simplify quad rasterization part

* fix line shaking issue

* support of `GL_DRAW_FRAMEBUFFER_BINDING`

* update rlgl - support of rlsw's framebuffers

* fix pixel origin in line rasterization
my bad, an oversight in my previous fix.
This offset should have been moved here rather than per pixel during truncation.

* style tweaks

* fix vla issue with msvc - fill depth / fill color
2026-03-17 17:50:32 +01:00