Browse Source

Merge pull request #7 from raysan5/master

pull
pull/675/head
Murray Campbell 6 years ago
committed by GitHub
parent
commit
03fb5499a0
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
114 changed files with 1874 additions and 1321 deletions
  1. +1
    -0
      .gitignore
  2. +0
    -1
      .travis.yml
  3. +18
    -16
      CONTRIBUTING.md
  4. +3
    -3
      LICENSE.md
  5. +1
    -1
      README.md
  6. +1
    -0
      examples/Makefile
  7. +90
    -0
      examples/core/core_multitouch.c
  8. BIN
      examples/core/core_multitouch.png
  9. +1
    -2
      examples/models/models_yaw_pitch_roll.c
  10. +3
    -0
      examples/physac/physics_restitution.c
  11. BIN
      examples/shapes/shapes_colors_palette.png
  12. BIN
      examples/text/resources/custom_alagard.png
  13. BIN
      examples/text/resources/custom_jupiter_crash.png
  14. BIN
      examples/text/resources/custom_mecha.png
  15. BIN
      examples/text/resources/fonts/alagard.png
  16. BIN
      examples/text/resources/fonts/alpha_beta.png
  17. BIN
      examples/text/resources/fonts/jupiter_crash.png
  18. BIN
      examples/text/resources/fonts/mecha.png
  19. BIN
      examples/text/resources/fonts/pixantiqua.png
  20. BIN
      examples/text/resources/fonts/pixelplay.png
  21. BIN
      examples/text/resources/fonts/romulus.png
  22. BIN
      examples/text/resources/fonts/setback.png
  23. BIN
      examples/textures/resources/custom_jupiter_crash.png
  24. BIN
      examples/textures/resources/scarfy.png
  25. BIN
      games/drturtle/resources/fish.png
  26. BIN
      games/drturtle/resources/gamera.png
  27. BIN
      games/drturtle/resources/gframe.png
  28. BIN
      games/drturtle/resources/komika.png
  29. BIN
      games/drturtle/resources/mountains.png
  30. BIN
      games/drturtle/resources/orca.png
  31. BIN
      games/drturtle/resources/sea.png
  32. BIN
      games/drturtle/resources/shark.png
  33. BIN
      games/drturtle/resources/sky.png
  34. BIN
      games/drturtle/resources/swhale.png
  35. BIN
      games/drturtle/resources/title.png
  36. BIN
      games/drturtle/resources/turtle.png
  37. +1
    -1
      games/just_do/screens/screen_level06.c
  38. +1
    -1
      games/koala_seasons/screens/screen_gameplay.c
  39. BIN
      games/light_my_ritual/resources/font_arcadian.png
  40. BIN
      games/light_my_ritual/resources/textures/back_title.png
  41. BIN
      games/light_my_ritual/resources/textures/background.png
  42. BIN
      games/light_my_ritual/resources/textures/circle_level_i_off.png
  43. BIN
      games/light_my_ritual/resources/textures/circle_level_i_on.png
  44. BIN
      games/light_my_ritual/resources/textures/circle_level_ii_off.png
  45. BIN
      games/light_my_ritual/resources/textures/circle_level_ii_on.png
  46. BIN
      games/light_my_ritual/resources/textures/circle_level_iii_off.png
  47. BIN
      games/light_my_ritual/resources/textures/circle_level_iii_on.png
  48. BIN
      games/light_my_ritual/resources/textures/enemy.png
  49. BIN
      games/light_my_ritual/resources/textures/foreground_level_i.png
  50. BIN
      games/light_my_ritual/resources/textures/foreground_level_ii.png
  51. BIN
      games/light_my_ritual/resources/textures/foreground_level_iii.png
  52. BIN
      games/light_my_ritual/resources/textures/light.png
  53. BIN
      games/light_my_ritual/resources/textures/light_glow.png
  54. BIN
      games/light_my_ritual/resources/textures/light_ray.png
  55. BIN
      games/light_my_ritual/resources/textures/msg_ritual.png
  56. BIN
      games/light_my_ritual/resources/textures/player.png
  57. BIN
      games/light_my_ritual/resources/textures/time_over.png
  58. BIN
      games/light_my_ritual/resources/textures/title.png
  59. BIN
      games/skully_escape/resources/textures/background_aisle01.png
  60. BIN
      games/skully_escape/resources/textures/doors.png
  61. BIN
      games/skully_escape/resources/textures/monster_chair_left.png
  62. BIN
      games/skully_escape/resources/textures/monster_chair_right.png
  63. BIN
      games/skully_escape/resources/textures/monster_lamp_left.png
  64. BIN
      games/skully_escape/resources/textures/monster_lamp_right.png
  65. BIN
      games/skully_escape/resources/textures/monster_picture.png
  66. BIN
      games/skully_escape/resources/textures/monster_window.png
  67. BIN
      games/skully_escape/resources/textures/skully.png
  68. BIN
      games/transmission/resources/textures/ending_background.png
  69. BIN
      games/transmission/resources/textures/message_background.png
  70. BIN
      games/transmission/resources/textures/message_vignette.png
  71. BIN
      games/transmission/resources/textures/mission_background.png
  72. BIN
      games/transmission/resources/textures/mission_backline.png
  73. BIN
      games/transmission/resources/textures/title_background.png
  74. BIN
      games/transmission/resources/textures/title_ribbon.png
  75. BIN
      games/transmission/resources/textures/words_base.png
  76. +6
    -4
      games/transmission/screens/screen_ending.c
  77. BIN
      games/wave_collector/resources/textures/background.png
  78. BIN
      games/wave_collector/resources/textures/background_gameplay.png
  79. BIN
      games/wave_collector/resources/textures/background_title.png
  80. BIN
      games/wave_collector/resources/textures/icon_synchro.png
  81. BIN
      games/wave_collector/resources/textures/icon_warp.png
  82. BIN
      games/wave_collector/resources/textures/lose.png
  83. BIN
      games/wave_collector/resources/textures/player.png
  84. BIN
      games/wave_collector/resources/textures/sample_big.png
  85. BIN
      games/wave_collector/resources/textures/sample_small.png
  86. BIN
      games/wave_collector/resources/textures/win.png
  87. BIN
      logo/raylib.ico
  88. BIN
      logo/raylib_180x180.png
  89. BIN
      logo/raylib_36x36.png
  90. BIN
      logo/raylib_512x512.png
  91. BIN
      logo/raylib_72x72.png
  92. BIN
      logo/raylib_96x96.png
  93. +4
    -4
      projects/VS2017/examples/core_basic_window.vcxproj
  94. +4
    -4
      projects/VS2017/examples/core_basic_window_cpp.vcxproj
  95. BIN
      raylib.rc.o
  96. +9
    -8
      src/CMakeLists.txt
  97. +8
    -5
      src/CMakeOptions.txt
  98. +2
    -24
      src/Makefile
  99. +36
    -626
      src/audio.c
  100. +1
    -1
      src/config.h

+ 1
- 0
.gitignore View File

@ -33,6 +33,7 @@ Thumbs.db
[Bb]in
[Dd]ebug/
[Dd]ebug.win32/
[Dd]ebug.DLL/
*.sbr
*.sdf
obj/

+ 0
- 1
.travis.yml View File

@ -120,7 +120,6 @@ script:
-DBUILD_EXAMPLES=ON -DBUILD_GAMES=ON
-DUSE_EXTERNAL_GLFW=$USE_EXTERNAL_GLFW
-DUSE_WAYLAND=$WAYLAND
-DUSE_OPENAL_BACKEND=$OPENAL
-DINCLUDE_EVERYTHING=ON
..
- $RUNNER make VERBOSE=1

+ 18
- 16
CONTRIBUTING.md View File

@ -59,21 +59,23 @@ To open new issue for raylib (bug, enhancement, discussion...), just try to foll
Some people ported raylib to other languages in form of bindings or wrappers to the library, here is a list with the ones I'm aware of:
- [raylib C/C++ version (default)](https://github.com/raysan5/raylib)
- [raylib Lua binding](https://github.com/raysan5/raylib-lua)
- [raylib Go binding](https://github.com/gen2brain/raylib-go)
- [raylib Nim binding](https://gitlab.com/define-private-public/raylib-Nim)
- [raylib Crystal binding](https://gitlab.com/Zatherz/cray)
- [raylib Perl wrapper](https://metacpan.org/pod/Graphics::Raylib)
- [raylib Pascal binding](https://github.com/drezgames/raylib-pascal)
- [raylib flat-assembler Usage example](http://forum.raylib.com/index.php?p=/discussion/comment/425/#Comment_425)
- [raylib COBOL Usage example](https://github.com/Martinfx/Cobol/tree/master/OpenCobol/Games/raylib)
- [raylib C# binding](https://github.com/ChrisDill/Raylib-cs)
- [raylib C# binding](https://github.com/TheLumaio/RaylibSharp)
- [raylib Ruby binding](https://github.com/D3nX/raylib-ruby-ffi)
- [raylib Rust binding](https://github.com/deltaphc/raylib-rs)
- [raylib Python binding](https://github.com/overdev/raylibpy)
- [raylib Haskell binding](https://github.com/DevJac/raylib-haskell)
- [raylib](https://github.com/raysan5/raylib) : raylib **C/C++** version (default)
- [raylib-lua](https://github.com/raysan5/raylib-lua) : raylib **Lua** binding
- [raylib-go](https://github.com/gen2brain/raylib-go) : raylib **Go** binding
- [raylib-Nim](https://gitlab.com/define-private-public/raylib-Nim) : raylib **Nim** binding
- [cray](https://gitlab.com/Zatherz/cray) - raylib **Crystal** binding
- [Graphics::Raylib](https://metacpan.org/pod/Graphics::Raylib) : raylib **Perl** wrapper
- [raylib-pascal](https://github.com/drezgames/raylib-pascal) - raylib **Pascal** binding
- [Raylib-cs](https://github.com/ChrisDill/Raylib-cs) : raylib **C#** binding
- [RaylibSharp](https://github.com/TheLumaio/RaylibSharp) : raylib **C#** binding
- [raylib-ruby-ffi](https://github.com/D3nX/raylib-ruby-ffi) : raylib **Ruby** binding
- [raylib-rs](https://github.com/deltaphc/raylib-rs) : raylib **Rust** binding
- [raylib-rust](https://github.com/dtcristo/raylib-rust) : raylib **Rust** binding
- [raylib-py](https://github.com/overdev/raylib-py) : raylib **Python** binding
- [raylib-haskell](https://github.com/DevJac/raylib-haskell) : raylib **Haskell** binding
- [raylib-java]() : raylib **Java** binding
- *[raylib flat-assembler Usage example](http://forum.raylib.com/index.php?p=/discussion/comment/425/#Comment_425)*
- *[raylib COBOL Usage example](https://github.com/Martinfx/Cobol/tree/master/OpenCobol/Games/raylib)*
Usually, raylib bindings follow the convention: `raylib-{language}`
@ -85,7 +87,7 @@ provide the icon/logo for that new language binding.
If you have any doubt, don't hesitate to [contact me](mailto:ray@raylib.com)!.
You can write me a direct mail but you can also contact me on the following networks:
- [raylib forum](http://forum.raylib.com/) - A good place for discussions or to ask for help.
- [raylib reddit](https://www.reddit.com/r/raylib/) - A good place for discussions or to ask for help.
- [raylib Discord](https://discord.gg/VkzNHUE) - A direct communication channel for project discussions.
- [raylib twitter](https://twitter.com/raysan5) - My personal twitter account, I usually post about raylib, you can send me PMs.
- [raylib web](http://www.raylib.com/) - On top-right corner there is a bunch of networks where you can find me.

+ 3
- 3
LICENSE.md View File

@ -7,7 +7,7 @@ source code
raylib is licensed under an unmodified zlib/libpng license, which is an OSI-certified,
BSD-like license that allows static linking with closed source software:
Copyright (c) 2013-2016 Ramon Santamaria (@raysan5)
Copyright (c) 2013-2019 Ramon Santamaria (@raysan5)
This software is provided "as-is", without any express or implied warranty. In no event
will the authors be held liable for any damages arising from the use of this software.
@ -41,9 +41,9 @@ The following fonts [provided with raylib](https://github.com/raysan5/raylib/tre
2d art
------
[scarfy spritesheet](https://github.com/raysan5/raylib/blob/master/examples/textures/resources/scarfy.png) and [fudesumi image](https://github.com/raysan5/raylib/blob/master/examples/textures/resources/fudesumi.png) have been created by [Eiden Marsal](https://www.artstation.com/artist/marshall_z) and licensed as [Creative Commons Attribution-NonCommercial 3.0](https://creativecommons.org/licenses/by-nc/3.0/legalcode)
[scarfy spritesheet](https://github.com/raysan5/raylib/blob/master/examples/textures/resources/scarfy.png) and [fudesumi image](https://github.com/raysan5/raylib/blob/master/examples/textures/resources/fudesumi.png) have been created by [Eiden Marsal](https://www.artstation.com/artist/marshall_z) and are licensed as [Creative Commons Attribution-NonCommercial 3.0](https://creativecommons.org/licenses/by-nc/3.0/legalcode)
3d models
---------
[medieval city 3d models and textures](https://github.com/raysan5/raylib/tree/master/examples/models/resources/medieval) have been created by Alberto Cano and licensed as [Creative Commons Attribution-NonCommercial 4.0](https://creativecommons.org/licenses/by-nc/4.0/legalcode)
[medieval city 3d models and textures](https://github.com/raysan5/raylib/tree/master/examples/models/resources/medieval) have been created by Alberto Cano and are licensed as [Creative Commons Attribution-NonCommercial 4.0](https://creativecommons.org/licenses/by-nc/4.0/legalcode)

+ 1
- 1
README.md View File

@ -31,7 +31,7 @@ features
- **Powerful math module** for Vector, Matrix and Quaternion operations: [raymath](https://github.com/raysan5/raylib/blob/master/src/raymath.h)
- Audio loading and playing with streaming support (WAV, OGG, MP3, FLAC, XM, MOD)
- **VR stereo rendering** support with configurable HMD device parameters
- Bindings to **Lua** ([raylib-lua](https://github.com/raysan5/raylib-lua)), **Go** ([raylib-go](https://github.com/gen2brain/raylib-go)) and more!
- Bindings to **Lua** ([raylib-lua](https://github.com/raysan5/raylib-lua)), **Go** ([raylib-go](https://github.com/gen2brain/raylib-go)) and [more](https://github.com/raysan5/raylib/blob/master/CONTRIBUTING.md#raylib-bindings)!
raylib uses on its [core](https://github.com/raysan5/raylib/blob/master/src/core.c) module the outstanding [GLFW3](http://www.glfw.org/) library, embedded inside raylib in the form of [rglfw](https://github.com/raysan5/raylib/blob/master/src/rglfw.c) module, avoiding that way external dependencies.

+ 1
- 0
examples/Makefile View File

@ -375,6 +375,7 @@ EXAMPLES = \
core/core_2d_camera \
core/core_world_screen \
core/core_vr_simulator \
core/core_multitouch \
shapes/shapes_logo_raylib \
shapes/shapes_basic_shapes \
shapes/shapes_colors_palette \

+ 90
- 0
examples/core/core_multitouch.c View File

@ -0,0 +1,90 @@
/*******************************************************************************************
*
* raylib [core] example - Multitouch input
*
* This example has been created using raylib 2.1 (www.raylib.com)
* raylib is licensed under an unmodified zlib/libpng license (View raylib.h for details)
*
* Copyright (c) 2014 Ramon Santamaria (@raysan5)
* Example by Berni
*
********************************************************************************************/
#include "raylib.h"
#include <stdio.h>
int main()
{
// Initialization
//--------------------------------------------------------------------------------------
int screenWidth = 800;
int screenHeight = 450;
InitWindow(screenWidth, screenHeight, "raylib [core] example - multitouch input");
Vector2 ballPosition = { -100.0f, -100.0f };
Color ballColor;
int PressedCounter = 0;
Vector2 TouchPos;
char Str[16];
SetTargetFPS(60);
//---------------------------------------------------------------------------------------
// Main game loop
while (!WindowShouldClose()) // Detect window close button or ESC key
{
// Update
//----------------------------------------------------------------------------------
ballPosition = GetMousePosition();
ballColor = BEIGE;
if (IsMouseButtonDown(MOUSE_LEFT_BUTTON)) ballColor = MAROON;
if (IsMouseButtonDown(MOUSE_MIDDLE_BUTTON)) ballColor = LIME;
if (IsMouseButtonDown(MOUSE_RIGHT_BUTTON)) ballColor = DARKBLUE;
if (IsMouseButtonPressed(MOUSE_LEFT_BUTTON)) PressedCounter = 10;
if (IsMouseButtonPressed(MOUSE_MIDDLE_BUTTON)) PressedCounter = 10;
if (IsMouseButtonPressed(MOUSE_RIGHT_BUTTON)) PressedCounter = 10;
if(PressedCounter > 0)
PressedCounter--;
//----------------------------------------------------------------------------------
// Draw
//----------------------------------------------------------------------------------
BeginDrawing();
ClearBackground(RAYWHITE);
// Multitouch
for (int i = 0; i < MAX_TOUCH_POINTS; ++i)
{
TouchPos = GetTouchPosition(i); // Get the touch point
if( (TouchPos.x >= 0) && (TouchPos.y >= 0) ) // Make sure point is not (-1,-1) as this means there is no touch for it
{
DrawCircleV(TouchPos, 34, ORANGE); // Draw a circle there
sprintf(Str,"%d",i);
DrawText(Str, TouchPos.x - 10, TouchPos.y - 70, 40, BLACK); // Also show its index number
}
}
// Draw the normal mouse location
DrawCircleV(ballPosition, 30 + (PressedCounter * 3), ballColor);
DrawText("move ball with mouse and click mouse button to change color", 10, 10, 20, DARKGRAY);
DrawText("touch the screen at multiple locations to get multiple balls", 10, 30, 20, DARKGRAY);
EndDrawing();
//----------------------------------------------------------------------------------
}
// De-Initialization
//--------------------------------------------------------------------------------------
CloseWindow(); // Close window and OpenGL context
//--------------------------------------------------------------------------------------
return 0;
}

BIN
examples/core/core_multitouch.png View File

Before After
Width: 800  |  Height: 450  |  Size: 17 KiB

+ 1
- 2
examples/models/models_yaw_pitch_roll.c View File

@ -5,8 +5,7 @@
* This example has been created using raylib 1.8 (www.raylib.com)
* raylib is licensed under an unmodified zlib/libpng license (View raylib.h for details)
*
* Example based on Berni work on Raspberry Pi:
* http://forum.raylib.com/index.php?p=/discussion/124/line-versus-triangle-drawing-order
* Example based on Berni work on Raspberry Pi.
*
* Copyright (c) 2017 Ramon Santamaria (@raysan5)
*

+ 3
- 0
examples/physac/physics_restitution.c View File

@ -51,6 +51,9 @@ int main()
circleC->restitution = 1;
SetTargetFPS(60);
// Restitution demo needs a very tiny physics time step for a proper simulation
SetPhysicsTimeStep(1.0/60.0/100 * 1000);
//--------------------------------------------------------------------------------------
// Main game loop

BIN
examples/shapes/shapes_colors_palette.png View File

Before After
Width: 800  |  Height: 450  |  Size: 5.1 KiB Width: 800  |  Height: 450  |  Size: 6.4 KiB

BIN
examples/text/resources/custom_alagard.png View File

Before After
Width: 512  |  Height: 284  |  Size: 37 KiB Width: 512  |  Height: 284  |  Size: 44 KiB

BIN
examples/text/resources/custom_jupiter_crash.png View File

Before After
Width: 426  |  Height: 284  |  Size: 23 KiB Width: 426  |  Height: 284  |  Size: 28 KiB

BIN
examples/text/resources/custom_mecha.png View File

Before After
Width: 446  |  Height: 284  |  Size: 26 KiB Width: 446  |  Height: 284  |  Size: 32 KiB

BIN
examples/text/resources/fonts/alagard.png View File

Before After
Width: 128  |  Height: 128  |  Size: 4.3 KiB Width: 128  |  Height: 128  |  Size: 3.5 KiB

BIN
examples/text/resources/fonts/alpha_beta.png View File

Before After
Width: 128  |  Height: 128  |  Size: 2.4 KiB Width: 128  |  Height: 128  |  Size: 2.4 KiB

BIN
examples/text/resources/fonts/jupiter_crash.png View File

Before After
Width: 128  |  Height: 128  |  Size: 3.4 KiB Width: 128  |  Height: 128  |  Size: 2.9 KiB

BIN
examples/text/resources/fonts/mecha.png View File

Before After
Width: 128  |  Height: 128  |  Size: 2.3 KiB Width: 128  |  Height: 128  |  Size: 2.3 KiB

BIN
examples/text/resources/fonts/pixantiqua.png View File

Before After
Width: 128  |  Height: 128  |  Size: 2.9 KiB Width: 128  |  Height: 128  |  Size: 2.7 KiB

BIN
examples/text/resources/fonts/pixelplay.png View File

Before After
Width: 128  |  Height: 128  |  Size: 2.8 KiB Width: 128  |  Height: 128  |  Size: 2.8 KiB

BIN
examples/text/resources/fonts/romulus.png View File

Before After
Width: 128  |  Height: 128  |  Size: 2.9 KiB Width: 128  |  Height: 128  |  Size: 2.6 KiB

BIN
examples/text/resources/fonts/setback.png View File

Before After
Width: 128  |  Height: 128  |  Size: 2.5 KiB Width: 128  |  Height: 128  |  Size: 2.5 KiB

BIN
examples/textures/resources/custom_jupiter_crash.png View File

Before After
Width: 426  |  Height: 284  |  Size: 23 KiB Width: 426  |  Height: 284  |  Size: 28 KiB

BIN
examples/textures/resources/scarfy.png View File

Before After
Width: 768  |  Height: 128  |  Size: 32 KiB Width: 768  |  Height: 128  |  Size: 10 KiB

BIN
games/drturtle/resources/fish.png View File

Before After
Width: 128  |  Height: 128  |  Size: 25 KiB Width: 128  |  Height: 128  |  Size: 12 KiB

BIN
games/drturtle/resources/gamera.png View File

Before After
Width: 256  |  Height: 192  |  Size: 75 KiB Width: 256  |  Height: 192  |  Size: 79 KiB

BIN
games/drturtle/resources/gframe.png View File

Before After
Width: 1280  |  Height: 720  |  Size: 905 KiB Width: 1280  |  Height: 720  |  Size: 1.4 MiB

BIN
games/drturtle/resources/komika.png View File

Before After
Width: 522  |  Height: 320  |  Size: 63 KiB Width: 522  |  Height: 320  |  Size: 70 KiB

BIN
games/drturtle/resources/mountains.png View File

Before After
Width: 1280  |  Height: 107  |  Size: 193 KiB Width: 1280  |  Height: 107  |  Size: 232 KiB

BIN
games/drturtle/resources/orca.png View File

Before After
Width: 256  |  Height: 128  |  Size: 42 KiB Width: 256  |  Height: 128  |  Size: 31 KiB

BIN
games/drturtle/resources/sea.png View File

Before After
Width: 1280  |  Height: 720  |  Size: 584 KiB Width: 1280  |  Height: 720  |  Size: 744 KiB

BIN
games/drturtle/resources/shark.png View File

Before After
Width: 256  |  Height: 128  |  Size: 38 KiB Width: 256  |  Height: 128  |  Size: 31 KiB

BIN
games/drturtle/resources/sky.png View File

Before After
Width: 1280  |  Height: 80  |  Size: 118 KiB Width: 1280  |  Height: 80  |  Size: 132 KiB

BIN
games/drturtle/resources/swhale.png View File

Before After
Width: 256  |  Height: 128  |  Size: 54 KiB Width: 256  |  Height: 128  |  Size: 44 KiB

BIN
games/drturtle/resources/title.png View File

Before After
Width: 540  |  Height: 300  |  Size: 45 KiB Width: 540  |  Height: 300  |  Size: 40 KiB

BIN
games/drturtle/resources/turtle.png View File

Before After
Width: 128  |  Height: 128  |  Size: 25 KiB Width: 128  |  Height: 128  |  Size: 14 KiB

+ 1
- 1
games/just_do/screens/screen_level06.c View File

@ -132,7 +132,7 @@ void DrawLevel06Screen(void)
DrawRectangleRec(movingRecs[i], GRAY);
}
if (!done & (mouseOverNum >= 0)) DrawRectangleLines(movingRecs[mouseOverNum].x - 5, movingRecs[mouseOverNum].y - 5, movingRecs[mouseOverNum].width + 10, movingRecs[mouseOverNum].height + 10, Fade(LIGHTGRAY, 0.8f));
if (!done && (mouseOverNum >= 0)) DrawRectangleLines(movingRecs[mouseOverNum].x - 5, movingRecs[mouseOverNum].y - 5, movingRecs[mouseOverNum].width + 10, movingRecs[mouseOverNum].height + 10, Fade(LIGHTGRAY, 0.8f));
if (levelFinished)
{

+ 1
- 1
games/koala_seasons/screens/screen_gameplay.c View File

@ -954,7 +954,7 @@ void UpdateGameplayScreen(void)
playerActive = false;
killer = 5;
}
else if (CheckCollisionRecs(bee, player) && (state == FINALFORM) && (state != KICK))
else if (CheckCollisionRecs(bee, player) && (state == FINALFORM))
{
isHitBee = true;
beeVelocity = 8;

BIN
games/light_my_ritual/resources/font_arcadian.png View File

Before After
Width: 512  |  Height: 512  |  Size: 95 KiB Width: 512  |  Height: 512  |  Size: 96 KiB

BIN
games/light_my_ritual/resources/textures/back_title.png View File

Before After
Width: 512  |  Height: 720  |  Size: 179 KiB Width: 512  |  Height: 720  |  Size: 249 KiB

BIN
games/light_my_ritual/resources/textures/background.png View File

Before After
Width: 1280  |  Height: 720  |  Size: 1.2 MiB Width: 1280  |  Height: 720  |  Size: 1.4 MiB

BIN
games/light_my_ritual/resources/textures/circle_level_i_off.png View File

Before After
Width: 320  |  Height: 320  |  Size: 15 KiB Width: 320  |  Height: 320  |  Size: 16 KiB

BIN
games/light_my_ritual/resources/textures/circle_level_i_on.png View File

Before After
Width: 320  |  Height: 320  |  Size: 50 KiB Width: 320  |  Height: 320  |  Size: 49 KiB

BIN
games/light_my_ritual/resources/textures/circle_level_ii_off.png View File

Before After
Width: 512  |  Height: 512  |  Size: 27 KiB Width: 512  |  Height: 512  |  Size: 31 KiB

BIN
games/light_my_ritual/resources/textures/circle_level_ii_on.png View File

Before After
Width: 512  |  Height: 512  |  Size: 104 KiB Width: 512  |  Height: 512  |  Size: 106 KiB

BIN
games/light_my_ritual/resources/textures/circle_level_iii_off.png View File

Before After
Width: 720  |  Height: 720  |  Size: 37 KiB Width: 720  |  Height: 720  |  Size: 47 KiB

BIN
games/light_my_ritual/resources/textures/circle_level_iii_on.png View File

Before After
Width: 720  |  Height: 720  |  Size: 156 KiB Width: 720  |  Height: 720  |  Size: 159 KiB

BIN
games/light_my_ritual/resources/textures/enemy.png View File

Before After
Width: 64  |  Height: 64  |  Size: 2.7 KiB Width: 64  |  Height: 64  |  Size: 2.5 KiB

BIN
games/light_my_ritual/resources/textures/foreground_level_i.png View File

Before After
Width: 1280  |  Height: 720  |  Size: 28 KiB Width: 1280  |  Height: 720  |  Size: 56 KiB

BIN
games/light_my_ritual/resources/textures/foreground_level_ii.png View File

Before After
Width: 1280  |  Height: 720  |  Size: 35 KiB Width: 1280  |  Height: 720  |  Size: 78 KiB

BIN
games/light_my_ritual/resources/textures/foreground_level_iii.png View File

Before After
Width: 1280  |  Height: 720  |  Size: 41 KiB Width: 1280  |  Height: 720  |  Size: 100 KiB

BIN
games/light_my_ritual/resources/textures/light.png View File

Before After
Width: 448  |  Height: 64  |  Size: 2.2 KiB Width: 448  |  Height: 64  |  Size: 1.9 KiB

BIN
games/light_my_ritual/resources/textures/light_glow.png View File

Before After
Width: 160  |  Height: 160  |  Size: 8.5 KiB Width: 160  |  Height: 160  |  Size: 16 KiB

BIN
games/light_my_ritual/resources/textures/light_ray.png View File

Before After
Width: 228  |  Height: 512  |  Size: 8.6 KiB Width: 228  |  Height: 512  |  Size: 24 KiB

BIN
games/light_my_ritual/resources/textures/msg_ritual.png View File

Before After
Width: 720  |  Height: 196  |  Size: 111 KiB Width: 720  |  Height: 196  |  Size: 176 KiB

BIN
games/light_my_ritual/resources/textures/player.png View File

Before After
Width: 64  |  Height: 64  |  Size: 2.8 KiB Width: 64  |  Height: 64  |  Size: 2.3 KiB

BIN
games/light_my_ritual/resources/textures/time_over.png View File

Before After
Width: 770  |  Height: 160  |  Size: 113 KiB Width: 770  |  Height: 160  |  Size: 173 KiB

BIN
games/light_my_ritual/resources/textures/title.png View File

Before After
Width: 720  |  Height: 360  |  Size: 208 KiB Width: 720  |  Height: 360  |  Size: 328 KiB

BIN
games/skully_escape/resources/textures/background_aisle01.png View File

Before After
Width: 2048  |  Height: 720  |  Size: 655 KiB Width: 2048  |  Height: 720  |  Size: 660 KiB

BIN
games/skully_escape/resources/textures/doors.png View File

Before After
Width: 735  |  Height: 1130  |  Size: 81 KiB Width: 735  |  Height: 1130  |  Size: 89 KiB

BIN
games/skully_escape/resources/textures/monster_chair_left.png View File

Before After
Width: 680  |  Height: 225  |  Size: 42 KiB Width: 680  |  Height: 225  |  Size: 33 KiB

BIN
games/skully_escape/resources/textures/monster_chair_right.png View File

Before After
Width: 680  |  Height: 225  |  Size: 45 KiB Width: 680  |  Height: 225  |  Size: 32 KiB

BIN
games/skully_escape/resources/textures/monster_lamp_left.png View File

Before After
Width: 1240  |  Height: 380  |  Size: 78 KiB Width: 1240  |  Height: 380  |  Size: 64 KiB

BIN
games/skully_escape/resources/textures/monster_lamp_right.png View File

Before After
Width: 1240  |  Height: 380  |  Size: 145 KiB Width: 1240  |  Height: 380  |  Size: 146 KiB

BIN
games/skully_escape/resources/textures/monster_picture.png View File

Before After
Width: 1032  |  Height: 264  |  Size: 94 KiB Width: 1032  |  Height: 264  |  Size: 63 KiB

BIN
games/skully_escape/resources/textures/monster_window.png View File

Before After
Width: 1592  |  Height: 372  |  Size: 172 KiB Width: 1592  |  Height: 372  |  Size: 122 KiB

BIN
games/skully_escape/resources/textures/skully.png View File

Before After
Width: 700  |  Height: 1590  |  Size: 136 KiB Width: 700  |  Height: 1590  |  Size: 125 KiB

BIN
games/transmission/resources/textures/ending_background.png View File

Before After
Width: 1280  |  Height: 720  |  Size: 241 KiB Width: 1280  |  Height: 720  |  Size: 277 KiB

BIN
games/transmission/resources/textures/message_background.png View File

Before After
Width: 1280  |  Height: 720  |  Size: 1.1 MiB Width: 1280  |  Height: 720  |  Size: 1.4 MiB

BIN
games/transmission/resources/textures/message_vignette.png View File

Before After
Width: 640  |  Height: 360  |  Size: 157 KiB Width: 640  |  Height: 360  |  Size: 248 KiB

BIN
games/transmission/resources/textures/mission_background.png View File

Before After
Width: 1280  |  Height: 720  |  Size: 796 KiB Width: 1280  |  Height: 720  |  Size: 1.2 MiB

BIN
games/transmission/resources/textures/mission_backline.png View File

Before After
Width: 32  |  Height: 720  |  Size: 1.4 KiB Width: 32  |  Height: 720  |  Size: 1.7 KiB

BIN
games/transmission/resources/textures/title_background.png View File

Before After
Width: 1280  |  Height: 720  |  Size: 1009 KiB Width: 1280  |  Height: 720  |  Size: 1.5 MiB

BIN
games/transmission/resources/textures/title_ribbon.png View File

Before After
Width: 197  |  Height: 85  |  Size: 35 KiB Width: 197  |  Height: 85  |  Size: 26 KiB

BIN
games/transmission/resources/textures/words_base.png View File

Before After
Width: 140  |  Height: 35  |  Size: 7.7 KiB Width: 140  |  Height: 35  |  Size: 8.8 KiB

+ 6
- 4
games/transmission/screens/screen_ending.c View File

@ -110,10 +110,12 @@ void InitEndingScreen(void)
{
// WARNING: It fails if the last sentence word has a '.' after space
char *title = StringReplace(headline, messageWords[i].text, codingWords[messageWords[i].id]);
strcpy(headline, title); // Base headline updated
if (title != NULL) free(title);
if (title != NULL)
{
strcpy(headline, title); // Base headline updated
free(title);
}
}
}

BIN
games/wave_collector/resources/textures/background.png View File

Before After
Width: 1280  |  Height: 720  |  Size: 821 KiB Width: 1280  |  Height: 720  |  Size: 1.4 MiB

BIN
games/wave_collector/resources/textures/background_gameplay.png View File

Before After
Width: 1280  |  Height: 720  |  Size: 554 KiB Width: 1280  |  Height: 720  |  Size: 954 KiB

BIN
games/wave_collector/resources/textures/background_title.png View File

Before After
Width: 1280  |  Height: 720  |  Size: 593 KiB Width: 1280  |  Height: 720  |  Size: 1004 KiB

BIN
games/wave_collector/resources/textures/icon_synchro.png View File

Before After
Width: 96  |  Height: 96  |  Size: 9.8 KiB Width: 96  |  Height: 96  |  Size: 12 KiB

BIN
games/wave_collector/resources/textures/icon_warp.png View File

Before After
Width: 96  |  Height: 96  |  Size: 12 KiB Width: 96  |  Height: 96  |  Size: 14 KiB

BIN
games/wave_collector/resources/textures/lose.png View File

Before After
Width: 768  |  Height: 256  |  Size: 77 KiB Width: 768  |  Height: 256  |  Size: 102 KiB

BIN
games/wave_collector/resources/textures/player.png View File

Before After
Width: 64  |  Height: 96  |  Size: 12 KiB Width: 64  |  Height: 96  |  Size: 11 KiB

BIN
games/wave_collector/resources/textures/sample_big.png View File

Before After
Width: 64  |  Height: 64  |  Size: 2.9 KiB Width: 64  |  Height: 64  |  Size: 2.8 KiB

BIN
games/wave_collector/resources/textures/sample_small.png View File

Before After
Width: 32  |  Height: 32  |  Size: 1.8 KiB Width: 32  |  Height: 32  |  Size: 1.2 KiB

BIN
games/wave_collector/resources/textures/win.png View File

Before After
Width: 768  |  Height: 256  |  Size: 32 KiB Width: 768  |  Height: 256  |  Size: 35 KiB

BIN
logo/raylib.ico View File

Before After

BIN
logo/raylib_180x180.png View File

Before After
Width: 180  |  Height: 180  |  Size: 1.8 KiB

BIN
logo/raylib_36x36.png View File

Before After
Width: 36  |  Height: 36  |  Size: 1.0 KiB Width: 36  |  Height: 36  |  Size: 354 B

BIN
logo/raylib_512x512.png View File

Before After
Width: 512  |  Height: 512  |  Size: 2.3 KiB Width: 512  |  Height: 512  |  Size: 4.9 KiB

BIN
logo/raylib_72x72.png View File

Before After
Width: 72  |  Height: 72  |  Size: 1.9 KiB Width: 72  |  Height: 72  |  Size: 1.1 KiB

BIN
logo/raylib_96x96.png View File

Before After
Width: 96  |  Height: 96  |  Size: 1.1 KiB Width: 96  |  Height: 96  |  Size: 749 B

+ 4
- 4
projects/VS2017/examples/core_basic_window.vcxproj View File

@ -98,7 +98,7 @@
<Optimization>Disabled</Optimization>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;PLATFORM_DESKTOP;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<CompileAs>CompileAsC</CompileAs>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\release\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
@ -115,7 +115,7 @@
<Optimization>Disabled</Optimization>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;PLATFORM_DESKTOP;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<CompileAs>CompileAsC</CompileAs>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\release\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
@ -133,7 +133,7 @@
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions);PLATFORM_DESKTOP</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\release\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<CompileAs>CompileAsC</CompileAs>
<RemoveUnreferencedCodeData>true</RemoveUnreferencedCodeData>
</ClCompile>
@ -155,7 +155,7 @@
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions);PLATFORM_DESKTOP</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\release\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<CompileAs>CompileAsC</CompileAs>
<RemoveUnreferencedCodeData>true</RemoveUnreferencedCodeData>
</ClCompile>

+ 4
- 4
projects/VS2017/examples/core_basic_window_cpp.vcxproj View File

@ -97,7 +97,7 @@
<WarningLevel>Level3</WarningLevel>
<Optimization>Disabled</Optimization>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\release\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<CompileAs>CompileAsCpp</CompileAs>
</ClCompile>
<Link>
@ -114,7 +114,7 @@
<WarningLevel>Level3</WarningLevel>
<Optimization>Disabled</Optimization>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\release\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<CompileAs>CompileAsCpp</CompileAs>
</ClCompile>
<Link>
@ -134,7 +134,7 @@
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<CompileAs>CompileAsCpp</CompileAs>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\release\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
@ -155,7 +155,7 @@
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<CompileAs>CompileAsCpp</CompileAs>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\release\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>

BIN
raylib.rc.o View File


+ 9
- 8
src/CMakeLists.txt View File

@ -45,13 +45,8 @@ endif()
add_definitions("-DRAYLIB_CMAKE=1")
if(USE_AUDIO)
if (NOT USE_OPENAL_BACKEND)
file(GLOB mini_al external/mini_al.c)
MESSAGE(STATUS "Audio Backend: mini_al")
else()
find_package(OpenAL REQUIRED)
MESSAGE(STATUS "Audio Backend: OpenAL")
endif()
file(GLOB mini_al external/mini_al.c)
MESSAGE(STATUS "Audio Backend: mini_al")
file(GLOB stb_vorbis external/stb_vorbis.c)
set(sources ${raylib_sources} ${mini_al} ${stb_vorbis})
else()
@ -73,6 +68,10 @@ if(${PLATFORM} MATCHES "Desktop")
find_library(OPENGL_LIBRARY OpenGL)
set(LIBS_PRIVATE ${OPENGL_LIBRARY})
link_libraries("${LIBS_PRIVATE}")
if (NOT CMAKE_SYSTEM STRLESS "Darwin-18.0.0")
add_definitions(-DGL_SILENCE_DEPRECATION)
MESSAGE(AUTHOR_WARNING "OpenGL is deprecated starting with macOS 10.14 (Mojave)!")
endif()
elseif(WIN32)
add_definitions(-D_CRT_SECURE_NO_WARNINGS)
else()
@ -131,7 +130,7 @@ if (${OPENGL_VERSION})
elseif (${OPENGL_VERSION} MATCHES "ES 2.0")
set(GRAPHICS "GRAPHICS_API_OPENGL_ES2")
endif()
if (o">${SUGGESTED_GRAPHICS} AND NOT "${SUGGESTED_GRAPHICS}" STREQUAL "${GRAPHICS}")
if (s2">"${SUGGESTED_GRAPHICS}" AND NOT "${SUGGESTED_GRAPHICS}" STREQUAL "${GRAPHICS}")
message(WARNING "You are overriding the suggested GRAPHICS=${SUGGESTED_GRAPHICS} with ${GRAPHICS}! This may fail")
endif()
endif()
@ -146,6 +145,7 @@ include(LibraryPathToLinkerFlags)
library_path_to_linker_flags(__PKG_CONFIG_LIBS_PRIVATE "${LIBS_PRIVATE}")
if(STATIC)
MESSAGE(STATUS "Building raylib static library")
if(${PLATFORM} MATCHES "Web")
set(CMAKE_STATIC_LIBRARY_SUFFIX ".bc")
endif()
@ -182,6 +182,7 @@ endif(STATIC)
if(SHARED)
MESSAGE(STATUS "Building raylib shared library")
add_library(raylib SHARED ${sources})
target_compile_definitions(raylib

+ 8
- 5
src/CMakeOptions.txt View File

@ -12,11 +12,6 @@ option(SHARED "Build raylib as a dynamic library" OFF)
option(STATIC "Build raylib as a static library" ON)
option(MACOS_FATLIB "Build fat library for both i386 and x86_64 on macOS" OFF)
option(USE_AUDIO "Build raylib with audio module" ON)
if(${PLATFORM} MATCHES "Web")
cmake_dependent_option(USE_OPENAL_BACKEND "Link raylib with openAL instead of mini-al" ON "USE_AUDIO" OFF)
else()
cmake_dependent_option(USE_OPENAL_BACKEND "Link raylib with openAL instead of mini-al" OFF "USE_AUDIO" OFF)
endif()
enum_option(USE_EXTERNAL_GLFW "OFF;IF_POSSIBLE;ON" "Link raylib against system GLFW instead of embedded one")
if(UNIX AND NOT APPLE)
@ -84,6 +79,14 @@ if(NOT (STATIC OR SHARED))
message(FATAL_ERROR "Nothing to do if both -DSHARED=OFF and -DSTATIC=OFF...")
endif()
if (DEFINED BUILD_SHARED_LIBS)
set(SHARED ${BUILD_SHARED_LIBS})
if (${BUILD_SHARED_LIBS})
set(STATIC OFF)
else()
set(STATIC ON)
endif()
endif()
if(DEFINED SHARED_RAYLIB)
set(SHARED ${SHARED_RAYLIB})
message(DEPRECATION "-DSHARED_RAYLIB is deprecated. Please use -DSHARED instead.")

+ 2
- 24
src/Makefile View File

@ -63,14 +63,6 @@ RAYLIB_BUILD_MODE ?= RELEASE
# NOTE: Some programs like tools could not require audio support
INCLUDE_AUDIO_MODULE ?= TRUE
# Use OpenAL Soft backend for audio
USE_OPENAL_BACKEND ?= FALSE
# OpenAL Soft audio backend forced on HTML5 and OSX (see below)
ifeq ($(PLATFORM),PLATFORM_WEB)
USE_OPENAL_BACKEND = TRUE
endif
# Use external GLFW library instead of rglfw module
# TODO: Review usage of examples on Linux.
USE_EXTERNAL_GLFW ?= FALSE
@ -154,13 +146,6 @@ endif
# RAYLIB_PATH ?= /home/pi/raylib
#endif
# Force OpenAL Soft audio backend for OSX platform
# NOTE 1: mini_al library does not support CoreAudio yet
# NOTE 2: Required OpenAL libraries should be available on OSX
ifeq ($(PLATFORM_OS),OSX)
USE_OPENAL_BACKEND = TRUE
endif
ifeq ($(PLATFORM),PLATFORM_WEB)
# Emscripten required variables
EMSDK_PATH = C:/emsdk
@ -343,11 +328,6 @@ ifeq ($(RAYLIB_LIBTYPE),SHARED)
CFLAGS += -fPIC -DBUILD_LIBTYPE_SHARED
endif
# Use OpenAL Soft backend instead of mini_al
ifeq ($(USE_OPENAL_BACKEND),TRUE)
CFLAGS += -DUSE_OPENAL_BACKEND
endif
# Use Wayland display on Linux desktop
ifeq ($(PLATFORM),PLATFORM_DESKTOP)
ifeq ($(PLATFORM_OS), LINUX)
@ -359,7 +339,7 @@ endif
# Define include paths for required headers
# NOTE: Several external required libraries (stb and others)
INCLUDE_PATHS = -I. -Iexternal -Iexternal/glfw/include
INCLUDE_PATHS = -I. -Iexternal/glfw/include
ifeq ($(PLATFORM),PLATFORM_DESKTOP)
ifeq ($(PLATFORM_OS),BSD)
@ -426,9 +406,7 @@ endif
ifeq ($(INCLUDE_AUDIO_MODULE),TRUE)
OBJS += audio.o
OBJS += stb_vorbis.o
ifeq ($(USE_OPENAL_BACKEND),FALSE)
OBJS += mini_al.o
endif
OBJS += mini_al.o
endif
ifeq ($(PLATFORM),PLATFORM_ANDROID)

+ 36
- 626
src/audio.c
File diff suppressed because it is too large
View File


+ 1
- 1
src/config.h View File

@ -25,7 +25,7 @@
*
**********************************************************************************************/
#define RAYLIB_VERSION "2.0"
#define RAYLIB_VERSION "2.1-dev"
// Edit to control what features Makefile'd raylib is compiled with
#if defined(RAYLIB_CMAKE)

Some files were not shown because too many files changed in this diff

||||||
x
 
000:0
Loading…
Cancel
Save