Ray
714de02a88
Merge pull request #4980 from williewillus/pr4980
...
[rshapes] Fix incorrect parameter names in DrawRectangleGradientEx
2025-06-02 18:37:34 +02:00
M374LX
bb5b5434a7
Update miniaudio to v0.11.22
2025-06-01 14:37:01 -03:00
alqeeu
51958d6e2c
changed RGFW_window_eventWait timeout to -1
2025-06-01 17:37:31 +03:00
Vincent Lee
19ae6f2c2d
[rshapes] Fix incorrect parameter names in DrawRectangleGradientEx
...
Examining the code shows that the rectangle is drawn winding counterclockwise, starting
with the top left. Therefore the colors used should be in the order: topLeft, bottomLeft,
bottomRight, topRight.
However, the variables actually being used are topLeft, bottomLeft, topRight,
bottomRight. I was confused by this as I was getting striping where I didn't expect any.
Put another way, the last two parameters are misnamed.
This diff swaps the parameter names and their usages. The result is that no runtime
behaviour changes: the same parameter order yields the same visual result both before and
after this change, but the parameter names now correctly reflect what they are actually
used for.
You can actually see this in the implementation of DrawRectangleGradientV, which
(correctly) passes top, bottom, bottom, top to DrawRectangleGradientEx.
2025-05-31 23:00:40 -07:00
jestarray
296e3af470
add const qualifier to ImageDrawTriangleFan and ImageDrawTriangleStrip arguments
2025-05-31 14:24:56 -07:00
M374LX
6eeaf1dd5b
Update RGFW to 1.7.5-dev
2025-05-31 16:43:25 -03:00
Ray
c1bb53738e
Merge pull request #4974 from M374LX/rgfw-escape-fix
...
RGFW: fix Escape always closing the window
2025-05-31 20:43:40 +02:00
Ray
9bf4388a4f
Merge pull request #4965 from M374LX/rgfw-update
...
Update RGFW to 1.7
2025-05-31 20:42:08 +02:00
Ray
20c0c92bdb
Merge pull request #4963 from meowstr/master
...
[rshapes] Add DrawEllipseV and DrawEllipseLinesV
2025-05-31 20:41:37 +02:00
M374LX
bc2b2864e0
RGFW: fix Escape always closing the window
2025-05-31 14:24:38 -03:00
M374LX
3418172617
Update comments
2025-05-29 23:01:48 -03:00
M374LX
a9525bfbc2
Update RGFW to 1.7
2025-05-29 16:03:39 -03:00
M374LX
16f398b464
Update comment (gamepad axes)
2025-05-29 15:01:01 -03:00
Meowster
6d5aedbd38
Add DrawEllipseV and DrawEllipseLinesV
2025-05-29 07:10:52 -04:00
Ray
913c236487
REVIEWED: MAX_GAMEPAD_AXES
2025-05-29 12:51:08 +02:00
Ray
341bfb22cc
REVIEWED: MAX_GAMEPAD_AXEX for consistency #4960
2025-05-29 12:25:00 +02:00
Ray
2afae1b3e1
Merge pull request #4962 from M374LX/rgfw-rctrl
...
RGFW backend: add missing Right Control key
2025-05-29 12:09:01 +02:00
M374LX
c0cf57f8f0
RGFW backend: add missing Right Control key
2025-05-28 22:38:16 -03:00
M374LX
299f5350a4
Remove unused variable
2025-05-28 19:49:57 -03:00
Moros Smith
f7fe8b88cb
add EmscriptenKeyboardCallback to consume key events
2025-05-28 17:47:18 -04:00
Ray
d7148f5f9d
REDESIGNED: Base64 encoding/decoding functions
...
Found some issues with output size when padding required, just re-implemented both functions from scratch.
2025-05-28 17:19:19 +02:00
Ray
5ddd13b775
REVIEWED: Hexadecimal formatting to be consistent
2025-05-28 17:18:02 +02:00
Moros Smith
8ef6473d33
return to ray's expected resize behavior
2025-05-25 18:58:35 -04:00
Moros Smith
cf2099f18a
the holy grail
2025-05-24 20:33:27 -04:00
Ray
afb52b19a4
WARNING: REDESIGNED: EncodeDataBase64(), NULL terminated string returned
...
Note that returned output size considers the NULL terminator as an additional byte.
2025-05-22 17:06:55 +02:00
Ray
21f0fe2a73
Removed some spaces
2025-05-21 19:06:04 +02:00
Ray
e3b9dbe75b
Merge pull request #4947 from padmadevd/master
...
[rcore] Fixed bug in hovering and input for android
2025-05-19 11:59:14 +02:00
Padmadev D
b6daa48a9c
Update rcore_android.c
...
corrected coding conventions.
2025-05-19 15:09:58 +05:30
Colby Newman
21e711b13f
Fix typo in mesh animNormals
2025-05-18 19:35:21 -04:00
Padmadev D
5da2d10118
Update rcore_android.c
...
Bug Fix Update
Code to Ignore Hovering Inputs Completely
2025-05-18 18:53:28 +05:30
Moros Smith
358917ffc3
trigger resize event when going into and out of fullscreen mode
2025-05-17 21:08:57 -04:00
Moros Smith
d0d42e78ea
inform glfw that a change of window size has taken place
2025-05-17 21:08:35 -04:00
Moros Smith
b618d7b35b
use parentElement's dimensions for width/height
2025-05-17 21:08:07 -04:00
Ray
8c99a508c6
REVIEWED: WindowSizeCallback(), GLFW
...
It is called on window minification and setting internal width/height to 0, that can break things
2025-05-14 23:49:24 +02:00
Ray
a51d334440
Merge branch 'master' of https://github.com/raysan5/raylib
2025-05-14 23:47:32 +02:00
Ray
9d4c31533d
Update rtext.c
2025-05-14 23:47:03 +02:00
Ray
ba31219141
Merge pull request #4937 from Bigfoot71/fix-gen-tangents
...
[rmodels] Fix and improve `GenMeshTangents`
2025-05-13 20:52:51 +02:00
Jeffery Myers
aa684a33de
make save file callback match const correctness of calling function
2025-05-12 19:54:34 -07:00
Bigfoot71
d135eef462
fix and improve GenMeshTangents
2025-05-12 23:16:06 +02:00
Ray
f7d03efb49
REVIEWED: DecodeDataBase64(), follow convention:
...
- All `char *` refer to text strings
- All `unsigned char *` refer to generic byte arrays
2025-05-11 11:05:25 +02:00
Ray
3083f0cd43
REVIEWED: SaveFileText(), const input text
2025-05-11 11:03:49 +02:00
Ray
693c9c292a
Formatting tweaks
2025-05-10 22:45:08 +02:00
Jeffery Myers
ebaa922f6b
Properly clean up the default font on unload, it may be reused if the window is created again
2025-05-08 09:57:31 -07:00
Ray
7e07278368
Update rprand.h
2025-05-08 17:06:29 +02:00
Karl Zylinski
a15548fb5a
Add normals to DrawSphereEx
2025-05-06 13:09:05 +02:00
Ray
3d6e24af4f
Merge pull request #4906 from Bigfoot71/fix-clip
...
[rlgl] Proposed fix for default near/far clipping range
2025-05-06 11:12:35 +02:00
Jeffery Myers
ee2ab11cc5
Use the animated verts and normals in GL 1.1 if they exist
2025-05-05 15:49:23 -07:00
Ray
31d63d08e2
Merge pull request #4922 from Bigfoot71/review-file-dir-2
...
[rcore] Some adjustments for `FilePathList`
2025-05-05 16:57:22 +02:00
Ray
a7ad2d1965
Merge pull request #4918 from JeffM2501/default_font_image_leaks
...
[rText] Fix issues with default font being used before InitWindow in the image API.
2025-05-05 12:06:55 +02:00
Jeffery Myers
e53a43b7b5
Assign meshes without bone weights to the bone they are attached to so they animate.
2025-05-04 17:32:37 -07:00
Bigfoot71
38aec920b5
makes path static in ScanDirectoryFilesRecursively
2025-05-04 14:47:52 +02:00
Bigfoot71
03988d2ce8
added a NULL check in UnloadDirectoryFiles
2025-05-04 14:46:39 +02:00
Le Juez Victor
c087144385
Merge branch 'raysan5:master' into fix-clip
2025-05-04 12:29:19 +02:00
Jeffery Myers
94c5de33a0
Make the default font loadable before InitWindow, for use with the image API.
...
Make the default font loader early out if we have already loaded parts of it, so we don't leak memory
2025-04-30 17:56:30 -07:00
Ray
1ec281e86f
Merge pull request #4914 from Servall4/master
...
[raudio] fix: GetMusicTimePlayed returns incorrect time after restarting a paused track
2025-04-28 23:13:31 +02:00
Duy Tran
f0de896f36
cmake: replace custom variable with built-in one
2025-04-28 11:57:53 -04:00
Ivan Ugryumov
ec5ce8c7fe
Update raudio.c
2025-04-28 14:29:51 +03:00
Gavin Rohrer
10478ff756
Revert GLFW_SCALE_FRAMEBUFFER to pre GLFW 4.3 behavior
2025-04-25 14:32:02 -04:00
Le Juez Victor
461c9c9d90
review tabs
2025-04-22 15:02:09 +02:00
Le Juez Victor
a7333a9dae
review near/far
2025-04-22 15:00:54 +02:00
Jeffery Myers
0f6b9ee738
format math the way ray likes it
2025-04-18 07:27:20 -07:00
Ray
b185f482d0
Merge pull request #4896 from mUnicorn/fix_bones_animation_scale
...
[rmodels] Fix bones animation scale
2025-04-18 10:46:00 +02:00
Ray
73030e02d4
Merge pull request #4895 from AndrewHamel111/descriptive-window-flag-warning
...
Add Warning to direct users to appropriate WindowState / ConfigFlag function
2025-04-18 10:43:24 +02:00
Jeffery Myers
5185d4c427
use the device channels and sample size when computing the default buffer size.
2025-04-16 18:13:41 -07:00
d.isakov
42a40b3920
move first mesh bones calculation under check for its presense
2025-04-16 08:04:58 +02:00
d.isakov
b4f1ff9a00
#4888 fix UpdateModelAnimationBones scale transform
2025-04-16 07:49:26 +02:00
AndrewHamel111
fdb92b373b
Warning to direct users to appropriate function
2025-04-15 21:08:35 -04:00
Ray
5b940692ea
REVIEWED: ExportFontAsCode() not checking isGpuReady #4894
2025-04-15 13:09:44 +02:00
Ray
80fcca4155
Update rcore_desktop_glfw.c
2025-04-14 12:37:06 +02:00
Ray
cc5739a6d7
REVIEWED: Some PRs formating
2025-04-13 20:55:38 +02:00
Jeffery Myers
60eb3a14d7
Only scale the screenshot by the DPI scale if we are doing automatic High DPI scaling, otherwise the native resolution is correct.
2025-04-10 13:59:09 -07:00
Eike Decker
1c4aa1378f
[rcore][SDL2] First touch position is overwritten with mouse pos
...
I believe it makes sense to only do this when there are no known
touch points. I am not even sure if this should be done at all.
See https://github.com/raysan5/raylib/issues/4872 for more information.
2025-04-01 23:10:19 +02:00
Ray
1a67dcb578
REVIEWED: RGB order on SDL3 #3568
2025-04-01 01:26:51 +02:00
Ray
9a049d1d27
Merge pull request #4859 from MikiZX1/master
...
Update rcore_desktop_sdl.c
2025-03-28 18:03:32 +01:00
Jonathan Marler
af16f7823a
Improve description of RestoreWindow
...
Restore window currently says it sets the window state to:
"not minimized/maximized"
However, if a window is maximized and then minimized, it's typical that
it would restore back to being maximized, which is what seems to happen
from my testing. I've reworded the description to better reflect
this behavior.
2025-03-28 10:39:22 -06:00
MikiZX1
55c6864092
Update rcore_desktop_sdl.c
...
raylib app crashing when started and a gamepad is already connected to the PC (even if the gamepad is not used in the app). I only tested this with a gamepad that has a layout which is not recognized. Using SDL3 as backend.
2025-03-26 14:06:58 +01:00
Ray
3d83c1c796
Format tweak
2025-03-25 19:27:55 +01:00
Ray
909c83fd4a
Avoid path filtering on TakeScreenshot()
2025-03-25 16:22:46 +01:00
Ray
32c8f396c2
Merge branch 'master' of https://github.com/raysan5/raylib
2025-03-25 16:21:53 +01:00
Ray
63e608d485
comment tweak
2025-03-24 15:07:36 +01:00
sleeptightAnsiC
8e9c3ceb57
[rcore] fix: TRACELOG upon successfully changing directory
...
InitWindow() prints CWD during initialization,
but ChangeDirectory() does not, which is quite confusing when you start
messing with CWD. Now said function should log similar message.
2025-03-22 21:20:17 +01:00
Ray
46cd07d2c7
WARNING: REVERTED CHANGE THAT BROKE BATCHING!!! #4849
...
I'm sorry... I did not detect this change was breaking batching... :(
2025-03-21 17:17:45 +01:00
Ray
266fba1111
Minor tweaks
2025-03-21 17:07:55 +01:00
Myrddin Krustowski
589ad0a33d
Add early return to circle sector functions when angles are equal.
...
Prevents unnecessary work and division by zero (when segments=0) in DrawCircleSector/DrawCircleSectorLines when startAngle equals endAngle, matching existing behavior in DrawRing/DrawRingLines.
2025-03-18 11:51:58 +02:00
Ray
2f63a15630
Merge pull request #4836 from JeffM2501/unscale_on_resize
...
[rcore] Correctly handle window size on resize in auto-scaled HIGHDPI environment
2025-03-14 17:15:14 +01:00
Jeffery Myers
d56ab670c3
spaces not tabs
2025-03-14 08:18:26 -07:00
Ray
cb830bed72
Increased depth size and clip distances to avoid z-fighting issues
2025-03-13 16:34:39 +01:00
Ray
d0e638cc31
REVIEWED: Platform DRM messages...
2025-03-13 11:42:16 +01:00
Alex Anderson
99a9ecfaac
[rcore] Support window flags with initialization issues
...
This may not be the correct approach, however this appears to work. The idea is that before modifying `CORE.Window.flags` when first creating the window we keep a copy of the flags in order to call `SetWindowState` after initialization has completed, which should behave as if `MaximizeWindow` or `MinimizeWindow`, or conceptually any other flag modifying function were called after `InitWindow`.
This pull request only performs this for the windows platform, modify as needed in the switch statement at the end for others.
2025-03-12 14:56:02 -07:00
Jeffery Myers
4bed3741c1
Unscale the window size on resize if we are doing automatic HighDPI scaling.
2025-03-12 14:16:50 -07:00
Ray
749a512f13
REVIEWED: ScanDirectoryFiles*() #4833
2025-03-12 12:44:40 +01:00
Ray
654d5c80c2
Merge pull request #4833 from MykBamberg/master
...
[rcore] Use snprintf to prevent buffer overflow in path construction
2025-03-12 12:40:25 +01:00
Nia Nightglow
fffbbad2f7
Guard against DEBUG Redefinition
...
Undefine DEBUG to avoid external redefinition
warnings/conflicts. This is probably a common
definition for many external build systems'
debug configurations.
This ensures raylib will not emit
a warning about the DEBUG definition being
redefined in external build systems.
2025-03-12 00:13:01 -05:00
MykBamberg
daa2921476
[rcore] Use snprintf to prevent buffer overflow in path construction
2025-03-12 01:38:39 +01:00
Ray
b80250bee4
Merge pull request #4807 from RicoP/RicoP/sinfl_bsr
...
[rcore] sinfl_bsr fix for TCC
2025-03-11 08:32:32 +01:00
Rico P
0934cdba48
fix C++ style cast
2025-03-11 07:09:10 +01:00
Rico P
7dc409d060
potential fix for MSVC compile error
2025-03-11 07:03:57 +01:00
Rico P
e7872a700d
update sinfl_bsr
2025-03-10 20:57:48 +01:00
Ray
7f8bf2233c
REVIEWED: Formating to follow raylib conventions
2025-03-10 17:08:18 +01:00
Ray
bd8e59f18d
Replace size_t by unsigned int
2025-03-10 17:07:18 +01:00
Ray
4c8c72778d
Remove trailing spaces
2025-03-10 17:04:29 +01:00
Ray
9c62a7823b
Update Makefile
2025-03-10 17:04:14 +01:00
Colleague Riley
0853c5b03f
[rcore][RGFW] bug fixes ( #4798 )
...
* update RGFW to 1.6
* properly handle RGFW_quit events
* fix rcore_desktop_rgfw bugs
* update
* update
* uncomment out
2025-03-10 16:50:40 +01:00
Kaluub
9ba0cdbe6d
Fix GetCurrentMonitor comments. ( #4812 )
2025-03-07 19:21:08 +00:00
Ashish Bhattarai
f1385f3aec
Fix stb_truetype composite glyph scaling logic ( #4811 )
2025-03-04 18:53:11 +01:00
sleeptightAnsiC
34159399cf
[rcore] fix crash in InitWindow, due to unchecked result of InitPlatform ( #4803 )
...
* [rcore] fix crash in InitWindow, due to unchecked result of InitPlatform
Check the result of InitPlatform(), if it isn't 0, report the Error
and return. This prevent crashes and allows for gracefully aborting
or recovering by checking IsWindowReady().
Partially-fixes: https://github.com/raysan5/raylib/issues/4801
* [rcore] style: store the result of InitPlatform() before checking it
Small style change that doesn't impact how the code behaves here.
Variable 'result' is not used anywhere else in this block,
it's just for compliance with Raylib's coding conventions.
Requested in PR: https://github.com/raysan5/raylib/pull/4803#discussion_r1976502788
* [rcore] use LOG_WARNING when InitPlatform() fails
...as this is preferred over LOG_ERROR.
Requested-by: https://github.com/raysan5/raylib/pull/4803#discussion_r1976651724
2025-03-02 17:05:09 +01:00
Rico P
539c45ee23
sinfl_bsr fix for TCC
2025-03-02 16:20:49 +01:00
Ray
b99c2848c1
Merge branch 'master' of https://github.com/raysan5/raylib
2025-03-02 13:43:32 +01:00
Ray
654131799e
Minor tweaks
2025-03-02 13:43:15 +01:00
sleeptightAnsiC
a20d9dedf3
[desktop_glfw] fix InitPlatform crash caused by glfwCreateWindow... ( #4804 )
...
...returning NULL. This was causing a crash few lines later.
Refs: https://github.com/raysan5/raylib/issues/4801#issuecomment-2691201072
Partially-fixes: https://github.com/raysan5/raylib/issues/4801
2025-03-01 23:42:07 +01:00
Colleague Riley
e4dcdfa1f2
update RGFW to 1.6 ( #4795 )
2025-02-25 21:49:37 +01:00
Ray
557d071fa2
Reviewed shader loading message
2025-02-25 17:50:46 +01:00
Ray
da8a08006a
Added some comments on latest change
2025-02-25 12:46:06 +01:00
Destructor17
27af359d1c
[rlgl] Preserve texture on mode switching ( #4364 )
...
* Fix textures on draw mode switch
* formatting fix
* ident
2025-02-25 12:39:00 +01:00
Ray
0037ee5420
Merge branch 'master' of https://github.com/raysan5/raylib
2025-02-25 11:43:32 +01:00
Ray
a979b10966
Minor format tweak
2025-02-25 11:43:22 +01:00
Rico P
1e2fd94209
fix linkage warnings under windows ( #4766 )
2025-02-24 13:54:17 +01:00
Ray
294da26042
Update raymath.h
2025-02-23 23:07:12 +01:00
Ray
fc5ff8db5c
Update raymath.h
2025-02-23 23:06:31 +01:00
Ray
a5907bfdca
REVIEWED: MatrixDeterminant() #4780
2025-02-23 23:04:52 +01:00
Mario Nachbaur
85a87baf69
Support IsWindowHidden() on web. ( #4789 )
2025-02-23 18:19:42 +01:00
Ralph Caraveo
4522ecae1a
[raudio] Fixed memory leak on early-return of WaveFormat func ( #4779 )
...
In the case of a failure within miniaudio on the function: ma_convert_frames, the dynamic memory allocated for the `data` variable will leak on the early return.
2025-02-21 15:29:12 +01:00
Colleague Riley
c34ef35433
Update RGFW and ensure it's consistent with the GLFW backend ( #4783 )
...
* add PLATFORM_WEB_RGFW
* fix some bugs
* fix web_rgfw gamepad
* send fake screensize
* fix gamepad bugs (linux) | add L3 + R3 (gamepad)
* fix?
* update RGFW (again)
* update raylib (merge)
* fix xinput stuff
* delete makefile added by mistake
* update RGFW
* update RGFW (rename joystick to gamepad to avoid misunderstandings
* update RGFW (fix X11 bug)
* update RGFW
* use RL_MALLOC for RGFW
* update RGFW (fixes xdnd bug)
* fix some formating
* Update RGFW
* update RGFW
* undo change
* undo change
* undo change
* undo change
* have .scroll be 0 by default
* update RGFW
* update RGFW
* update RGFW
* fix year
* fix wasm key event bug
* update RGFW
* link to IOKit
* update
2025-02-21 12:32:09 +01:00
Ray
5ea60dd3ce
Minor tweaks
2025-02-20 18:10:01 +01:00
Ray
32fcfd3549
Minor tweaks
2025-02-19 13:38:22 +01:00
sleeptightAnsiC
77df0ab1e8
[rcore_desktop_glfw.c] fix: make sure that GLFW uses RL_*alloc macros ( #4777 )
...
Raylib allows for providing custom allocators via macros.
GLFW supports this too, but via function pointers.
Make sure that GLFW uses those Raylib macros, by wrapping them in
function calls and setting them up inside of InitPlatform().
This is possible because of glfwInitAllocator() and GLFWallocator.
Fixes: https://github.com/raysan5/raylib/issues/4776
Relates-to: https://github.com/raysan5/raylib/issues/4751
2025-02-18 22:53:18 +01:00
Brian E
11090ab6cb
[raylib.h] Added space after comma ( #4774 )
...
args for ImageResizeNN were missing a space in the arguments after a comma, i just added one.
2025-02-17 12:12:59 +01:00
vict-Yang
b49c079b1d
Fix typo in rshapes.c ( #4772 )
2025-02-16 15:43:32 +01:00
Le Juez Victor
2b59e7475f
Implement Android-specific functions ( #4769 )
...
`GetWindowScaleDPI` and monitor physical dimensions
2025-02-15 19:34:51 +01:00
Le Juez Victor
c647d33703
Better default values for normals and tangents (VBOs) ( #4763 )
2025-02-14 01:00:05 +01:00
mannikim
ee946b2f16
use strstr instead of TextFindIndex ( #4764 )
2025-02-14 00:58:33 +01:00
veins1
1d87932d93
TextSubtext fixes ( #4759 )
...
Fix buffer write overflow
Fix reading past the end of text
2025-02-12 23:12:10 +01:00
goto40
6a644b48f0
doc: audio stream processor, number of channels ( #4753 )
...
* doc: audio stream processor
* fixed accidental encoding effect
2025-02-08 11:22:34 +01:00
Ray
cceabf6961
Formatting review
2025-02-02 13:00:20 +01:00
Ray
cfe96931f5
REVIEWED: Formatting #4739
2025-02-02 12:59:34 +01:00
Nikolas
bddb5df0d4
[rmodels] Separate GLTF roughness and metallic channels on load ( #4739 )
2025-02-02 12:48:18 +01:00
Henrik A. Glass
4f5a20a634
Add missing increments of k in LoadImageDataNormalized() ( #4745 )
2025-02-01 21:30:21 +01:00
whaley
e85ae86f70
[platforms/glfw] fix: allow GetGamepadButtonPressed() to return GAMEPAD_BUTTON_LEFT_TRIGGER_2 / GAME_PAD_BUTTON_RIGHT_TRIGGER_2 if they are pressed ( #4742 )
2025-02-01 10:50:25 +01:00
sleeptightAnsiC
99dfec070a
[rtext] fix: misuse of cast in GetCodepointCount ( #4741 )
...
I was really wondering what is going on here :D I believe this code
tried initially to out-cast 'const' specifier but this is not needed here
at all. Currently, it just confuses whoever reads this so I changed it.
The old code would also trigger -Wcast-qual warning on some compilers.
2025-01-31 14:44:23 +01:00
Eike Decker
1f6de0c507
Replacing hardcoded canvas id references with module variable usages ( #4735 )
...
Should also have the benefit of being faster.
2025-01-31 00:34:51 +01:00
Ray
d46ba9a671
Merge branch 'master' of https://github.com/raysan5/raylib
2025-01-28 16:19:39 +01:00
Ray
9789ff123b
REVERTING: emscripten_sleep() previous removal #4713
2025-01-28 16:19:30 +01:00
Peter0x44
2492dd3d0a
[build] [Makefile]: Undefine _GNU_SOURCE for rglfw.c ( #4732 )
...
Currently, a warning about _GNU_SOURCE being redefined is emitted when
compiling rglfw.c
In file included from rglfw.c:99:
external/glfw/src/posix_poll.c:27:9: warning: "_GNU_SOURCE" redefined
27 | #define _GNU_SOURCE
| ^~~~~~~~~~~
<command-line>: note: this is the location of the previous definition
This can be avoided by not defining _GNU_SOURCE on the command line for
this file.
Defining feature test macros in source code is not really good practice
so this should probably reviewed in glfw itself, at least to maybe check
#ifdef _GNU_SOURCE first. But for now this change will suffice.
Fixes #4725
2025-01-27 23:15:09 +01:00
Asdqwe
f6f31a9f21
[rtextures] Fix HalfToFloat() and FloatToHalf() dereferencing issues with an union ( #4729 )
...
* Fix HalfToFloat() and FloatToHalf() dereferencing issues with an union
* Remove unnecessary initialization
* Moved the union to inside the functions
2025-01-26 21:26:18 +01:00
Asdqwe
139de05e9d
[rcore] [SDL2] Fix gamepad event handling by adding joystick instance id tracking ( #4724 )
...
* Fix gamepad SDL_JOYDEVICEADDED and SDL_JOYDEVICEREMOVED event handling for PLATFORM_DESKTOP_SDL by adding joystick instance id tracking
* Fix gamepad button handling
2025-01-25 20:49:42 +01:00
Nikolas
49d37b035f
[rtexture] Cubemap mipmap loading improvements ( #4721 )
...
* [rtextures] Only build cubemap mipmaps when necessary
* [rtextures] Assign correct mipmap count to cubemaps
2025-01-24 10:41:32 +01:00
Ray
87f17538d0
Reviewed warning on shared library generation for web
2025-01-21 19:23:16 +01:00
sleeptightAnsiC
322ba54c08
Fix(WEB): Makefile: throw an error when trying to build SHARED library ( #4718 )
...
When asking Makefile to create SHARED library for WEB
$ make TARGET_PLATFORM=PLATFORM_WEB RAYLIB_LIBTYPE=SHARED
it would instead silently create STATIC library
thus not fulfilling the request as expected
This commit adds an error in this case and stops further execution.
This is not consistent with Cmake, because Cmake throws the warning and
does not stop, but Cmake can easily recover from this case and people
probably does not even notice it. However, Makefile is something that
you have to handle yourself and you have to recover from any issues so
having an error and aborting with exit code 1 is more expected.
Otherwise people may spend a lot of time debugging Makefile in order to
understand what's even going on.
Fixes: https://github.com/raysan5/raylib/issues/4717
2025-01-21 19:20:51 +01:00
Ray
2c50da9a6a
REVIEWED: -sASSERTIONS usage by linker #4717
2025-01-21 19:18:23 +01:00
Ray
d48b8afbb5
Update rcore_web.c
2025-01-20 14:01:57 +01:00
Anthony Carbajal
77c509db6e
removed hardcoded sleep ( #4713 )
2025-01-20 12:14:18 +01:00
sleeptightAnsiC
10d0616d1f
fix(rtextures): TCC not being able to compile due to: 'emmintrin.h' not found ( #4707 )
...
define STBIR_NO_SIMD when __TINYC__ is defined so stb_image_resize2 will
not include *mmintrin which are not supported by all compilers.
There are similar checks for __TINYC__ already elswere in raylib
and they are also mostly there to disable SIMD headers.
Additionally, move similar check for stb_image, to be a little bit
deeper. Before it was defining STBI_NO_SIMD without including stb_image
It was also clashing with note, causing said note to make no sense.
Fixes: https://github.com/raysan5/raylib/discussions/2994
Reference: https://github.com/nothings/stb/issues/1738
2025-01-19 12:06:27 +01:00
Chris
09272e2e11
Updted the comment for SetShaderValueTexture to reflect the difference between SetShaderValue using sampler2d and SetShaderValueTexture is the automatic bind of the texture. ( #4703 )
2025-01-18 20:24:48 +01:00
Ray
896ff68540
REVIEWED: Text functions usage notes #4704
2025-01-18 20:19:11 +01:00
Ray
74256943a4
REVIEWED: MAX_GAMEPAD_NAME_LENGTH #4695
2025-01-18 19:39:50 +01:00
Ray
313067d749
Update rlgl.h
2025-01-16 19:47:21 +01:00
Ray
94f261c6d7
Update rmodels.c
2025-01-16 19:47:12 +01:00
Colleague Riley
6bf40eee4f
Update to RGFW 1.5 ( #4688 )
...
* add PLATFORM_WEB_RGFW
* fix some bugs
* fix web_rgfw gamepad
* send fake screensize
* fix gamepad bugs (linux) | add L3 + R3 (gamepad)
* fix?
* update RGFW (again)
* update raylib (merge)
* fix xinput stuff
* delete makefile added by mistake
* update RGFW
* update RGFW (rename joystick to gamepad to avoid misunderstandings
* update RGFW (fix X11 bug)
* update RGFW
* use RL_MALLOC for RGFW
* update RGFW (fixes xdnd bug)
* fix some formating
* Update RGFW
* update RGFW
* undo change
* undo change
* undo change
* undo change
* have .scroll be 0 by default
* update RGFW
* update RGFW
* update RGFW
* fix year
* fix wasm key event bug
2025-01-16 00:34:27 +01:00
Eike Decker
5c1cce28a7
Using Module provided canvas id for event binding ( #4690 )
...
This change is replacing the hardcoded "#canvas" element references in
rcore_web to allow using canvas elements that use different names
(which is necessary when using multiple canvas elements on one page).
Also adding a cursor hiding example to mouse example.
2025-01-16 00:32:58 +01:00
tea☆
1cdf3bb791
[rshapes] Allow DrawRectangleRounded() to draw rectangles with a size < 1 ( #4683 )
...
Closes #4673
2025-01-12 18:46:49 +01:00
Ray
a1896c7a90
REVIEWED: Code/Web-Makefile formatting
2025-01-12 16:19:10 +01:00
Ray
e227371265
REVIEWED: TextJoin(), convert const char ** to char**
...
It generates multiple issues: https://c-faq.com/ansi/constmismatch.html
2025-01-11 23:38:21 +01:00
Ray
49b905077d
remove trailing spaces
2025-01-11 19:36:26 +01:00
Ray
2b2694a89f
Fix #4680
2025-01-10 22:36:11 +01:00
Le Juez Victor
b554b53ede
fix pixel offset issue with DrawRectangleLines ( #4669 )
2025-01-10 17:36:52 +01:00
Ray
bf8962dbc7
REVIEWED: Remove some const from text buffer return values
...
Lately got some compilation `errors` related, it seems GCC 14 interprets some `const`-missmatch as errors instead of warnings (as previous versions).
But in any case, I don't see why an user won't be able to operate directly over of those returned buffers; `const` adds a restriction (for security reasons?) that in my opinion is useless.
From an expert on compilers (w64devkit creator), here there are some notes I agree with:
```
No const. It serves no practical role in optimization, and I cannot recall an instance where it caught, or would have caught, a mistake. I held out for awhile as prototype documentation, but on reflection I found that good parameter names were sufficient. Dropping const has made me noticeably more productive by reducing cognitive load and eliminating visual clutter. I now believe its inclusion in C was a costly mistake.
(One small exception: I still like it as a hint to place static tables in read-only memory closer to the code. I’ll cast away the const if needed. This is only of minor importance.)
```
Ref: https://nullprogram.com/blog/2023/10/08/
2025-01-10 13:06:28 +01:00
Le Juez Victor
ddd86a3387
[rshapes] Fix pixel offset issue with line drawing ( #4666 )
...
* fix pixel offset issue with `DrawRectangleRoundedLinesEx`
* improve fix - (pixel offset issue with `DrawRectangleRoundedLinesEx`)
* revert radius tweak (`DrawRectangleRoundedLines`)
2025-01-09 00:07:59 +01:00
K. Adam Christensen
5d9aed5d40
[rlgl] Optimize rlReadScreenPixels ( #4667 )
...
This optimization works in the following ways:
1. Reduces calls to malloc to 1. Instead of needing an extra array, we
can just swap the top half with the bottom half of the one array.
2. Unroll the inner for loop and remove a condition. Unrolling loops
buys some performance wins, but the real goal was to remove the if check
and just set the alpha channel to 255.
On my hidpi arm64 laptop, I saw ~60% improvement in performance in my
debug build (29 FPS vs 47 FPS). When optimized, the gains were roughly
10% (75 FPS vs 83%).
Signed-off-by: K. Adam Christensen <pope@shifteleven.com>
2025-01-08 18:53:27 +01:00
Maicon Santana
fc29bc27fd
Fix Touch pointCount reduction ( #4661 )
2025-01-06 11:29:24 +01:00
Asdqwe
ad035edfac
Fix camera initial position ( #4657 )
2025-01-05 12:30:43 +01:00
Brian E
05c4d8a652
[rlgl.h] Fixed typo in top comment ( #4658 )
...
"renderer" to "rendered"
2025-01-05 12:29:31 +01:00
veins1
97fa3a73e8
Fix: Alt-Tab not working in borderless fullscreen ( #3865 ) ( #4655 )
2025-01-03 17:36:48 +01:00
Ray
fa0eada61a
Update year to 2025
2025-01-01 00:02:52 +01:00
Peter Zmanovsky
d1315e8a04
[rmodels] Fix leaks in LoadIQM() and LoadModelAnimationsIQM() ( #4649 )
...
Add calls to UnloadFileData() before return in cases of invalid IQM file.
2024-12-29 21:06:40 +01:00
Ray
c0f2067dba
REVIEWED: LoadShaderFromMemory(), use default locations for default shader #4641
2024-12-28 16:35:42 +01:00
Asdqwe
5b822585e5
[rcore] [GLFW] [SDL2] Updates CORE.Window.eventWaiting and FLAG_WINDOW_ALWAYS_RUN handling ( #4642 )
...
* Add implementation for CORE.Window.eventWaiting on PLATFORM_DESKTOP_SDL
* Optimize GetFrameTime() reset
* Optimize FLAG_WINDOW_ALWAYS_RUN and GetFrameTime() reset for PLATFORM_DESKTOP_GLFW
2024-12-28 15:59:05 +01:00
Mario Nachbaur
7ecc47d12e
Fix IsWindowFocused() on web. ( #4640 )
2024-12-26 20:12:53 +01:00
Asdqwe
4758867815
[rcore] [SDL2] Add implementation for FLAG_WINDOW_ALWAYS_RUN ( #4598 )
...
* Enable FLAG_WINDOW_ALWAYS_RUN by default on PLATFORM_DESKTOP_GLFW
* Revert enabling FLAG_WINDOW_ALWAYS_RUN by default on PLATFORM_DESKTOP_GLFW
* Add implementation for FLAG_WINDOW_ALWAYS_RUN on PLATFORM_DESKTOP_SDL
* Add reset for GetFrameTime()
2024-12-26 19:02:57 +01:00
Colleague Riley
c333e80497
Update RGFW ( #4637 )
...
* add PLATFORM_WEB_RGFW
* fix some bugs
* fix web_rgfw gamepad
* send fake screensize
* fix gamepad bugs (linux) | add L3 + R3 (gamepad)
* fix?
* update RGFW (again)
* update raylib (merge)
* fix xinput stuff
* delete makefile added by mistake
* update RGFW
* update RGFW (rename joystick to gamepad to avoid misunderstandings
* update RGFW (fix X11 bug)
* update RGFW
* use RL_MALLOC for RGFW
* update RGFW (fixes xdnd bug)
* fix some formating
* Update RGFW
* update RGFW
* undo change
* undo change
* undo change
* undo change
* have .scroll be 0 by default
2024-12-25 21:19:51 +01:00
Le Juez Victor
873bf31be3
[rmodels] Fix normal transform in UpdateModelAnimationBones ( #4634 )
...
* remove duplicate calculation of `invRotation` in `UpdateModelAnimationBones`
* fix normal transform in `UpdateModelAnimation`
2024-12-24 20:17:37 +01:00
Ray
ae3c0df206
Reviewed formating, removed assert() #4635
2024-12-24 20:14:54 +01:00
Jett
a7686c47b3
resolved a few segfaults with animation system ( #4635 )
...
* Update rmodels.c
resolves segfault with missing bone weights or bone IDs
* Update rmodels.c segfault with animation and missing normals/animnormals
* correct place.
2024-12-24 20:11:17 +01:00
Fancy2209
7868d600f4
[rtext] Fix default font alpha on Big Endian systems ( #4624 )
...
* Fix rtext default font alpha on Big Endian
* Endian Indepence
2024-12-23 22:25:22 +01:00
veins1
e5d8de7c63
Fix: Setting flags disables fullscreen #4618 ( #4619 )
2024-12-23 19:26:50 +01:00
Ray
67b164bc04
Merge branch 'master' of https://github.com/raysan5/raylib
2024-12-23 19:24:09 +01:00
Ray
6f0d8611fe
Formating tweaks
2024-12-23 19:24:07 +01:00
Jett
0212ed0a4b
setting MAX_LEVEL based on actual mipcount input ( #4622 )
2024-12-20 14:14:13 +01:00
Fancy2209
26e12d6b35
Fix Typo in rcore_desktop_sdl.c ( #4621 )
2024-12-20 13:53:51 +01:00
Ray
ab83e6dd41
Image manipulation functions depend on a flag
2024-12-19 13:24:30 +01:00
Ray
03ff864087
Formating tweaks
2024-12-18 18:44:23 +01:00
Asdqwe
99cb4cbc36
Fix SetGamepadVibration() TRACELOG message ( #4615 )
2024-12-18 14:53:50 +01:00
Ray
783ca612cc
Update Makefile
2024-12-18 12:51:00 +01:00
Colleague Riley
58004723d8
[rcore][RGFW] Add new backend option: PLATFORM_WEB_RGFW and update RGFW ( #4480 )
...
* add PLATFORM_WEB_RGFW
* fix some bugs
* fix web_rgfw gamepad
* send fake screensize
* fix gamepad bugs (linux) | add L3 + R3 (gamepad)
* fix?
* update RGFW (again)
* update raylib (merge)
* fix xinput stuff
* delete makefile added by mistake
* update RGFW
* update RGFW (rename joystick to gamepad to avoid misunderstandings
* update RGFW (fix X11 bug)
* update RGFW
* use RL_MALLOC for RGFW
* update RGFW (fixes xdnd bug)
* fix some formating
2024-12-18 12:03:42 +01:00
Ray
de6c09ee7a
WARNING: REVIEWED: Use libraylib.web.a naming on PLATFORM_WEB
...
This change allows to have in same directory (currently `raylib/src`) two raylib build versions: Desktop and Web
2024-12-18 11:45:55 +01:00
Ray
f76734fc50
REVIEWED: UpdateModelAnimationBones(), break on first mesh found and formating
2024-12-18 11:43:43 +01:00
Kirandeep-Singh-Khehra
35c2408413
[rmodels] Optimized UpdateModelAnimationBones() function ( #4602 )
...
- Updating bones only once instead for each mesh.
- Updating only one `model.meshes[].boneMatrices` and then using deep copy for other meshes instead of calculating for each bone in each mesh.
**Other points:**
- Makes it a clean base/template/reference for bone updation functions. Because if using this as template then some calculations done in one mesh can affect bones in other mesh in next iteration(doubles the effect in for next mesh).
Signed-off-by: Kirandeep-Singh-Khehra <kirandeepsinghkhehra@gmail.com>
2024-12-18 11:39:50 +01:00
Asdqwe
cdaff163cb
Fix show, hide, focus and unfocus window/flags states for SDL2 ( #4610 )
2024-12-18 11:39:30 +01:00
JupiterRider
714cd5ef5c
add SetGamepadVibration to rgfw and template ( #4612 )
2024-12-18 11:38:11 +01:00
Asdqwe
bdfbd6e8cc
Fix maximizing, minimizing and restoring windows for SDL2 ( #4607 )
2024-12-16 22:19:00 +01:00
Le Juez Victor
79facde353
fix rlActiveDrawBuffers for OpenGL ES 3 ( #4605 )
2024-12-16 00:51:42 +01:00
Per Hallsmark
d0504800d2
install rcamera.h ( #4603 )
...
Signed-off-by: Per Hallsmark <per.hallsmark@bitjuggler.se>
2024-12-15 11:16:08 +01:00
__hexmaster111
8a5a95c13a
Removed inaccurate comment about negitves not being supported with TextToFloat And TextToInt Methods ( #4596 )
2024-12-13 09:21:13 +01:00
Ray
1f704be4e4
Review comments spacing for better alignment
2024-12-12 12:13:38 +01:00
Ray
6b220f2798
Review formating
2024-12-12 12:13:17 +01:00
Rico P
2a2acff2d5
Make sure ShaderUniformDataType matches rlShaderUniformDataType ( #4577 )
...
* Make sure ShaderUniformDataType matches rlShaderUniformDataType
* Update raylib_api.* by CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Ray <raysan5@gmail.com>
2024-12-08 12:52:06 +01:00
Michael
d2cd2a0152
[rlgl][rmodels] Add instranceTransform shader location index #4538 ( #4579 )
2024-12-08 12:48:54 +01:00
Ray
602583bcdb
Merge branch 'master' of https://github.com/raysan5/raylib
2024-12-03 19:14:29 +01:00
Ray
1f45e7af76
REVIEWED: Coding conventions
2024-12-03 19:14:14 +01:00
Caleb Heydon
5feccb1bab
[rmodels] Fixed null pointer dereference in LoadGLTF ( #4564 )
...
* [rmodels] Fixed null pointer dereference in LoadGLTF
* [rmodels] Add parenthesis around conditionals in LoadGLTF
2024-12-03 18:35:24 +01:00
Caleb Heydon
f3f5f38c0f
[rmodels] Fix crash when NULL is passed to LoadImageFromCgltfImage ( #4563 )
2024-12-02 13:35:54 +01:00
Ray
b50d418ec7
Merge branch 'master' of https://github.com/raysan5/raylib
2024-12-01 23:25:27 +01:00
Ray
dd26df0be8
REVIEWED: Parser issue with comment #4558
2024-12-01 23:25:12 +01:00
Rico P
ff71e3a513
use unused variable. Fixes #4560 ( #4561 )
2024-12-01 23:22:46 +01:00
Ray
962f1c26ff
Review formatting to follow raylib conventions
2024-12-01 23:10:59 +01:00
Caleb Heydon
9047630ae7
[rmodels] Fix null pointer dereference in LoadImageFromCgltfImage ( #4557 )
2024-12-01 22:46:26 +01:00
Ray
503cd7ba34
Update raymath.h
2024-12-01 22:45:09 +01:00
Jonathan Akaba
1b4e73cf2f
Update documentation for Vector2Angle ( #4556 )
2024-12-01 22:43:32 +01:00
Caleb Heydon
58fe34d9cc
[raudio] Fixed buffer overflow when loading WAV files ( #4539 )
2024-11-28 22:58:35 +01:00
Mossieur-Patate
2c4c6e6201
GetKeyName prototype ( #4544 )
...
* Update raylib.h: GeyKeyName prototype
Prototype for GetKeyName, which is already implemented elsewhere.
* Update raylib_to_parse.h: GetKeyName prototype
2024-11-28 22:50:00 +01:00
Ray
abb3c8e9f7
Revert "[build][cmake] Improve cmake config file generation ( #4541 )"
...
This reverts commit c53dd8a931 .
2024-11-28 22:44:42 +01:00
Leonardo Guilherme de Freitas
c53dd8a931
[build][cmake] Improve cmake config file generation ( #4541 )
...
* Improve cmake config file generation
This allows for finding raylib on a non-standard location (eg, not in /usr/lib{,64})
* Only have glfw as private if using internal glfw and not static
2024-11-27 11:39:36 +01:00
Anthony Carbajal
79188f570b
fixed spacing in sha1 comment ( #4540 )
2024-11-25 20:17:22 +01:00
Jeffery Myers
6141489b00
Fixes casting warnings with RGFW platform. ( #4534 )
2024-11-24 16:25:36 +01:00
listeria
e494c545b8
raymath: fix C++ operator overloads ( #4535 )
...
Co-authored-by: Listeria monocytogenes <listeria@disroot.org>
2024-11-24 16:24:34 +01:00
Ray
da6fa1d756
Fix #4529
2024-11-22 11:06:34 +01:00
Ray
50a2afff9e
Update raylib version to 5.6-dev to avoid confusions with release
2024-11-22 11:01:10 +01:00
Asdqwe
a53a8958f2
Add implementation to GetWindowScaleDPI() for PLATFORM_WEB ( #4526 )
2024-11-22 10:52:55 +01:00
veins1
11429b48eb
Fix for #4521 ( #4523 )
2024-11-20 21:28:46 +01:00
Gael Pérez
415a98965a
update raymath.h: add Vector2CrossProduct function ( #4520 )
2024-11-20 11:27:14 +01:00
Ray
26548c1062
Remove trail-spaces
2024-11-19 12:33:13 +01:00
Ray
9e4f513a43
Reviewed formating
2024-11-19 12:31:57 +01:00
Ray
c78757a959
REVIEWED: GetClipboardImage(), make symbol available on all platforms
2024-11-19 12:31:49 +01:00
Ray
10789a4d49
Update rlgl.h
2024-11-19 12:31:14 +01:00
mikeemm
95e766472f
[rmodels] Improve OBJ vertex data precision and lower memory usage by ExportMesh() ( #4496 )
...
* increased vertex data precision to match blender exports
* modified memory allocation to better fit higher precision data
* now accounting for newline characters during allocation
* now accounting for potentially higher vertex counts
* removed unnecessary final newline
2024-11-19 10:35:47 +01:00
Ray
938b805bfb
Update raylib.h
2024-11-16 18:45:16 +01:00
Eike Decker
7c5d74e98e
Fixing an OBJ loader bug that fragmented the loaded meshes ( #4494 )
...
The nextShapeEnd integer is a pointer in the OBJ data structures.
The faceVertIndex is a vertex index counter for the mesh we are
about to create. Both integers are not compatible, which causes
the code to finish the meshes too early, thus writing the OBJ data
incompletely into the target meshes.
It wasn't noticed because for the last mesh, it process all remaining
data, causing the last mesh to contain all remaining triangles.
This would have been noticed if the OBJ meshes used different textures
for each mesh.
2024-11-15 16:40:14 +01:00
Ray
5e6cdf3a73
Update emsdk path on Windows to match new raylib installer package
2024-11-14 18:41:37 +01:00
Ray
76016aae20
Update raylib.ico
2024-11-14 16:40:04 +01:00
Ray
15eb8221e3
Updated raylib resource data
2024-11-14 16:39:58 +01:00
Ray
928535a828
Commented code issuing warnings on w64devkit (GCC)
...
Tested with w64devkit/MSVC and all seem to work as expected
2024-11-14 16:39:38 +01:00
Asdqwe
700e2c5e5d
Fix touch count reset ( #4488 )
2024-11-14 10:49:35 +01:00
Everton Jr.
5cc06f4ba4
[rcore]: Issue an warning instead of an error when checking SUPPORT_CLIPBOARD_IMAGE necessary support detection ( #4477 )
2024-11-11 19:47:25 +01:00
Jeffery Myers
fb69b39d54
Fix a typecast warning in glfw clipboard access ( #4479 )
2024-11-11 19:46:54 +01:00
Jeffery Myers
2af4f31712
Fix the X axis of the second vertex of the Y negative cap of a cylinders, triangle fan ( #4478 )
2024-11-10 22:04:58 +01:00
Everton Jr.
00396e3436
[rcore] Clipboard Image Support ( #4459 )
...
* [rcore] add 'GetClipboardImage' for windows
* [rcore] GetClipboardImage removed some unneeded defines
* [rcore] PLATFORM_SDL: create a compatility layer for SDL3
* external: add win32_clipboard.h header only lib
* [rcore] using win32_clipboard on platforms rlfw and rgfw
* [rcore] fix warnings in SDL3 compatibility layer
* Makefile: Allow specifying SDL_LIBRARIES to link, this helps with SDL3
* Makefile: examples makefile now compile others/rlgl_standalone only when TARGET_PLATFORM is PLATFORM_DESKTOP_GFLW
* Makefile: examples makefile now compile others/rlgl_standalone only when TARGET_PLATFORM is PLATFORM_DESKTOP_GFLW
* [rcore]: PLATFORM_SDL: improve clipboard data retrieval
* external: remove unused function from win32_clipboard.h
* Makefile: allow for extra flags necessary when compiling for SDL3
* [rcore]: fix string typo
* [rcore]: Properly handle NULL dpi passing. As is allowed in SDL2
* external: fix arch finding on win32_clipboard.h to allow compilation on msvc cmake CI
* [rcore]: PLATFORM_SDL: Treat monitor as an ID in SDL3 as opposed to an index as in SDL2
* [rcore]: typo
2024-11-09 19:40:41 +01:00
Jett
dc489786b0
UpdateModelAnimation speedup ( #4470 )
...
If we borrow from the GPU skinned animation code, we can just multiply the vertex by the matrix * weight and shave a chunk of CPU time.
2024-11-08 14:28:39 +01:00
Jeffery Myers
55a64f51b8
fix float casting warnings ( #4471 )
2024-11-07 21:42:59 +01:00
decromo
281ee51aff
implemented new linear gradient generation function ( #4462 )
2024-11-04 15:57:50 +01:00
waveydave
66a4f2e90b
Fix for issue 4454, MatrixDecompose() gave incorrect output for certain combinations of scale and rotation ( #4461 )
2024-11-03 20:36:32 +01:00
Ray
be360d2ad1
RENAMED: UpdateModelAnimationBoneMatrices() to UpdateModelAnimationBones()
...
Still, not fully convinced of those functions naming, despite quite descriptive, sounds a bit confusing to me...
2024-11-03 13:12:01 +01:00
MikiZX1
8e5d5f89c2
Update rmodels.c - 'fix' for GenMeshSphere artifact ( #4460 )
...
When creating a new sphere mesh with high number of slices/rings the top and bottom parts of the generated sphere are removed. This happens because the triangles in those parts, due to high resolution, end up being very small and are removed as part of the 'par_shapes' library's optimization. Adding par_shapes_set_epsilon_degenerate_sphere(0.0); before generating the sphere mesh sets the threshold for removal of small triangles is removed and the sphere is returned to raylib correctly.
2024-11-01 22:35:35 +01:00
Asdqwe
b8c0842b2e
Fix SetWindowSize() for PLATFORM_WEB ( #4452 )
2024-10-30 22:21:37 +01:00
Arche Washi
3bad05aa7b
fix the issue with GetScreenWidth/GetScreenHeight that was identified on other platforms ( #4451 )
2024-10-30 20:13:53 +01:00
Ray
d15e583460
Update rtext.c
2024-10-29 09:37:38 +01:00
Ray
10c8e4e435
Update rcore_desktop_glfw.c
2024-10-29 09:37:33 +01:00
Jeffery Myers
743e557e1e
Fix inconsistent dll linkage warning on windows ( #4447 )
2024-10-29 09:34:57 +01:00
mpv-enjoyer
de7ab83f5a
Fix empty input string for MeasureTextEx ( #4448 )
2024-10-29 09:33:03 +01:00
Jeffery Myers
0e1fc33c5c
Fix signed/unsigned mismatch in rlgl ( #4443 )
2024-10-26 22:59:50 +02:00
Colleague Riley
7fe5f7126b
Fix MSVC errors for PLATFORM_DESKTOP_RGFW ( #4441 )
...
* (rcore_desktop_rgfw.c) fix errors when compiling with mingw
* define WideCharToMultiByte
* update RGFW
* move stdcall def to windows only
* fix raw cursor input
* Fix warnings, update RGFW, fix msvc errors (make sure windows macro _WIN32 is correct)
2024-10-26 22:59:10 +02:00
Nikolas
38cf9f3224
[rtextures] LoadTextureCubemap(): Copy image before generating mipmaps, to avoid dangling re-allocated pointers ( #4439 )
2024-10-26 22:52:24 +02:00
Ray
7ad8fa689f
REVIEWED: LoadTextureCubemap() to avoid crash #4429
2024-10-26 13:51:10 +02:00
Ray
ec79bffa20
Update stb_truetype.h
2024-10-26 13:13:05 +02:00
Ray
dc679cd1c7
Update stb_image_resize2.h
2024-10-26 13:12:38 +02:00
Ray
28e7e2cffd
Update stb_image.h
2024-10-26 13:12:36 +02:00
Ray
d0e11a8c92
Update qoa.h
2024-10-26 13:12:33 +02:00
Ray
e70bf2bce1
Update dr_wav.h
2024-10-26 13:12:30 +02:00
Ray
c085c73014
Update dr_mp3.h
2024-10-26 13:12:26 +02:00
Ray
c6b1ecc593
Update cgltf.h
2024-10-26 13:12:24 +02:00
Ray
1f6b3384fa
Reviewed formatting, remove end-line points, for consistency with comments
2024-10-26 12:26:00 +02:00
Ray
80b490c8f1
Reviewed formating to follow raylib conventions #4429
2024-10-26 12:15:06 +02:00
Nikolas
7fedf9e0b8
[rtextures/rlgl] Load mipmaps for cubemaps ( #4429 )
...
* [rlgl] Load cubemap mipmaps
* [rtextures] Only generate mipmaps that don't already exist
* [rtextures] ImageDraw(): Implement drawing to mipmaps
* [rtextures] Load cubemap mipmaps
2024-10-26 12:09:38 +02:00
Ray
4e3fc84050
Minor format tweaks
2024-10-26 00:52:22 +02:00
Ray
22c77d17b7
REVIEWED: WebGL2 (OpenGL ES 3.0) backend flags (PLATFORM_WEB) #4330
2024-10-26 00:51:37 +02:00
Ray
16368cd353
REVIEWED: DrawRectangleLines(), considering view matrix for lines "alignment"
2024-10-24 13:11:39 +02:00
RadsammyT
385187f795
[rshapes] Review DrawRectangleLines() pixel offset ( #4261 )
...
* [rshapes] Remove `DrawRectangleLines()`'s + 1 offset
* ... and replace it with a -/+ 0.5 offset divided by current cam's zoom.
2024-10-24 13:08:12 +02:00
Ray
6ff0b03629
REVIEWED: UpdateModelAnimationBoneMatrices() comments
2024-10-24 12:46:02 +02:00
Ray
5065b85d33
Update rlgl.h
2024-10-24 12:45:12 +02:00
Ray
b0140b876b
REVIEWED: GPU skninning on Web, some gotchas! #4412
2024-10-24 12:25:05 +02:00
Ray
3483a4d9cb
Update raylib.h
2024-10-24 11:57:36 +02:00
Ray
5706cfd600
Update Makefile
2024-10-24 11:50:42 +02:00
Ray
d85c6fe2c0
Update raylib.h
2024-10-24 11:50:30 +02:00
Ray
2072b4fa04
Update raylib.h
2024-10-24 09:59:54 +02:00
Jeffery Myers
0b650f62a6
[RTEXTURES] Remove the panorama cubemap layout option ( #4425 )
...
* Remove the panorama cubemap layout, it was not implemented.
Left a todo in the code for some aspiring developer to finish.
* Update raylib_api.* by CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-10-24 09:06:24 +02:00
Ray
00c1f0836b
Update Makefile
2024-10-24 01:35:37 +02:00
Ray
708089f560
Reviewed and reverted unneeded module check, rtextures should not depend on rtext
2024-10-23 23:29:05 +02:00
Franz
6f4407cb15
Fix typo in rshapes.c ( #4421 )
2024-10-23 17:04:15 +02:00
Asdqwe
7a4a84a561
[rcore] Fix #4405 ( #4420 )
...
* Fix #4405 at runtime
* Add parameter validation
* Remove default global deadzone
2024-10-23 00:59:50 +02:00
Ray
4b60ce700f
Update raylib.h
2024-10-23 00:21:14 +02:00
Ray
352f4ce2c4
Update config.h
2024-10-23 00:21:06 +02:00
Asdqwe
4cd243f0a3
Simplify EmscriptenResizeCallback() ( #4415 )
2024-10-22 13:44:53 +02:00
Asdqwe
f8f6aa0907
[rcore] Adds implementation to SetGamepadVibration() on PLATFORM_WEB and updates it on PLATFORM_DESKTOP_SDL to handle duration ( #4410 )
...
* Updates SetGamepadVibration()
* Handle MAX_GAMEPAD_VIBRATION_TIME
* Revert low/high parameters back to left/rightMotor
* Fix missin semicolon
* Convert duration to seconds
* Add SetGamepadVibration() implementation to PLATFORM_WEB
2024-10-22 00:06:37 +02:00
Ray
cd3de0af0c
Merge branch 'master' of https://github.com/raysan5/raylib
2024-10-21 20:47:10 +02:00
Ray
f4cbc1fbae
REVIEWED: GetGestureHoldDuration() comments
2024-10-21 20:47:08 +02:00
Jeffery Myers
a2fcbc94fd
[Raymath] Add matrix operators to raymath for C++ ( #4409 )
...
* Add matrix operators to raymath for C++
* Fix spaces
2024-10-21 18:38:42 +02:00
Ray
f60c6d472c
Update raymath.h
2024-10-21 17:26:42 +02:00
Ray
f141c75cde
Removed trailing spaces
2024-10-21 17:00:52 +02:00
Ray
c935ca3168
Reviewed formatting #4408
2024-10-21 16:59:55 +02:00
Rapha
f402147a63
Updated instanced rendering support loading ( #4408 )
2024-10-21 16:56:19 +02:00
Ray
7601468211
REVIEWED: Formatting and raymath version #4385
2024-10-21 16:25:45 +02:00
Jeffery Myers
72f8c354b0
[Raymath] Add C++ operator overloads for common math function ( #4385 )
...
* Update raylib_api.* by CI
* Add math operators for C++ to raymath
* better #define for disabling C++ operators
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-10-21 16:17:50 +02:00
Sage Hane
110ee74875
build.zig: Merge src/build.zig to build.zig ( #4393 )
...
* build.zig: Move `src/build.zig` to `build.zig`
* build.zig: Remove uses of `@src`
* build.zig: Update entry point
2024-10-21 12:57:11 +02:00
Asdqwe
9d0b1f0171
Adds SetWindowOpacity() implementation for PLATFORM_WEB ( #4403 )
2024-10-21 09:47:19 +02:00
Asdqwe
cb21fe88d3
Fix MaximizeWindow() for PLATFORM_WEB ( #4404 )
2024-10-21 09:45:46 +02:00
Asdqwe
4290a0d9f2
[rcore] [web] Updates SetWindowState() and ClearWindowState() to handle FLAG_WINDOW_MAXIMIZED for PLATFORM_WEB ( #4402 )
...
* Updates SetWindowState() and ClearWindowState() to handle FLAG_WINDOW_MAXIMIZED for PLATFORM_WEB
* Update MaximizeWindow() and RestoreWindow() to set/unset the FLAG_WINDOW_MAXIMIZED
2024-10-21 01:04:32 +02:00
Nikolas
51ff6586f4
[rtextures] ImageDraw(): Don't try to blend images without alpha ( #4395 )
2024-10-21 00:31:01 +02:00
Asdqwe
3dbbe60376
Adds MaximizeWindow() and RestoreWindow() implementation for PLATFORM_WEB ( #4397 )
2024-10-21 00:29:32 +02:00
Sage Hane
ce9259cd02
build.zig: Fix various issues around -Dconfig ( #4398 )
...
* build.zig: Fix various issues around `-Dconfig`
* build.zig: Parse all relevant flags from `src/config.h` at comptime
2024-10-21 00:27:25 +02:00
Le Juez Victor
23354e1551
correction of comments ( #4400 )
...
The indication of locations for bone ids and bone weights did not correspond to their default values in config.h
2024-10-21 00:26:15 +02:00
Nikolas
902d3c92e3
[rl_gputex] Correctly load mipmaps from DDS files ( #4399 )
2024-10-21 00:25:33 +02:00
Sage Hane
dc5e6e0ad0
build.zig: Clean up my mess ( #4387 )
2024-10-18 21:03:27 +02:00
Anthony Carbajal
80393c0fb6
[rcore] added sha1 implementation ( #4390 )
...
* added sha1 implementation
* added missing part
* fixed issue
* fix to match other implementations
2024-10-18 01:15:19 +02:00
Asdqwe
a2e31c4e1b
Fix #4388 ( #4392 )
2024-10-17 15:35:49 +02:00
Ray
8cbf34ddc4
WARNING: BREAKING: Renamed several functions for data validation #3930
2024-10-16 19:26:12 +02:00
Ray
361b0e85c1
ADDED: Utility functions: ComputeCRC32() and ComputeMD5()
2024-10-16 16:49:50 +02:00
Jojaby
c9c830cb97
Fix rectangle width and height check to account for squares ( #4382 )
2024-10-15 19:04:30 +02:00
R-YaTian
8d267aaf23
qoi: Added support for image of channels 3 ( #4384 )
2024-10-15 19:03:17 +02:00
yuval_dev
99ff770edc
Fix the type mismatch caused due to unsupported ?[]const u8 ( #4383 )
...
Co-authored-by: Yuval Herman <yuvalherman99@gmail.com>
2024-10-15 19:02:20 +02:00
Sage Hane
c18677e70f
build.zig: Very minor fixes ( #4381 )
2024-10-13 20:24:39 +02:00
Ray
735308f8eb
REVIEWED: CodepointToUTF8(), clean static buffer #4379
2024-10-13 20:02:40 +02:00
Sage Hane
bac3798ad3
build.zig: Fix @src logic and a few things ( #4380 )
2024-10-13 18:58:42 +02:00
Ray
d29eb34cfb
REMOVED: LoadImageSvg()
2024-10-10 21:17:31 +02:00
Ray
1effe92129
WARNING: REMOVED: SVG files loading and drawing, moving it to raylib-extras
2024-10-10 20:37:46 +02:00
Sage Hane
d3f86eb957
build.zig: Improve logic ( #4375 )
...
* build.zig: Fix `@src` logic
* build.zig: Clarify build error
* build.zig: Add option for enabling `raygui`
* build.zig: Expose `Options` type
2024-10-10 18:56:43 +02:00
William Culver
c4be013294
Fix build.zig ( #4374 )
2024-10-10 18:56:29 +02:00
Harald Scheirich
454acca84b
Some update to gltf loading ( #4373 )
...
Only warns when there are more animations than currently implemented
Allows mesh indices to be unsigned char
2024-10-10 18:53:02 +02:00
Ray
3fb1ba25ac
Removed tabs and triple line-breaks
2024-10-08 18:45:52 +02:00
Colleague Riley
44e37c5f97
Update RGFW ( #4372 )
...
* (rcore_desktop_rgfw.c) fix errors when compiling with mingw
* define WideCharToMultiByte
* update RGFW
* move stdcall def to windows only
* fix raw cursor input
2024-10-08 18:39:15 +02:00
Anthony Carbajal
712ab798d1
updated makefile to disable wayland by default ( #4369 )
2024-10-08 18:33:33 +02:00
Anthony Carbajal
43b109a4e3
removed old comment ( #4370 )
2024-10-07 09:32:04 +02:00
Visen
b290d47bd5
[zig] Fix build.zig bug ( #4366 )
...
* fixed zig config.h bug
* zig fmt
2024-10-06 15:52:01 +02:00
Ray
f9e709915a
Fix #4355
2024-10-04 11:24:02 +02:00
Anthony Carbajal
da95f88c36
updated camera speeds with GetFrameTime ( #4362 )
2024-10-04 11:15:43 +02:00
Nikolas
0ef0791854
Allow Zig build script to change desktop backend ( #4358 )
2024-10-04 11:05:19 +02:00
Asdqwe
96d91a3892
[rlgl] Fix rlgl standalone defaults ( #4357 )
...
* Fix rlgl standalone defaults
* Fix rmodels
2024-10-02 11:41:21 +02:00
Jeffery Myers
09987b01cc
[MODELS] Better fix for GPU skinning issues ( #4353 )
...
* Make the max VBO match the animation flag.
* re-enable GPU skinning for mac, and fix the max buffer to be correct based on the GPU skinning support flag.
2024-10-02 10:49:56 +02:00
Asdqwe
d9c10ed264
Fixes GetClipboardText() memory leak for PLATFORM_DESKTOP_SDL ( #4354 )
2024-10-02 10:49:06 +02:00
Asdqwe
282d6478ba
Complements the #4348 GPU skinning fix ( #4352 )
2024-10-01 12:09:06 +02:00
Jeffery Myers
0e7bcd5639
[MODELS] Disable GPU skinning for MacOS platform ( #4348 )
...
* Update raylib_api.* by CI
* Disable GPU skinning on MacOS
Add GPU skinning example to MSVC Projects.
* Update raylib_api.* by CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-09-30 12:10:02 +02:00
Ray
84a4d93bc4
Fix #4349
2024-09-30 12:06:53 +02:00
Jeffery Myers
0573ef0382
[SHAPES] Add more detail to comment for DrawPixel ( #4344 )
...
* Update raylib_api.* by CI
* Add comment that draw pixel uses geometry and may be slow
* Update raylib_api.* by CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-09-27 23:06:54 +02:00
Menno van der Graaf
55e83468c9
Fix isGpuReady flag on android ( #4340 )
2024-09-24 20:02:54 +02:00
Ray
13178b9373
Update rcore.c
2024-09-22 23:01:22 +02:00
Ray
291063c98f
Update rcore.c
2024-09-22 22:56:21 +02:00
Ray
24a1cd8c5b
Update rcore.c
2024-09-22 22:50:47 +02:00
Ray
352c450ad0
Update rcore.c
2024-09-22 22:43:35 +02:00
Ray
100f6624d6
Update rcore.c
2024-09-22 22:36:17 +02:00
Ray
55a25ac04b
ADDED: MakeDirectory()
2024-09-22 22:11:08 +02:00
Ray
1eb8ff5e54
LoadFontDefault(): Initialize glyphs and recs to zero #4319
2024-09-22 18:05:58 +02:00
Asdqwe
212b1e5fe7
Fix rlgl standalone defaults ( #4334 )
2024-09-21 23:11:40 +02:00
Ray
e5d0cc978a
Some minor tweaks
2024-09-20 17:32:01 +02:00