Commit Graph

1667 Commits

Author SHA1 Message Date
Ray
9e2c418a92 Removed dev from version 2018-07-11 16:40:08 +02:00
Ray
eb296a5605 Reviewed shared library generation 2018-07-11 16:39:41 +02:00
Ray
43178f3488 Updated mini_al to latest dev version
Corrects issue with audio on RPI
2018-07-11 16:39:26 +02:00
Ahmad Fatoum
414bb6018b
CMake: Add Libs.private to Libs if installing static only
pkg-config --libs --static raylib and pkg-config --libs raylib
should give the same result if there is no shared raylib installed.
2018-07-10 21:20:01 +02:00
raysan5
3c02a9fc66 Support multiple data type aliases
Vector4 -> Quaternion
Texture2D -> Texture
RenderTexture2D -> RenderTexture
Camera3D -> Camera
SpriteFont -> Font
2018-07-09 10:23:53 +02:00
raysan5
f939378764 Support ARM and ARM64 Android building 2018-07-09 03:00:52 +02:00
raysan5
c6d188a09a Reviewed latest commit for Android gamepad support 2018-07-07 10:15:19 +02:00
Ray
50088bf49b
Merge pull request #570 from SethArchambault/master
SNES-like GAMEPAD Support added for Android, Makefile has optional support for 32bit
2018-07-07 09:38:19 +02:00
David Reid
8651e14955 Update mini_al with a fix for macOS. 2018-07-07 10:36:19 +10:00
Seth Archambault
fa36c5294a Merge branch 'master' of https://github.com/raysan5/raylib 2018-07-06 13:37:17 -04:00
Seth Archambault
f981daf1df Added SNES-style GAMEPAD SUPPORT 2018-07-06 13:33:46 -04:00
Ahmad Fatoum
7f040009ee
Add null statement after goto label to pacify CI
Fixes: #568
2018-07-06 02:30:38 +02:00
Ray
0ab3d85aa0
Merge pull request #568 from mackron/dr/mini_al
Update Audio Libraries
2018-07-06 00:31:21 +02:00
raysan5
103bc7dfc6 Corrected issue with GetFontDefault()
Note for me: Replace All is NOT your friend...
2018-07-05 19:17:06 +02:00
raysan5
d881c73257 Renamed GetDefaultFont() to GetFontDefault()
Library consistency rename... yes, I know, it breaks the API...
2018-07-05 19:08:24 +02:00
raysan5
1f1d8eeeeb Checking Android input functionality
Joystick support is not implemented just yet, not difficult but it
requires some work...
2018-07-05 19:00:49 +02:00
David Reid
b7d7704098 Update mini_al to version 0.8. 2018-07-05 23:12:20 +10:00
David Reid
6c96fa6301 Update external audio libraries. 2018-07-05 22:57:45 +10:00
David Reid
c598701873 Fix bug with FLAC music streams. 2018-07-05 22:57:17 +10:00
David Reid
1d354bc704 Merge branch 'master' of https://github.com/raysan5/raylib into dr/mini_al 2018-07-05 22:33:16 +10:00
Ahmad Fatoum
c3aeaf4a49
Travis CI: Add test case for pkg-config 2018-07-03 21:35:28 +02:00
Ahmad Fatoum
61747508b0
CMake: Reuse libraries found by glfw CMake config
if (${PLATFORM} MATCHES "Desktop")
  target_link_libraries(${RAYLIB}_shared glfw ${GLFW_LIBRARIES})

was never true because PLATFORM STREQUAL "PLATFORM_DESKTOP"...

This fixes #551 and makes the changes suggested in #552 (commited as 965cc8ab)
unnecessary.
2018-07-03 21:35:27 +02:00
Ahmad Fatoum
33c830353b CMake: Fix regression in USE_EXTERNAL_GLFW=IF_POSSIBLE
Fixes: e1e036a6 ("Disable glfw only when it is not found and not external", #558)
2018-07-03 09:24:31 +02:00
Ray
74fd0e7ca4 Added function: ImageColorReplace() 2018-07-03 00:57:58 +02:00
Ray
7b971e0623 Added Quaternion typedef 2018-07-02 18:53:46 +02:00
Ray
276974de05 Removed function prototype
This function was added in text module as GenImageFontAtlas()
2018-07-02 16:39:04 +02:00
Ray
7dedb84fd0 Added function: Vector3RotateByQuaternion()
Rotate a Vector3 by a Quaternion
2018-06-30 22:00:16 +02:00
Ray
d0166c9d45 Spacing tweaks 2018-06-30 21:56:26 +02:00
Ray
afe81d94ce Re-added: LoadFontEx() 2018-06-30 19:58:44 +02:00
Michael Campagnaro
859b1cf574 Fix incorrect log agent names 2018-06-28 18:41:32 -04:00
Ray
dbfd8d713f Reviewed comments section 2018-06-26 01:36:13 +02:00
Ray
bd957c7442
Merge pull request #557 from Martinfx/max-support-bsd-os
Added support OpenBSD, NetBSD, DragonFly OS
2018-06-24 12:44:58 +02:00
maficccc@gmail.com
59ebe1b7c3 Added support OpenBSD, NetBSD, DragonFly 2018-06-23 17:02:07 +02:00
maficccc@gmail.com
965cc8ab6f Added support DragonFly os from BSD family 2018-06-23 17:02:04 +02:00
Yuri
e1e036a602
Fisable glfw only when it is not found and not external. 2018-06-23 07:30:35 -07:00
Ray
0e135118fd Improved GenImageFontAtlas() 2018-06-21 00:18:13 +02:00
Ray
75ba5aca55 Improved font generation and SDF
Added: data to CharInfo struct
Added: LoadFontData()
Added: GenImageFontAtlas()
Removed: LoadFontEx()
Removed: LoadTTF() [internal]
Some code tweaks
2018-06-20 00:52:14 +02:00
Ray
372e4a1139 Reviewed some functions
- GetImageData()
- GetImageDataNormalized()
2018-06-12 16:30:03 +02:00
Ray San
64804f30e6 Comment review 2018-06-12 13:27:41 +02:00
Ray San
0c01c08718 Corrected issue, flag not supported...
...by emscripten glfw javascript implementation
2018-06-12 13:21:36 +02:00
Ray San
59fd261491 Added function: GetImageDataNormalized()
Reviewed: GetImageData()
Reviewed: ImageFormat()
2018-06-12 13:13:09 +02:00
Ray San
7d0e09ff4c Corrected bug 2018-06-12 12:05:28 +02:00
Ray San
b588af5ce2 Corrected breaking build 2018-06-12 10:45:00 +02:00
raysan5
b48d225a43 Propose new function: GenImageFont() 2018-06-10 19:29:01 +02:00
Ray
817ae07505 Some comments cleaning
ImageDraw() code tweak
2018-06-06 00:43:52 +02:00
Ray
0e6458cfee Added ImageRotate*() functions 2018-06-03 21:05:01 +02:00
Ray
61a1c59472 Corrected possible issue with CMake for GLFW 2018-06-02 18:47:19 +02:00
Ray
9688c677de Review window creation hints 2018-06-02 18:26:57 +02:00
Ray
c7d6a44e33 Update GLFW to latest dev version (master branch) 2018-06-02 18:26:29 +02:00
Ray
b1b4a11bdb Corrected issue with function definition 2018-06-02 13:05:23 +02:00
Ray
afc4181752 Work on ImageResizeCanvas() 2018-06-02 12:47:05 +02:00
Ray
2536bea379 Added: ImageResizeCanvas() -WIP-
Added note idea on ImageFormat() for future redesign (to support
16bit-32bit pixel-formats)
2018-06-01 00:53:40 +02:00
Ray
129c890a28 Removed assert()
Not used in raylib this mechanism
2018-05-30 00:06:23 +02:00
Ray
8f4b53384c Replaced tabs by spaces 2018-05-29 09:09:40 +02:00
Ray
d873314c27 Reviewed Windows resource file name 2018-05-29 00:52:08 +02:00
Ray
0148432588 fabsf() not working with TCC
Replaced by fabs() that seem to work ok
2018-05-28 00:48:45 +02:00
Ray
dbff40944a Corrected issue with floats on TCC
It seems TCC was not casting correctly int values to float in some
specific situations
2018-05-28 00:48:07 +02:00
Ray
1f0cc57ec7 Corrected issue with compiler param
Added android_native_app_glue module to raylib compilation instead of
compiling it as static lib at apk generation.
2018-05-27 19:06:14 +02:00
Ray San
8f4fa5006b Added a note 2018-05-22 12:09:12 +02:00
Ray San
f454af08bb Review include (already included) 2018-05-22 12:08:58 +02:00
raysan5
559b9b8cc3 Corrected possible memory leak 2018-05-21 18:57:54 +02:00
raysan5
44181baf04 Working on Android APK building 2018-05-21 18:13:52 +02:00
David Reid
63cf43b729 Fix some warnings. 2018-05-21 20:46:22 +10:00
David Reid
647c08ef4c Fix a copy paste typo. 2018-05-21 20:39:42 +10:00
David Reid
f1b624d38b Update mini_al. 2018-05-21 20:39:19 +10:00
David Reid
6d8cc250bd Merge branch 'master' of https://github.com/raysan5/raylib into dr/mini_al 2018-05-21 20:26:28 +10:00
Ahmad Fatoum
e025e62445 cmake: Fix PLATFORM_WEB build
Did this ever work? Surely, doesn't look like it...
2018-05-21 12:15:39 +02:00
Ahmad Fatoum
ad8509732c
CMake: Fix (Add?) Android support
Not sure if this ever worked, but now it at least compiles.
2018-05-21 01:08:29 +02:00
Ahmad Fatoum
ff55af14f9
CMake: Move reusable code to new cmake/ directory 2018-05-21 01:08:29 +02:00
Ahmad Fatoum
ae26e083b4
CMake: Add default build type if none specified
Release, unless we are in a Git repo, then it's Debug.
2018-05-21 01:08:28 +02:00
Ahmad Fatoum
20ddc6a2bb
Move utils.cmake to separate cmake/ directory 2018-05-21 01:08:28 +02:00
raysan5
a752092055 Removed 32bit arm Android library
From 2019 64bit support will be mandatory to publish an Android app.
Google plans to require that new apps target Oreo (API level 26) in
August of 2018.
2018-05-20 19:13:10 +02:00
raysan5
8e0cd51afb Support shared library building on Android 2018-05-20 18:49:58 +02:00
raysan5
ca69068814 Added function: rlCheckBufferLimit() 2018-05-20 01:55:46 +02:00
raysan5
3b70b66a08 Love OpenGL gotchas... make my life more enjoyable! 2018-05-20 00:41:12 +02:00
raysan5
24adca4ad0 Manual mipmap generation review
On OpenGL 1.1 only is supported for 32bit RGBA textures
2018-05-20 00:39:56 +02:00
raysan5
25d5e907ec Some code review (mainly comments) 2018-05-20 00:37:16 +02:00
Michael Vetter
5cfbb53f6c Increase API version
Please do this whenever necessary. And adapt it before releasing a new
RC. The RC should already have the correct one.
2018-05-18 16:04:18 +02:00
Ray
fb4265f646 Reviewed Android pipeline
Now defaults to Clang, ARM64 and API 21
2018-05-17 00:59:53 +02:00
Ray
0b05169aa7 Some warnings review 2018-05-17 00:58:58 +02:00
Ray
88c2337225 Preliminary support for MP3 fileformat -WIP- 2018-05-17 00:04:58 +02:00
Ray
2aae62cea2 Header tweak and comments 2018-05-17 00:04:36 +02:00
Ray
1d3e4ef437 Corrected issue on file extension check 2018-05-17 00:04:12 +02:00
Ray
bb43755a9d
Corrected issue on LoadASTC() 2018-05-12 23:33:03 +02:00
Ahmad Fatoum
eed170f852
CMake: Fix typo... s/USE_PIC/WITH_PIC/ 2018-05-12 19:05:30 +02:00
Ahmad Fatoum
0f1aaa474a
CMake: (Properly) build glfw separately with CMake
This reverts commit 2d6fb5c628,
and adds a fix for Alien::raylib's test failures.

The tests failed because the resulting static library didn't reexport
GLFW symbols. As a fix, we now have GLFW create a CMake "object library"
target that we can link with both the static and shared raylib.

This is arguably ugly... Proper fix would probably be a GLFW upstream
object library target.

Closes #536.
2018-05-12 18:38:20 +02:00
Ahmad Fatoum
2d6fb5c628
Revert "CMake: Build glfw separately with CMake"
This reverts commit 0adb4b67de,
because it failed tests for Alien::raylib:
http://www.cpantesters.org/distro/A/Alien-raylib.html
2018-05-11 23:43:35 +02:00
Ray
aa76985c0d Review raylib version to 2.0
Review raylib_icon resource
2018-05-11 18:14:19 +02:00
Ahmad Fatoum
0adb4b67de
CMake: Build glfw separately with CMake
Makes it easier to support Wayland later on.
2018-05-11 01:24:27 +02:00
Ahmad Fatoum
0df501be91
Add GLFW source tree to src/external
We need the CMake stuff for wayland configuration.
Otherwise, we would have to replicate that ourselves.
This is the full 7ef34eb06de54dd9186d3d21a401b2ef819b59e7 tree except
for tests/ examples/ and docs/
2018-05-10 23:07:26 +02:00
Ahmad Fatoum
b8ca51fd01
CMake: Don't create symlinks on unsupporting file systems (#539)
Panders to the idiosyncrasies of my work flow:
I have my raylib build directory mounted as a VirtualBox vboxfs for use
with my Linux VM, but vboxfs doesn't support symlinks, while raylib shared
library versioning on Unix expects symlinks to work.
If this happens, library versioning is now disabled on Unix with
an error message instead of just failing the build.
2018-05-10 21:03:43 +02:00
Ray
f26a38a9e1 Merge branch 'master' of https://github.com/raysan5/raylib 2018-05-09 00:24:08 +02:00
Ray
9ea2a69bfd Corrected issue on rectangle drawing 2018-05-09 00:23:56 +02:00
Ray
3a803ac95e
Removed unnecesary define 2018-05-08 23:04:13 +02:00
Sherjil Ozair
8e9ff75f1c Use fabsf for floats, and avoid implicit type casting 2018-05-06 12:47:46 -04:00
Ray
f14492432d Avoid exposing native GLFW3 functionality
Try to avoid types conflict with Font
2018-05-04 23:03:56 +02:00
Ray San
ec33e7d705 BREAKING CHANGE: Renamed SpriteFont type to Font
- Preparing MP3 files support
- Jumped version to raylib 2.0-dev (too many breaking changes...)
2018-05-04 16:59:48 +02:00
Ray San
6045062a05 Renamed some functions
- Renamed Begin3dMode() --> BeginMode3D()
- Renamed Begin2dMode() --> BeginMode2D()
- Renamed End3dMode() --> EndMode3D()
- Renamed End2dMode() --> EndMode2D()
2018-05-04 16:54:05 +02:00
Ray San
6324697ffd Rectangle parameters changed to float
- Some examples tweaks
- Reviewed ImageFormat()
- Use float for text fontSize
2018-05-04 16:25:31 +02:00
Ray San
9d103b7c2f Removed line breaks from functions
Useful to parse raylib.h to generate raylib-lua and Notepad++
intellisense XML info
2018-05-03 19:19:35 +02:00
raysan5
198d739256 BREAKING CHANGE: Renamed Camera -> Camera3D
Just added a fallback in the meantime...
2018-05-01 12:31:03 +02:00
raysan5
400c345f96 Added tangent computation alternative method
As stated in the note, I'm not sure if math is right, just followed a
reference implementation...
2018-04-30 11:21:44 +02:00
raysan5
23e335d933 Implemented MeshTangents()
- Added Vector3OrthoNormalize() to raymath.h - not sure if it is correct
- Implemented MeshBinormals() - Mesh struct has not a place for them...
- Updated model_material_pbr example - tested but not working on my GPU
(old Intel HD), actually, it never worked on it...
2018-04-30 02:47:48 +02:00
raysan5
c51203ae7e Corrected alpha blending on ImageDraw() 2018-04-29 18:39:57 +02:00
raysan5
dff1028466 Replaced ColorToFloat() by ColorNormalize() 2018-04-29 18:39:46 +02:00
raysan5
8d81b6e4e4 Support shapes drawing using only QUADS
Also added new compilation FLAGS for that pourpose
2018-04-29 12:53:32 +02:00
raysan5
ada6668b24 Expose file-dropping functions symbols 2018-04-29 11:49:10 +02:00
raysan5
ca5f7ebd10 Added compile flag: SUPPORT_SCREEN_CAPTURE
Allow compiling the library with support for automatic screen capture
(KEY_F12)
2018-04-29 11:37:39 +02:00
David Reid
3ca5047c82 Update mini_al. 2018-04-22 07:24:18 +10:00
David Reid
af4d23aa82 Update mini_al. 2018-04-21 22:13:02 +10:00
David Reid
24cab8f920 Update mini_al. 2018-04-21 20:39:31 +10:00
David Reid
0febaa2446 Update external audio libraries. 2018-04-21 18:57:00 +10:00
Ray
847bdaf682 Implemented default mesh
In case mesh loading fails, a cube is generated instead!
2018-04-19 20:20:34 +02:00
Ray
76a6bf6c52 Review spacing for cosistency 2018-04-19 20:19:53 +02:00
lumaio teon
5ef6cc1fb9
Add more key definitions 2018-04-13 17:14:04 -04:00
Ahmad Fatoum
3f59bdfc76
mini_al: Use WinAPI interlocked ops with tcc
Seems tcc doesn't provide __sync_*. See #435.
2018-04-11 11:29:49 +02:00
Ahmad Fatoum
8b0fef6c34
raymath: Workaround tcc inline function limitation
Reported in #435, tcc generates out-of-line definitions for inline
symbols, something it shouldn't.  This fix punishes tcc for that
by making applications it compiles (slightly) larger...
2018-04-11 10:43:27 +02:00
Ray San
4cc12ef2b3 Review camera definition on examples 2018-04-11 10:13:00 +02:00
Ray San
cc3b8645df Updated release version 2018-04-10 10:37:48 +02:00
Ray
8e44f7b3c7 Reviewed config.h formatting
Added raylib version to config
2018-04-09 23:01:20 +02:00
Ray
54e24d905a Init frame timming measure variables 2018-04-09 22:28:41 +02:00
Ray
cd616258c6
Merge pull request #522 from a3f/master
Refactor all #define SUPPORT_* into a config.h
2018-04-08 22:46:44 +02:00
Ray
9e7dedf5af
Merge pull request #521 from TheLumaio/master
Added GetCollisionRayModel
2018-04-08 22:28:19 +02:00
Ahmad Fatoum
1dbce35247
CMake: Generate config.h from CMakeOptions.txt
I would have liked config.h to be selected by include dir configuration,
but this way is less intrusive.
2018-04-07 23:39:53 +02:00
Ahmad Fatoum
1841afad11
Refactor all #define SUPPORT_* into a config.h
That way, a user needs only to touch a single file to configure what
features raylib is built with.
Include guards are left out intentionally, because config.h should only
be included in source files, not headers.

Later on, config.h can also define the raylib version (#461).
2018-04-07 23:37:48 +02:00
Ahmad Fatoum
d88523f03a
Split CMake options into separate CMakeOptions.txt 2018-04-07 22:41:43 +02:00
Milan Nikolic
3caa044bf2 Add GNUInstallDirs and USE_AUDIO/USE_WAYLAND options to CMake (#518) 2018-04-07 16:32:14 +02:00
lumaio teon
d2cc5b88df
Removed useless GetCollisionRayMesh and libraylib.a 2018-04-07 03:49:56 -04:00
lumaio teon
d003c23ecf
Added GetCollisionRayModel 2018-04-06 12:04:09 -04:00
Ray
b8bd1d2ea6 Remove unnecesary NPOT check
Now PLATFORM checks only used on core and utils modules
2018-04-05 19:22:45 +02:00
Ray
005f2ffb75 Simplified some code 2018-04-05 19:18:44 +02:00
Ray
931b672c92 Added: ImageDrawRectangle()
Renamed SaveImageAs() to ExportImage() for consistency on what actually happens with data.
2018-04-04 12:02:20 +02:00
Ray
6edf15b9f9 Added funtion: ExportMesh() 2018-04-04 12:00:54 +02:00
Ray
9393d1d76f Merge branch 'master' of https://github.com/raysan5/raylib 2018-04-03 12:43:42 +02:00
Ray San
fe1c04d1b8 Removed old code 2018-04-03 12:42:28 +02:00
Ray
533780aadf Review ImageDraw() alpha blending
Not sure if math is ok... just left a commented piece of code that uses pre-multiplied alpha.
2018-04-03 12:42:22 +02:00
Ray
3e0de31424
Merge pull request #504 from Martinfx/master
Fix potential bugs from static analysis
2018-04-02 18:10:38 +02:00
raysan5
375adf86a6 Review math usage to reduce temp variables 2018-04-02 15:16:45 +02:00
raysan5
bbdf9f4880 Review InitWindow() to avoid void pointer
Reviewed for PLATFORM_ANDROID and PLATFORM_UWP
2018-04-02 14:49:01 +02:00
maficccc@gmail.com
201007e426 Fix sscanf() without field limits can crash with huge input data 2018-04-02 13:30:20 +02:00
maficccc@gmail.com
db98dba10f Fix Allocator sizeof operand mismatch 2018-04-02 13:30:20 +02:00
maficccc@gmail.com
03ca9508bf Fix Dead initialization 2018-04-02 13:30:20 +02:00
maficccc@gmail.com
44eedf235d Redundant assignment of 'angle' to itself 2018-04-02 13:30:20 +02:00
maficccc@gmail.com
ca9e652f8b Remove dead assignment 2018-04-02 13:30:19 +02:00
Martinfx
28a9a181cb Fix use after free 2018-04-02 13:30:19 +02:00
maficccc@gmail.com
e659336c11 Fix value stored to 'num_channels' is never read 2018-04-02 13:30:19 +02:00
Ray
e72b96ada1
Merge pull request #508 from a3f/master
Allow use of main instead of android_main
2018-04-02 10:48:02 +02:00
Ray
564baa22d6
Merge pull request #513 from autious/master
Add orthographic 3d rendering mode
2018-04-01 00:27:20 +02:00
Jacques Heunis
b4e2f5b45c Initialize the timer after the graphics device on desktop and web platforms. (#516)
This is already the order that is used for Android. It doesn't appear to
make a difference on desktop but on web using the timer before it's been
initialized (by glfwInit, inside InitGraphicsDevice) causes the a long
(and variable but often several seconds) sleep between the first and
second frame.

Fixes: 468309d ("Early-exit InitWindow if InitGraphicsDevice fails")
2018-03-31 12:22:44 +02:00
Max Danielsson
6c049fdd76 Move deduplicate aspect variable in begin render.
Changes motivated by commentary in pull request 513
2018-03-27 19:59:54 +02:00
Max Danielsson
5ecee69088 Add 3d orthographic projection mode 2018-03-25 18:33:19 +02:00
David Reid
a8e2c7de9c
Fix an infinite loop in ALSA backend of mini_al. 2018-03-20 18:39:21 +10:00
Ray
deffad1701 Review tabs issue when compiling...
...PLATFORM_ANDROID on Windows, using MinGW-w64 (x86) provided Make (GCC
7.2)
2018-03-19 23:49:14 +01:00
David Reid
4a69c2d75e
Fix a buffer overflow in the OSS/BSD backend. 2018-03-18 14:37:41 +10:00
Ahmad Fatoum
2c219fb814
Allow use of main instead of android_main
Inspired by #504.
Instead of requiring the user to do PLATFORM_ANDROID #ifdefery,
have the android_main entry point exported by raylib and call
the user-defined main. This way many games could (in theory)
run unmodified on Android and elsewhere.

This is untested!
2018-03-16 21:37:22 +01:00
Ray
61e0e4b4f3 Complete review of raymath for API consistency 2018-03-16 13:47:01 +01:00
Ray San
9318dc98ce Support case-insensitive extension check 2018-03-16 13:09:49 +01:00
Ray
487bc613fd Updated raylib dev version 2018-03-15 12:37:52 +01:00
Ray
9d8f15c19d Reviewed raymath changes 2018-03-15 12:37:23 +01:00
Ray
6c6d6776c0
Merge pull request #482 from a3f/master
raymath.h: Use C99 inline semantics
2018-03-15 12:27:40 +01:00
Ray
8bc2813b0c
Merge pull request #500 from victorfisac/fork/master
[fork/master] Fixed some memory leaks and add null checks for consistency
2018-03-11 10:51:15 +01:00
raysan5
a0127d8300 Corrected typo 2018-03-11 10:49:51 +01:00
raysan5
fd5e457bb4 Correct issue with triangleCount 2018-03-11 10:41:49 +01:00
victorfisac
d6fee9da29 Fixed compilation code comment in header 2018-03-10 19:30:25 +01:00
victorfisac
3201bad65a Fixed memory leaks in physics step operations 2018-03-10 19:25:17 +01:00
Ray San
df50eada53 Added new functions
- SetWindowSize() to scale Windows in runtime
- SetMouseScale() to scale mouse input, useful when rendering game to a
RenderTexture2D that will be scaled to Window size (used on rFXGen tool)
2018-03-09 11:43:53 +01:00
raysan5
85850a955a Removed additional code
GLFW has been updated to latest version, probably this code is not
required any more due to already been integrated into library... but it
needs to be tested...
2018-03-03 16:01:24 +01:00
raysan5
3b4a64f2d6 Updated GLFW library to latest version 2018-03-03 15:58:44 +01:00
Ray
fd2adbe62d Renamed CalculateBoundingBox() to MeshBoundingBox()
Renamed function for consistency with a possible Mesh manipulation functions (maybe added in a future). Naming follows Image*() manipulation functions.
2018-02-26 12:10:45 +01:00
Ray
a7207dc6d4 Removed tangents generation
It has no sense to be inside LoadOBJ(), mesh processing moved to own functions: MeshTangents() and MeshBinormals(). Not exposed to user yet.
2018-02-26 12:02:05 +01:00
Ahmad Fatoum
3f48ffb1b6
Fix two memory leaks in jar_xm.h
Found by LeakSanitizer in #494.
2018-02-26 00:14:19 +01:00
RDR8
18f61948ce Update Makefile
$ make clean
Makefile:296: *** missing separator.  Stop.
2018-02-25 22:27:32 +01:00
Ahmad Fatoum
80bf636f81
Don't exceed signed int range when shifting left
Fixes UB in #489, found by UBSan.
2018-02-25 03:17:57 +01:00
Ahmad Fatoum
76aca9b0d1
Fix possible buffer overflow in LoadBMFont
Width specifier doesn't include NUL terminator.
Fixes #487 found by AddressSanitizer.
2018-02-25 03:03:37 +01:00
Ahmad Fatoum
1430d01906
jar_xm: Workaround for unaligned pointer accesses
jar_xm.h does some shady pointer casts leading to unaligned accesses
and breaking strict aliasing. x86 has special circuitry for doing
unaligned accesses, but on other architectures, it may trap and require
kernel fix-up or crash outright. With this patch, one obstacle in
porting raylib to the GameBoy Advance has been removed. Go for it ;-)

To avoid having to rewrite that `mempool' code, insert padding before
structs and instruct the compiler (GCC, most importantly), to be gentle
when optimizing.

This fixes #490 (Unless we got ourselves 256-bit pointers, if so,
hello future!)
2018-02-24 23:59:56 +01:00
Ahmad Fatoum
f52d2de582
raymath.h: Use C99 inline semantics
RAYMATH_EXTERN_INLINE was renamed to RAYMATH_HEADER_ONLY, which user code
may define if they want to use it as header-only library. If multiple
files in the same project define RAYMATH_HEADER_ONLY, they might each
have duplicate out-of-line definitions of the same functions.

By default, raymath.h exposes inline definitions, which instructs the
compiler _not_ to generate out-of-line definitons, if out-of-line
definitions are required, those of the file defined with
RAYLIB_IMPLEMENTATION are used instead. There may be only one such file.

In C++ mode, the compiler will select only one out-of-line definition
automatically, so no need to define a RAYLIB_IMPLEMENTATION.

Unfortunately, we have to remove raymath function declaration from
raylib.h as those declarations would lead to duplicate out-of-line
definitions which would yield linker errors. This problem didn't
exist with GNU89 or C++, because there multiple defintions are ok,
but in C99 they aren't.
2018-02-24 23:39:23 +01:00
Ahmad Fatoum
ed6962edd3
Make MatrixToFloat and Vector3ToFloat reentrant
Besides making it thread-safe, it suppresses a GCC warning
when making them static inline in an upcoming patch.
2018-02-24 23:39:17 +01:00
RDR8
2b5fc12036 Update Makefiles. Enable example usage of staged libraylib.so. 2018-02-24 14:24:55 -06:00
Ahmad Fatoum
a5881fb9cc
Revert "raymath.h: Use C99 inline semantics"
This reverts commit 6ffc8cb799.
and commit e4d7bbec1e.
which I pushed by mistake...
2018-02-24 15:40:08 +01:00
Ahmad Fatoum
c9043b5a87
CMake: Add options to use -fsanitize={address,undefined}
To make bugs like #485, #486, #487 and #488 easier to find in future.
2018-02-24 15:37:38 +01:00
Ahmad Fatoum
6ffc8cb799
raymath.h: Use C99 inline semantics
RAYMATH_EXTERN_INLINE was renamed to RAYMATH_HEADER_ONLY, which user code
may define if they want to use it as header-only library. If multiple
files in the same project define RAYMATH_HEADER_ONLY, they might each
have duplicate out-of-line definitions of the same functions.

By default, raymath.h exposes inline definitions, which instructs the
compiler _not_ to generate out-of-line definitons, if out-of-line
definitions are required, those of the file defined with
RAYLIB_IMPLEMENTATION are used instead. There may be only one such file.

In C++ mode, the compiler will select only one out-of-line definition
automatically, so no need to define a RAYLIB_IMPLEMENTATION.

Unfortunately, we have to remove raymath function declaration from
raylib.h as those declarations would lead to duplicate out-of-line
definitions which would yield linker errors. This problem didn't
exist with GNU89 or C++, because there multiple defintions are ok,
but in C99 they aren't.
2018-02-24 15:37:37 +01:00
Ahmad Fatoum
e4d7bbec1e
Make MatrixToFloat and Vector3ToFloat reentrant
Besides making it thread-safe, it suppresses a GCC warning
when making them static inline in an upcoming patch.
2018-02-24 15:37:37 +01:00
Ray
077bef4286 Support 4 components mesh.tangent data
Added struct Vector4 for convenience
2018-02-24 12:31:32 +01:00
Ray
6d64327a87 Reviewed unloading model data
When UnloadModel() --> UnloadMaterial(), avoid unloading default shader (if used) and avoid unlaoding default texture (if used), that data is managed by raylib internally. The question is... should UnloadModel() also UnloadMaterial()?
2018-02-22 12:39:17 +01:00
Ray
cd5e2e0f17 Corrected cursor issue for Wayland 2018-02-22 00:01:13 +01:00
Ray
326fe09777 Reviewed compilation for OpenGL 1.1 2018-02-21 23:47:48 +01:00
Ray
97bf2706c4 Removed flag -fgnu89-inline 2018-02-21 23:28:34 +01:00
Ray
11612fce27 Reviewed timming system for macOS
Apparently, before macOS Sierra version, clock_gettime was not available, using MATCH timming system instead
2018-02-20 10:30:51 +01:00
raysan5
0958904eac Added comments to review function ImageTextEx() 2018-02-18 19:29:13 +01:00
raysan5
4492a70a4b Support UTF8 basic characters on ImageTextEx()
Supported UTF8 range equivalent to [128..255] (80h..FFh)
Exposed and renamed text function GetGlyphIndex()
Renamed spriteFont parameter name to simply font
Small security check on transmission mission ending screen
2018-02-18 18:07:57 +01:00
Ahmad Fatoum
051040af2d
CMake: Remove _RAYLIB suffix from -D{SHARED,STATIC}_RAYLIB
They were named so for compatibility with make, but make doesn't use
the anymore. I always forget whether it's SHARED_RAYLIB or
RAYLIB_SHARED...

For now, RAYLIB_SHARED and STATIC_RAYLIB may still be used,
but print a deprecation warning.
2018-02-16 05:58:18 +01:00
Ray
36750ffb9a BREAKING CHANGE: Renamed function for consistency
Rename: GetHexValue() renamed to ColorToInt()
Added: ColorToHSV()
2018-02-12 11:55:22 +01:00
Ray
8af5f9dfe0 Avoid rendering SPACE character! 2018-02-12 11:25:00 +01:00
RDR8
f742f1289d
Update Makefile 2018-02-12 05:17:02 +00:00
RDR8
5616314069
Update Makefile 2018-02-12 00:15:58 +00:00
RDR8
4c4b564392
Update Makefiles for Linux installation. See prior commit.
These changes are intended to provide context and control over the Linux make install process. make install RAYLIB_LIBTYPE=SHARED now works as expected. libraylib.so is properly installed with attendant runtime links. The examples will be running against the newly installed libraylib.so unless otherwise specified with RAYLIB_RUNTIME_PATH. See raylib/src/Makefile and raylib/examples/Makefile for usage of RAYLIB_INSTALL_PATH, RAYLIB_H_INSTALL_PATH, and RAYLIB_RUNTIME_PATH variables. RAYLIB_RUNTIME_PATH in particular is interesting for portability since sudo isn't needed.
The default configuration and workflow is essentially unchanged and unaffected.
2018-02-11 23:42:22 +00:00
RDR8
e86b4d4e03 Update Makefiles for Linux installation. 2018-02-11 22:58:15 +00:00
Ahmad Fatoum
1be72a2e72
pkg-config: Empty Requires.private on shared-only build
If user doesn't build the static library,
`pkg-config --static --libs raylib` should be equivalent to
`pkg-config --libs raylib`.
2018-02-11 20:10:50 +01:00
Ahmad Fatoum
09b022305f mini_al: Support {Net,Open}BSD OSS
Fixes this build failure:
http://www.cpantesters.org/cpan/report/a069fade-0e1f-11e8-a1cf-bb670eaac09d
2018-02-11 12:20:17 +01:00
Ray
d90a33b850 Some reviews for Android compilation 2018-02-11 01:48:53 +01:00
Ray
231a69417a Corrected masteVolume setting 2018-02-11 01:28:30 +01:00
Ray
7bf6becc94 Reviewed mini_al implementation
- Some functions renamed
- Comments reviewed
- Functions reorganized
2018-02-11 01:12:16 +01:00
Ahmad Fatoum
468309d06c
Early-exit InitWindow if InitGraphicsDevice fails
Otherwise we may run into LoadDefaultFont and crash in rlLoadTexture
Also moves InitTimer() before InitGraphicsDevice(), to allow it to be
tested even if InitWindow ultimately fails.
2018-02-09 22:54:35 +01:00
Ray
f72b315cb6 Updated external libraries 2018-02-09 00:01:00 +01:00
Ahmad Fatoum
a976e76ae6
InitWindow: return false if no monitor found
Otherwise we run into an assertion failure inside GLFW's glfwGetVideoMode.
Example:
http://www.cpantesters.org/cpan/report/b4ba5894-0bdb-11e8-841e-2c60b04e1d2d

This is related to #456.
2018-02-08 12:06:21 +01:00
Ray
4d5d1e0434 Added function LoadShaderCode()
Allows loading of shader from text code string directly
2018-02-05 01:03:13 +01:00
raysan5
5437458469 Merge branch 'develop' of https://github.com/raysan5/raylib into develop 2018-02-04 13:46:45 +01:00
raysan5
3a11cc5e31 Incremeted version to align with CMake 2018-02-04 13:44:41 +01:00
Ahmad Fatoum
19f280f4b7
Bump version to 1.9.4 2018-02-04 13:36:08 +01:00
raysan5
6dc2f979cc Updated raylib version
Note that this version is under development and could be buggy on some
platforms...
2018-02-04 12:33:46 +01:00
raysan5
c32ed921a2 Security check in case window initialization fails 2018-02-04 12:31:16 +01:00
raysan5
70e0070a85 Reviewed window initialization
In case graphic device could not be created it returns false instead of
failing with an error tracelog (and consequently closing the program).
Window initialization success could be checked with new function
IsWindowReady()
2018-02-04 12:26:28 +01:00
Ahmad Fatoum
26c9176a14
Return false from InitWindow if glfwInit or glfwCreateWindow fails
You can't do much with raylib if glfwInit or glfwCreateWindow fails,
currently it just exits by means of TraceLog(LOG_ERROR.
User code, however, might want to fall back to a text-only UI
or display a warning if raylib can't be used.
2018-02-03 14:53:58 +01:00
Ahmad Fatoum
44cd4faf83
exit(3), don't crash, when glfwCreateWindow fails
glfwSetWindowPos was called on a NULL window, triggering an assert
inside GLFW. Check for failure and exit cleanly by means of
TraceLog(LOG_ERROR instead.
2018-02-03 14:46:26 +01:00
Ahmad Fatoum
7f5fa4d49c
CMake: Add tristate option for using system GLFW (#455)
-DWITH_SYSTEM_GLFW=ON: Link against system glfw and fail otherwise
-DWITH_SYSTEM_GLFW=OFF: Use embedded rglfw.c
-DWITH_SYSTEM_GLFW=IF_POSSIBLE: Probe for system glfw but fallback to
                                rglfw if unavailable

Also change Linux 64-bit CI build to install system glfw and use it,
so this doesn't bitrot.

Addresses #453.
2018-02-03 10:17:51 +01:00
Ahmad Fatoum
007ae1b7b3
CMake: Fix typo in MACOS_FATLIB 2018-02-03 09:38:57 +01:00
Ray San
d1ef6869a9 Added function DrawRectangleLinesEx() 2018-02-02 11:01:38 +01:00
Ray
58346414f7 Corrected typo 2018-01-31 15:32:40 +01:00
Ray
44c95af463 Added missing keys definitions 2018-01-31 14:08:08 +01:00
Ray
1ce8c80de9 Corrected several issues... 2018-01-28 16:52:18 +01:00
Ahmad Fatoum
f955b2255d
GLFW: Fix build error on Linux < v2.6.39
Cherry-pick from upstream glfw/glfw#1196
Found in CPANtesters test of Alien::raylib:
http://www.cpantesters.org/cpan/report/d956d128-0339-11e8-b0d1-b6c4abd39192
2018-01-27 14:53:04 +01:00
Ahmad Fatoum
7f7aac643a
CMake: Search dependencies and build pkg-config's Libs.private with it 2018-01-27 01:57:21 +01:00
Ahmad Fatoum
1093766669
CMake: remove OpenAL dependency 2018-01-27 01:05:17 +01:00
Ray
1d5fbef93d Clear fbo for drawing
Just in case ClearBackground() is not used after BeginTextureMode(), it clears fbo to color defined by previous ClearBackground()
2018-01-26 11:49:00 +01:00
Ahmad Fatoum
520f317a75
#include header for time() on Windows 2018-01-25 23:12:03 +01:00
Ahmad Fatoum
03ee03e2a6
#include header for glInsertEventMarkerEXT on macOS 2018-01-25 23:00:07 +01:00
Ahmad Fatoum
8be93762d9
Make function calls without prior declaration an error
which is the default behavior on C99 and up.
2018-01-25 22:34:29 +01:00
Ray
c2ec88f930 Support DEBUG library building 2018-01-25 10:07:51 +01:00
Ray
2dcaddc81c Review mipmaps generation issue
When changing image format, mipmaps are lost and regenerated from
scratch
2018-01-23 13:23:34 +01:00
Ray
04af83ff99 Improved pixel formats support
Review rlLoadTexture() function to make it simpler, now OpenGL texture
glInternalFormat, glFormat and glType are retrieved with new function
GetGlFormats()
2018-01-22 00:20:42 +01:00
Ray
8e0a277f7c Reviewed UWP branch integration 2018-01-19 12:02:15 +01:00
Ray
750323da53
Merge branch 'develop' into testing_uwp 2018-01-19 11:41:51 +01:00
Ahmad Fatoum
30ef3f3122
GCC/Clang: Treat void pointer arithmetic as error
As an extension, GNU C treats sizeof(void) as 1. MSVC doesn't.
Make it an error on GCC/Clang to avoid accidental MSVC breakage.
2018-01-18 13:22:41 +01:00
Ahmad Fatoum
a2edc9d641
MSVC: Fix void pointer arithmetic error
GNU C allows it as a compiler extension, but MSVC doesn't.
2018-01-18 13:20:13 +01:00
Ray
ce9f191f1b Added function: ImageMipmaps() 2018-01-18 00:23:45 +01:00
Ray
727cb1819b Reviewed VS2015 projects
- Support OpenGL 1.1 if selected macro
- Corrected MSVC compiler issues with (void *) data
- Removed raylib.dll project
- Created DEBUG_DLL and RELEASE_DLL configurations
2018-01-17 14:21:23 +01:00
Ray
c8e97df233 Reviewed function GenImagePerlinNoise()
Added support for noise image offset
2018-01-17 00:43:30 +01:00
Ray
dd3b3dbadb Redesigned rlLoadTexture()
- Added support for mipmap levels loading
- Removed internal function LoadTextureCompressed(), not required any
more...
2018-01-16 00:00:05 +01:00
-
230e78a23e Code tweak while using OpenAL backend 2018-01-15 13:54:25 +01:00
-
f2a675ae53 Reviewed Makefiles...
- Renamed VERSION to RAYLIB_VERSION
- Renamed API_VERSION to RAYLIB_API_VERSION
- Renamed RAYLIB_RELEASE to RAYLIB_RELEASE_PATH
- Support Web Assembly compilation on PLATFORM_WEB
2018-01-15 13:54:06 +01:00
Ray
278d8575bd Added new function: ImageAlphaCrop() 2018-01-11 10:22:32 +01:00
Ray
c37d2d448d Corrected issue with matrices
Matrix stack system should be reviewed but, in the meantime,
currentMatrix should be reseted in order of 3d to work
2018-01-08 01:03:04 +01:00
Ray
fcb0cae605 Use busy wait loop
If not using busy wait loop, linkage with WINMM in Windows platform is
required
2018-01-07 23:55:23 +01:00
Ray
4dcc02ff1e Launch draw call if buffer limits reached
Note that this solution is a temporal patch, not properly tested and
prone to fail, specially if matrix are pushed into the stack...
2018-01-07 23:54:11 +01:00
raysan5
e4be917d1b Added new image functions
- Added: ImageAlphaClear()
- Added: ImageAlphaPremultiply()
- Reorganized some functions
2018-01-07 00:51:26 +01:00
raysan5
b97134c3e1 Review float pixel format textures support 2018-01-06 18:17:38 +01:00
raysan5
7caa3201d5 Improved pixel formats support
- Renamed enum TextureFormat to PixelFormat for consistency
- Added support for pixel format UNCOMPRESSED_R32
- Using GetPixelDataSize() where required
2018-01-06 13:43:48 +01:00
raysan5
1f0f8c33fa Added function declaration 2018-01-06 02:51:28 +01:00
raysan5
7fa2861160 Added function: GetPixelDataSize()
Just found I need that function...
2018-01-06 02:50:20 +01:00
raysan5
0e48396369 Corrected issue with new functionality
Using default font texture as base white texture for rectangles reduces
draw calls considerably, actually, raygui can be drawn with a single
pass!
2018-01-06 02:44:47 +01:00
raysan5
b760f16f9b Reviewed framebuffers cleaning
Issues when dealing with FBOs
2018-01-06 02:43:38 +01:00
raysan5
1a82e1ab26 Added function GetFileName()
Review comments
2018-01-02 02:26:05 +01:00
raysan5
e1baae0249 Removed function DrawRectangleT()
Functionality integrated in DrawRectangle() and selectable with config
flag USE_DEFAULT_FONT_TEXTURE
2018-01-01 16:54:32 +01:00
raysan5
e69424c86f Reviewed text input 2017-12-31 23:50:22 +01:00
raysan5
e7cf03b1e4 Minor tweaks 2017-12-28 19:27:02 +01:00
raysan5
7965f983ba Support Wayland display on Linux desktop 2017-12-28 18:14:39 +01:00
raysan5
b19e155b34 Support UNCOMPRESSED_R32G32B32A32 texture format 2017-12-28 17:58:37 +01:00
raysan5
c93bca8c27 Review Makefile config flags
Support external GLFW usage
Renamed some flags for consistency
2017-12-28 17:58:09 +01:00
raysan5
0bd06eec51 Renamed function to SetTraceLog()
I think is clearer this way...
2017-12-24 16:49:54 +01:00
raysan5
e517d8fd16 Added function SetTraceLogTypes()
Trace log messages could be configured with this function to select wich
ones are shown
2017-12-24 16:47:33 +01:00
raysan5
e574428343 Some formatting tweaks 2017-12-24 16:12:52 +01:00
raysan5
f44dbf21cf Review physac timming system 2017-12-24 15:59:03 +01:00
Martinfx
9b7a24331d Added next bsd os 2017-12-23 18:12:19 +01:00
Ray San
00c34a035c Updated copyright year 2017-12-20 12:37:08 +01:00
Ray San
27c274bc3c Corrected issue with SaveImageAs()
That function depends on SavePNG() and forces platform check on textures
module, that behaviour should be changed, platform definition should be
only required on core module...
2017-12-20 12:36:47 +01:00
Ray San
e8bb53ed35 Corrected issue on OpenGL ES compilation 2017-12-20 12:35:12 +01:00
Ray San
61afd07bd7 Force OpenAL backend on some platforms
OpenAL audio backend is being forced on HTML5 and OSX
2017-12-20 12:34:18 +01:00
Ray San
1320044e94 Review code formatting 2017-12-20 11:37:43 +01:00
Ray
b63ffcfa0f Some code tweaks
Audio module requires a complete formatting review....
2017-12-20 00:34:31 +01:00
Ray San
5290390494 Expose GetTime() function to users
Monotonic time since InitWindow() could be retrieved with this function.
2017-12-19 14:06:54 +01:00
Ray
bc6ae93a48 Added some comments on GetTime()
Reviewing GetTime() functionality
2017-12-18 00:06:57 +01:00
Ray San
b155333178 Support audio module skip on compiling
Some programs like tools could not require audio support
2017-12-15 17:02:29 +01:00
Ray San
e17a9a8216 Updated mini_al to latest version 2017-12-15 17:01:50 +01:00
Ray San
53ad53d051 Manually review previous PR 2017-12-15 13:44:31 +01:00
user
2affac820e make raylib not clash with windows-header 2017-12-14 11:52:45 +01:00
user
217917530b fix for eventmarker missed in first cl 2017-12-14 11:51:17 +01:00
user
48d0c93ace make GetTime available to user of library 2017-12-14 11:50:35 +01:00
user
b872de951b fix for GetMatrixModelview (former cl) 2017-12-14 11:49:31 +01:00
user
d51f382ef8 optimized matrixrotate function by removing identity matrix 2017-12-14 11:48:33 +01:00
user
b5395b22cc make raymath compiling with msvc in c++ mode 2017-12-14 11:47:52 +01:00
user
07b522c113 make matrix stack work closer to old opengl implementation 2017-12-14 11:46:38 +01:00
user
a7f2fedbfb compilefix for function declaration (win only) 2017-12-14 11:45:47 +01:00
user
0e18b14605 added debug-event-markers for opengl so that you're able to set markers for renderdoc or other gpu debuggers what your program is currently doing 2017-12-14 11:44:48 +01:00
user
963551ee6e added possibility to get modelview matrix from rlgl to be able to send it to shaders 2017-12-14 11:43:06 +01:00
user
69c8fa409a fixed function declaration differ from implementation 2017-12-14 11:42:06 +01:00
user
54587d7fdb proper if-clauses for disabling functionality in text.c 2017-12-14 11:41:31 +01:00
user
08fc886afd added proper define checks for png-save if it's disabled 2017-12-14 11:40:08 +01:00
Ray
2388cbc3cd Corrected crash on shader loading
If shader file could not be found on loading it crashed, instead added
fallback to default shader!
2017-12-13 20:10:13 +01:00
Ray
a6f9cc5629 Remove rres support
Let the user choose if using rres external library
2017-12-11 11:55:02 +01:00
Ahmad Fatoum
4a7840b752
Remove Meson build system
Less maintenance overhead that way,
given that make/CMake now also do library versioning.
2017-12-11 11:15:14 +01:00
Ahmad Fatoum
d24b89bb0e
Add library versioning to Make/CMake build systems
See #401 for the discussion.
Also bumps version number to 1.9.2 without the -dev,
because neither ELF nor MachO like such a suffix.
The -dev suffix will have to be restricted to the git tags.
2017-12-11 10:25:06 +01:00
Ahmad Fatoum
de78fa69bc Fix CI builds after mini_al changes 2017-12-10 21:35:38 +01:00
Ahmad Fatoum
203b2f65d1
Fix typo in preprocessor macro 2017-12-10 21:11:04 +01:00
raysan5
5ae2c0d15b Added Wayland support
Updated to latest GLFW library and working on Wayland support, still
looking how to implement it on raylib because it just exposes
PLATFORM_DESKTOP and defaults to X11 windowing system on Linux...
2017-12-09 19:05:42 +01:00
Ray San
3b5a26099e Removed OpenAL Soft dependency on building
OpenAL Soft backend is still available in audio module, I'm thinking if
exposing it for building in some way or just left it there for advance
users to switch to it manually in case of necessity...
2017-12-05 14:01:35 +01:00
Ray San
33eec31575 Updated external libraries dependencies
Added dr_wav for a future use
2017-12-05 13:23:04 +01:00
Ray San
acbfba9250 Updated library features and dependencies 2017-12-05 13:22:26 +01:00
Ray
9d0ee6c2f6
Merge pull request #413 from mackron/dr/mini_al
mini_al integration
2017-12-05 11:23:16 +01:00
David Reid
104391f82b Update mini_al. 2017-12-05 18:49:00 +10:00
Ray
54d0acc3b6 Change version number for develop
Updated raylib version to 1.9-dev for development pourposes.

Next raylib version is planned to implement a big amount of changes, so
the version bump.
2017-12-05 00:05:05 +01:00
Ray San
0cd327ccb2 Moved QuaternionNlerp() function 2017-12-04 11:03:45 +01:00
David Reid
82f88e5df9 Potential fixes for Raspberry Pi. 2017-12-03 11:20:02 +10:00
Ray San
25a232a6f3 Merge branch 'develop' of https://github.com/raysan5/raylib into develop 2017-11-30 16:59:13 +01:00
Ray San
9a7524661f Removed GLFW3 linking and added rglfw 2017-11-30 16:59:09 +01:00
Martinfx
825d15b069 Fixed broken include for AppVeyor 2017-11-29 17:06:40 +01:00
Martinfx
69a1c19735 Fixed use ${LIBS_PRIVATE} for FreeBSD 2017-11-29 13:17:02 +01:00
Martinfx
2f471414c2 Added compile with cmake for FreeBSD 2017-11-29 00:05:39 +01:00
Martinfx
2cf37708c0 Added glfw support for FreeBSD 2017-11-29 00:04:29 +01:00
Ray San
c9722161d1 Support GetCurrentTime() on macOS 2017-11-27 12:46:40 +01:00
Ahmad Fatoum
f991a075e1 Build examples and games on Travis CI
They were disabled because they failed to build,
but this patch set fixes the build on Linux and macOS.

This doesn't apply to the AppVeyor build on Windows yet;
it currently fails at linking with OpenAL.
2017-11-25 21:45:31 +01:00
raysan5
853cc6f4c9 Added authorization token 2017-11-25 19:40:05 +01:00
Ahmad Fatoum
49c5a433df
Setup CMake package target and CI auto-deploy tags
cmake --build . --target package # or make package if make is used

can now be used to create binary packages for raylib.

AppVeyor and Travis CI are configured to push the artifacts
that result from building git tags to the related Github releases page.
2017-11-24 21:24:35 +01:00
Ahmad Fatoum
44376c04fa
Generate and install pkg-config pc file
After installation, compiling new programs is possible with
    $ cc game.c `pkg-config --static --libs --cflags raylib`
or
    $ cc game.c `pkg-config --libs --cflags raylib`
depending on configuration

Also adds following configuration options:
- WITH_PIC "Compile static library as position-independent code"
- STATIC_RAYLIB "Build raylib as a static library"
- MACOS_FATLIB  "Build fat library for both i386 and x86_64 on macOS"
2017-11-24 17:15:33 +01:00
David Reid
a0d9913c7c Potential fixes for audio on RPI and Emscripten builds. 2017-11-24 22:13:33 +10:00
David Reid
5463e14886 Audio: Fix a bug with AudioStreams.
This bug is a result of the buffer of an AudioStream being smaller than
that of a period of the backend playback device. In this situation,
AudioStream's would have pauses between buffer updates because the
backend is not able to re-fill the AudioStream buffer's quick enough
due to it's periods being longer than the AudioStream buffer.
2017-11-24 21:54:00 +10:00
Ahmad Fatoum
17c91bad6f
Disable CRT "secure" warnings
Suppresses 88 of the 213 warnings reported when compiling with
MSVC 2015 on AppVeyor.
2017-11-23 07:56:02 +01:00
Ahmad Fatoum
1e1b20c889
Add AppVeyor CI for automatic Windows Builds
We already have automatic Linux and macOS build via Travis CI.
This adds the same for Windows x86 and x86_64 with both
Microsoft Visual Studio 2015 as well as MinGW-w64.
2017-11-23 00:47:58 +01:00
Ahmad Fatoum
b2acff66de
Fix macOS build of new rglfw.c approach
There have been two problems:

* GLFW itself was compiled with the definitions for compiling
_against_ GLFW (fixed by removing requirement for external glfw)

* rglfw.c was being compiled as C code, although it includes
Objective C files.

This _might_ break the Windows build, needs to be checked.

Fixes #391, but as noted I'd prefer though a separate source directory
and build script for GLFW.
2017-11-22 23:11:41 +01:00
Ahmad Fatoum
899e1fbd94
Avoid duplicate definition of feature macro
Feature macros need to be defined before #including any headers,
preferably through the build system, but this is good enough.

Fixes a compile error on my fork's Travis CI.
2017-11-22 22:58:18 +01:00
Ray San
1be826fb16 Removed useless file 2017-11-22 17:30:09 +01:00
Ray
25ceec9b8f Corrected default textures locations
By default, we look for texture1 for LOC_MAP_SPECULAR and texture2 for
LOC_MAP_NORMAL
2017-11-22 14:56:45 +01:00
David Reid
8b3694a34d Fix a crash in audio mixing code. 2017-11-22 18:36:48 +10:00
David Reid
c71b01c8ac Update mini_al with fixes for OpenSL and SDL backends. 2017-11-21 06:35:38 +10:00
David Reid
14b889be41 Update mini_al with a potential fix for HTML5. 2017-11-20 21:47:07 +10:00
David Reid
3238cba47c Log the name of the playback device. 2017-11-19 19:38:23 +10:00
David Reid
49e945f958 Update mini_al with fixes and improvements for Emscripten. 2017-11-19 12:15:01 +10:00
David Reid
84ef860443 Update mini_al with experimental support for SDL/Emscripten. 2017-11-18 22:30:20 +10:00
David Reid
f9144ac5b0 Rename a variable for consistency. 2017-11-18 12:15:48 +10:00
David Reid
3be83dac7e Update mini_al. 2017-11-18 11:51:51 +10:00
David Reid
b9bb80d004 Add some logging and update mini_al. 2017-11-18 10:27:44 +10:00
David Reid
60d7215b2a mini_al: Unify the buffer system for Sounds and AudioStreams. 2017-11-18 08:42:14 +10:00
Ray San
6d317c7afe Remove glfw3 dependency
Full sources already included and compiled with raylib (rglfw)
2017-11-17 18:43:39 +01:00
Ray San
e2e4b8df28 Remove unneeded glfw dependencies
Only required by examples
2017-11-17 18:42:39 +01:00
Ray San
a6877c82c6 Added alternative license to rgif.h library
Just in case of legal conflict with public domain software, added MIT
alternative license.
2017-11-17 18:30:19 +01:00
David Reid
261b00e9e8 Update mini_al. 2017-11-17 21:12:05 +10:00
Ray San
a6416f82a7 Reviewed file comments 2017-11-16 17:59:35 +01:00
David Reid
96be62e88b Update mini_al.h 2017-11-16 21:49:45 +10:00
David Reid
e03afbf2fa Add support for pitch shifting.
This commit should bring the mini_al backend up to feature parity with
the OpenAL backend.
2017-11-15 22:04:23 +10:00
David Reid
322d868841 Fix minor errors with the OpenAL backend. 2017-11-14 21:44:57 +10:00
David Reid
88d2810fa3 Bug fixes for Music with mini_al. 2017-11-14 21:15:50 +10:00
Ray
68024f1b0b Added desktop platform check...
...to define proper values
2017-11-13 21:37:00 +01:00
David Reid
3a96a66fdf Bring up to date with changes to mini_al. 2017-11-13 21:46:29 +10:00
Ray San
9c65caea8c Added GLFW sources to raylib
Compiling GLFW library with raylib avoids external dependencies, this
way we solve version problems in some platforms
2017-11-13 12:09:41 +01:00
David Reid
e52f4282d6 Update comments. 2017-11-12 22:57:31 +10:00
David Reid
ac4c911ad7 Work on porting Music to mini_al. 2017-11-12 21:55:24 +10:00
David Reid
68bf6c9701 Initial work on porting AudioStream to use mini_al. 2017-11-12 20:59:16 +10:00
raysan5
24b12e5e23 Remove PLATFORM_ checks from raylib header
Now header is truly multiplatform...

Actually still a small pending check on XBOX gamepad controls that
hopefully will be removed with next GLFW 3.3
2017-11-12 11:45:35 +01:00
raysan5
02dd4d32b5 Allow custom distortion shader - IN PROGRESS - 2017-11-12 11:00:28 +01:00
raysan5
09228752ce Review default shaders usage on loading 2017-11-12 10:33:44 +01:00
David Reid
b0852002b8 Rename SoundInternal to SoundData for consistency with MusicData. 2017-11-12 14:54:37 +10:00