Commit Graph

182 Commits

Author SHA1 Message Date
Ray 40f3df5b86 Update core_2d_camera_platformer.c 2024-01-24 21:17:11 +01:00
Ray 3f1e59a7cf Update copyright to 2024 2024-01-02 20:58:12 +01:00
Antonis Geralis 7ca95512d8
Review UnloadAutomationEventList (#3658)
* Review UnloadAutomationEventList

* Update raylib.h

* Update rcore.c

* Update core_automation_events.c

* Fix mistake
2023-12-23 12:14:39 +01:00
Matthew Oros 387506faab
[rcore] Remove unused vScreenCenter (#3632) 2023-12-13 21:22:44 +01:00
Ray e7ba72ded9 Update core_automation_events.c 2023-11-10 19:36:58 +01:00
Ray e4ea116857 Reviewing automation events on web... 2023-11-10 19:25:28 +01:00
Miloslav Milenkov a92c34d83c
Changed keybinds for the automation example to avoid conflict with browser shortcuts (#3519) 2023-11-10 15:04:04 +01:00
Ray 4c2340aea6 Update core_2d_camera_platformer.c 2023-11-08 23:35:27 +01:00
Ray 9c2308bdc3 Examples reviews 2023-11-08 23:28:31 +01:00
Ray 040b945fef Reviewed some examples and warnings 2023-11-08 20:09:32 +01:00
Ray bbf0c3a46d REVIEWED: Added new examples to VS2022 solution 2023-11-08 17:41:08 +01:00
Jeffery Myers 6cd37e57a6
Fix warnings in visual studio (#3512) 2023-11-06 20:31:07 +01:00
Ray 64d64cc181 REVIEWED: Potential code issues reported by CodeQL #3476 2023-11-01 15:28:18 +01:00
ubkp d8acceca14
Fix example core_3d_camera_free (#3488) 2023-10-31 10:10:43 +01:00
Ray f721429f25 ADDED: `SetAutomationEventBaseFrame(int frame)` 2023-10-27 01:19:10 +02:00
Ray 98fcbe3fe2 Update core_automation_events.c 2023-10-27 00:50:02 +02:00
Ray 654b4e6257 Update core_automation_events.c 2023-10-27 00:45:00 +02:00
Ray 99dac5451c ADDED: Automation Events System, exposed to users
Added new API to record and play events
Added examples illustrating functionality
2023-10-26 23:59:19 +02:00
MichaelFiber 18bedbd095
[core] Change axisCount to be an array (#3421)
* Update `PLATFORM_DRM` implementation of `GetGamepadAxisCount`

* Update

* Update `PLATFORM_DRM` implementation of `GetGamepadName`

* Add example to test gamepad info functions
Fix typo

* Update new gamepad info example

* Move axis count update out of GamepadThread - race condition

* Remove pointless if statement

* Start integrating stuff from the mikesinput lib

* Add more logging

* Add semicolon

* Add forgotten static

* More fixes

* Update axisCount to be array

* More debugging

* Add forgotten index to ready check

* Add path logging

* Missing parenthesis

* Add missing slash

* Fix axis count being reset to 0

* Fix missing paren

* Test polling joystick button events

* Major updates

* Fix missing array index

* Fix another missing array index

* Update example

* dumb logging

* Wrong constant for ev.code handling

* More dumb logging

* Remove some logging

* Add FPS to gamepad info example and try for max FPS

* tweak

* Revert example

* Add fps back

* Clean up after merge

* Switch axisCount to be an array
2023-10-14 22:51:35 +02:00
MichaelFiber daba1a2794
Split drm update input (#3397)
* Update `PLATFORM_DRM` implementation of `GetGamepadAxisCount`

* Update

* Update `PLATFORM_DRM` implementation of `GetGamepadName`

* Add example to test gamepad info functions
Fix typo

* Update new gamepad info example

* Move axis count update out of GamepadThread - race condition

* Remove pointless if statement
2023-10-11 10:30:51 +02:00
Ray fecf56e15a
WARNING: `rcore` module split per-platform **BIG CHANGE** (#3388)
* Submodules (#3311)

* Check in current state

* Add submodules to Makefile and clean up some imports

* Start moving InitGraphicsDeivce

* Move android_main and CloseWindow() out of rcore

* Move WindowShouldClose out of rcore

* Move IsWindowHidden out of rcore

* Move IsWindowMinimized out of rcore

* Move IsWindowMaximized, IsWindowFocused and IsWindowResized out of rcore

* Move ToggleFullscreen out of rcore

* Move MaximizeWindow, MinimizeWindow and RestoreWindow out of rcore

* Move 13 functions out of rcore:
ToggleBorderlessWindowed
SetWindowState
ClearWindowState
SetWindowIcon
SetWindowIcons
SetWindowTitle
SetWindowPosition
SetWindowMonitor
SetWindowMinSize
SetWindowMaxSize
SetWindowSize
SetWindowOpacity
SetWindowFocused

* Minor clean up, revert makefile change, include submodules directly in rcore

* Fix makefile comment

* Remove rcore.h from Makefile

* Remove debug include

* Move 18 functions from rcore to submodules
GetWindowHandle
GetMonitorCount
GetCurrentMonitor
GetMonitorPosition
GetMonitorWidth
GetMonitorHeight
GetMonitorPhysicalHeight
GetMonitorRefreshRate
GetWindowPosition
GetWindowScaleDPI
GetMonitorName
SetClipboardText
GetClipboardText
ShowCursor
HideCursor
EnableCursor
DisableCursor
GetTime

* Move TakeScreenshot, OpenURL, GetGamepadName out of rcore into submodules

* remove debugging #defines

* Move GetMonitorPhysicalWidth from rcore to submodule

* Move GetGamepadAxisCount from rcore

* Move SetGamepadMappings out of rcore

* Move GetMouseX, GetMouseY, GetMousePosition out of rcore

* Move SetMousePosition out of rcore

* Move GetMouseWheelMove out of rcore

* Move the last functions out of rcore

* Move shared function defs and some global var to rcore.h

* Clean up rcore.c and rcore.h a little more

* Remove unnecessary #define

---------

Co-authored-by: MichaelFiber <michael@cubeofb.org>

* REVIEWED: `PLATFORM_DESKTOP` Windows building

* Revert "REVIEWED: `PLATFORM_DESKTOP` Windows building"

This reverts commit 71a12171f7.

* Reviewed Windows building

* [split] Fix compilation for web (and desktop) (#3329)

* Fix compilation for web

* Remove EM_ASM_INT from core_input_gestures_web example

* Fix raymath undefined symbols for desktop and web

* Remove raylib_opengl_interop from examples Makefile

* Revert previous commit (8651c78)

* Fix TraceLog for web and desktop

* [split] `rcore`, `rcore_web` and `rcore_desktop` changes (batch 2) (#3334)

* Fix formatting

* Reapply commit 9d230d7 (#3305) that was missing

* Reapplies commits 719365f (#3309) and 8a1779b (#3312) that were missing

* Reapply commit 5c9cc3f (#3323) that was missing

* Reapply commit a2b3b1e that was missing

* Revert commit cef25c6 to fix macro redefined warning

* Move rcore.h #include to after config.h to fix macro redefinitions warnings

* [split] `rcore`, `web`, `desktop`, `android` changes (batch 3) (#3338)

* First pass to remove unneeded platform macros for web

* Second pass to remove unneeded platform macros for web

* Move GetTouchX, GetTouchY, GetTouchPosition from rcore to web, desktop, android

* Move SetMouseCursor from rcore to android, desktop, web

* [split] `rcore`, `web`, `desktop`, `android` changes (batch 4) (#3343)

* Fix ToggleBorderlessWindowed duplicated glfwSetWindowSize calls

* First pass to remove unneeded platform macros for android

* Second pass to remove unneeded platform macros for android

* Remove unneeded platform macros for desktop

* Relocate GetGamepadName and update SetGamepadMappings on android, desktop, web

* Add missing comment to web

* [split] `rcore`, `web`, `desktop`, `android` changes (batch 5) (#3345)

* Move SetExitKey from core to android, desktop, web

* Move some callbacks from core to desktop and web

* Relocate emscripten callbacks on web

* Relocate android callbacks on android

* Revert "Relocate android callbacks on android"

This reverts commit bbdbecc01e.

* Updates UnloadVrStereoConfig on rcore

* Update SetClipboardText on android

* Fix screenMin/Max default values for android

* [split] `rcore`, `drm` changes (#3347)

* Tweak makefiles for PLATFORM_DRM and move rcore_drm's dependencies to rcore.h

* Move drm functions to rcore_drm.c

* Fix a typo in rcore.c

* Add SetExitKey to rcore_drm.c

---------

Co-authored-by: MichaelFiber <michael@cubeofb.org>

* Fix compilation for android (#3360)

* Fix android include (#3364)

* Reviewed platform split #3313

 - Added file headers info
 - Added TRACELOG message for unimplemented functions
 - Reviewed code formatting and organization
 - Several code tweaks

* REVIEWED: `GetDirectoryPath()`

---------

Co-authored-by: MichaelFiber <42419558+michaelfiber@users.noreply.github.com>
Co-authored-by: MichaelFiber <michael@cubeofb.org>
Co-authored-by: ubkp <118854183+ubkp@users.noreply.github.com>
2023-10-08 18:36:07 +02:00
Ray 1896268775 Reviewed examples for consistency 2023-09-08 13:27:13 +02:00
Gabriel dos Santos Sanches 2d5d0c2999
examples: core: adds 2D camera two player split screen (#3298) 2023-09-08 12:22:12 +02:00
MichaelFiber 18e9784c6d
Remove PLATFORM_RPI (#3232)
* Remove PLATFORM_RPI

* remove build artifacts

---------

Co-authored-by: MichaelFiber <michael@cubeofb.org>
Co-authored-by: Ray <raysan5@gmail.com>
2023-09-07 17:42:28 +02:00
Asdqwe 1d2b43402e
Remove a duplicated screenshot and add missing one (#3275) 2023-08-30 22:39:44 +02:00
Ray 86f95d7150 Reviewed C compilation issues and formatting 2023-07-16 13:24:49 +02:00
ubkp b980268ba7
[example] Core Input Gestures for Web (#3172)
* [example] Core Input Gestures for Web

* Fix Doubletap for web

* Changes TAP_TIMEOUT and rgGetCurrentTime to seconds
2023-07-16 13:07:29 +02:00
iacore 7392c4b0c5
Better examples/core_input_gamepad (#3110)
* examples/core_input_gamepad: Add visuals for LT,RT

* examples/core_input_gamepad: arrows left/right to choose gamepad

* Style change
2023-06-14 20:46:10 +02:00
Mansour Quddus 4f43ceb0d2
add missing space in one of the cameraDescriptions (#2977) 2023-03-21 08:31:29 +01:00
Ray 2e02474b7a Update core_loading_thread.c 2023-03-19 11:25:29 +01:00
Ray 8ca3212701 REVIEWED: `UpdateCameraPro()` to use `Vector3` 2023-03-12 19:40:43 +01:00
Ray f9c4cc2040 ADDED: `UpdateCameraPro()` -Experimental-
REVIEWED: rcamera module formating
REVIEWED: `core_3d_camera_example`
2023-03-12 19:28:42 +01:00
Ray 614e0518a7 Remove trailing spaces 2023-03-06 14:58:58 +01:00
Ray 6897b43599 REVIEWED: `core_drop_files` #2943 2023-03-03 20:13:35 +01:00
Ray ea590c44a9 REVIEWED: Camera redesign PR 2023-02-14 20:00:51 +01:00
Crydsch Cube 73989a4981
WIP rcamera redesign vector (#2563)
* core functionality CAMERA_FREE

* fix example

* add remaining camera modes

* add view bobbing

* view bobbing

* catch curser in SetCameraMode

* adjust examples

* fix compilation on linux

* fix example text_draw_3d

* actually fix text_draw_3d

* Updated camera API

* Improve Vector3RotateByAxisAngle() function

* remove camera.mode dependency from low-level functions

* remove camera.mode from struct

* fixes after rebase

* adjust examples for new UpdateCamera function

* adjust example models_loading_m3d

---------

Co-authored-by: Ray <raysan5@gmail.com>
2023-02-14 17:47:21 +01:00
Antonis Geralis 212f331583
Update core_input_gamepad.c (#2903) 2023-02-01 15:13:25 +01:00
Jeffery Myers 81ca2f0bf3
Fix warnings and bad project settings for 4.5 release (#2894) 2023-01-27 19:20:42 +01:00
Ghost 2a2f2b20b8
Fixed bug : touches become sticky (#2857)
Touches became sticky and didn't disappear after using more than 2 fingers, fixed by getting the touch count of how many fingers are on the screen, and only looping through the available/pressed down touch points instead of looping through the maximum touch points.
Tested with more than 10 touch points, and with different MAX points value, working perfectly.
2023-01-14 19:41:42 +01:00
Antonis Geralis 1dbcce8b56
Use explicit atomics (#2849)
* Use explicit atomics

* missed one

* use relaced ordering
2023-01-02 16:48:53 +01:00
Ray e2a8066fca Update year to 2023 2023-01-01 16:07:51 +01:00
Ray b59fab7ee6 Update year to 2023 2023-01-01 16:00:56 +01:00
Antonis Geralis ba38fe5b97
core_loading_thread example join thread on completion (#2845)
* core_loading_thread example join thread on completion

* error checking
2022-12-31 19:25:35 +01:00
Ray 3c51d066f1 Avoid using `DrawCubeTexture()` 2022-11-15 12:26:22 +01:00
Ray 07bbfe86b9 Update core_basic_window.c 2022-10-11 22:28:40 +02:00
murilluhenrique eaa0b9102b
Fix typo (#2696) 2022-09-16 00:06:25 +02:00
hartmannathan c1b4881e8a
examples/core/core_custom_logging.c: Fix typo (#2692) 2022-09-08 16:10:15 +02:00
Ray ac3420faac Update core_custom_frame_control.c 2022-09-04 12:32:40 +02:00
skylar ee5a87826d
Fixed a bug in the 2d camera platformer example (#2687)
canJump used to alternate between true and false when on ground
2022-09-04 11:48:33 +02:00
Ray 75ece337ae Revert "Update core_3d_camera_mode.c"
This reverts commit 4f6fbaed41.
2022-08-11 12:28:21 +02:00