diff options
| author | Ray <[email protected]> | 2019-01-10 16:32:40 +0100 |
|---|---|---|
| committer | Ray <[email protected]> | 2019-01-10 16:32:40 +0100 |
| commit | 93471b0a7c75fc675f27fc74dfda281eb8310a7a (patch) | |
| tree | b626b2cbe7ade9c8d180f25d16969a2f92992d0f | |
| parent | 64fd131ed584d063e4f1ee63050d19ca8413a32a (diff) | |
| download | raylib-93471b0a7c75fc675f27fc74dfda281eb8310a7a.tar.gz raylib-93471b0a7c75fc675f27fc74dfda281eb8310a7a.zip | |
WARNING: Renamed module: audio -> raudio
Planning to promote raudio module as a simple and easy-to-use front-end for the amazing mini_al library, so the name change.
Name comes from raylib-audio but in spanish it also remembers to word "raudo", meaning "very fast", an analogy that fits perfectly to the usefulness and performance of the library!
Consequently, raylib version has been bumped to 2.4-dev.
| -rw-r--r-- | HISTORY.md | 2 | ||||
| -rw-r--r-- | README.md | 2 | ||||
| -rw-r--r-- | examples/others/raudio_standalone.c (renamed from examples/others/audio_standalone.c) | 8 | ||||
| -rw-r--r-- | projects/Geany/raylib_compile_sources.bat | 4 | ||||
| -rw-r--r-- | projects/Notepad++/npes_saved_mingw.txt | bin | 7620 -> 7622 bytes | |||
| -rw-r--r-- | projects/Notepad++/npes_saved_tcc.txt | bin | 7546 -> 7548 bytes | |||
| -rwxr-xr-x | projects/scripts/linux-build.sh | 2 | ||||
| -rwxr-xr-x | projects/scripts/osx-build.sh | 2 | ||||
| -rw-r--r-- | projects/scripts/windows-build.bat | 2 | ||||
| -rw-r--r-- | src/CMakeLists.txt | 4 | ||||
| -rw-r--r-- | src/CMakeOptions.txt | 2 | ||||
| -rw-r--r-- | src/Makefile | 4 | ||||
| -rw-r--r-- | src/config.h | 2 | ||||
| -rw-r--r-- | src/config.h.in | 2 | ||||
| -rw-r--r-- | src/libraylib.a | bin | 0 -> 1287474 bytes | |||
| -rw-r--r-- | src/raudio.c (renamed from src/audio.c) | 12 | ||||
| -rw-r--r-- | src/raudio.h (renamed from src/audio.h) | 0 |
17 files changed, 24 insertions, 24 deletions
@@ -149,7 +149,7 @@ On November 2016, only 4 months after raylib 1.5, arrives raylib 1.6. This new v Complete [raylib Lua binding](https://github.com/raysan5/raylib-lua). All raylib functions plus the +60 code examples have been ported to Lua, now Lua users can enjoy coding videogames in Lua while using all the internal power of raylib. This addition also open the doors to Lua scripting support for a future raylib-based engine, being able to move game logic (Init, Update, Draw, De-Init) to Lua scripts while keep using raylib functionality. -Completely redesigned [audio module](https://github.com/raysan5/raylib/blob/master/src/audio.c). Based on the new direction taken in raylib 1.5, it has been further improved and more functionality added (+20 new functions) to allow raw audio processing and streaming. [FLAC file format support](https://github.com/raysan5/raylib/blob/master/src/external/dr_flac.h) has also been added. In the same line, [OpenAL Soft](https://github.com/kcat/openal-soft) backend is now provided as a static library in Windows to allow static linking and get ride of OpenAL32.dll. Now raylib Windows games are completey self-contained, no external libraries required any more! +Completely redesigned [audio module](https://github.com/raysan5/raylib/blob/master/src/raudio.c). Based on the new direction taken in raylib 1.5, it has been further improved and more functionality added (+20 new functions) to allow raw audio processing and streaming. [FLAC file format support](https://github.com/raysan5/raylib/blob/master/src/external/dr_flac.h) has also been added. In the same line, [OpenAL Soft](https://github.com/kcat/openal-soft) backend is now provided as a static library in Windows to allow static linking and get ride of OpenAL32.dll. Now raylib Windows games are completey self-contained, no external libraries required any more! [Physac](https://github.com/victorfisac/Physac) module has been moved to its own repository and it has been improved A LOT, actually, library has been completely rewritten from scratch by [@victorfisac](https://github.com/victorfisac), multiple samples have been added together with countless new features to match current standard 2D physic libraries. Results are amazing! @@ -35,7 +35,7 @@ features 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. -raylib uses on its [audio](https://github.com/raysan5/raylib/blob/master/src/audio.c) module, the amazing [mini_al](https://github.com/dr-soft/mini_al) audio library, single-file header-only and supporting multiple platforms and multiple audio backends. +raylib uses on its [audio](https://github.com/raysan5/raylib/blob/master/src/raudio.c) module, the amazing [mini_al](https://github.com/dr-soft/mini_al) audio library, single-file header-only and supporting multiple platforms and multiple audio backends. raylib uses internally multiple single-file header-only libraries to support multiple fileformats loading and saving, all those libraries are embedded with raylib and available in [src/external](https://github.com/raysan5/raylib/tree/master/src/external) directory. diff --git a/examples/others/audio_standalone.c b/examples/others/raudio_standalone.c index f08fbf82..930bde85 100644 --- a/examples/others/audio_standalone.c +++ b/examples/others/raudio_standalone.c @@ -1,6 +1,6 @@ /******************************************************************************************* * -* raylib [audio] example - Using audio module as standalone module +* raylib [audio] example - Using raudio module as standalone module * * NOTE: This example does not require any graphic device, it can run directly on console. * @@ -13,7 +13,7 @@ * * COMPILATION: * gcc -c ..\..\src\external\mini_al.c -Wall -I. -* gcc -o audio_standalone.exe audio_standalone.c ..\..\src\audio.c ..\..\src\external\stb_vorbis.c mini_al.o / +* gcc -o audio_standalone.exe audio_standalone.c ..\..\src\raudio.c mini_al.o / * -I..\..\src -I..\..\src\external -L. -Wall -std=c99 / * -DAUDIO_STANDALONE -DSUPPORT_FILEFORMAT_WAV -DSUPPORT_FILEFORMAT_OGG * @@ -22,7 +22,7 @@ * This example 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) 2014-2018 Ramon Santamaria (@raysan5) +* Copyright (c) 2014-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,7 +41,7 @@ * ********************************************************************************************/ -#include "audio.h" // Audio library +#include "raudio.h" // raylib audio library #include <stdio.h> // Required for: printf() diff --git a/projects/Geany/raylib_compile_sources.bat b/projects/Geany/raylib_compile_sources.bat index 8a5c1e7b..708873c2 100644 --- a/projects/Geany/raylib_compile_sources.bat +++ b/projects/Geany/raylib_compile_sources.bat @@ -23,14 +23,14 @@ gcc -O2 -c shapes.c -std=c99 -Wall -DPLATFORM_DESKTOP gcc -O2 -c textures.c -std=c99 -Wall -DPLATFORM_DESKTOP gcc -O2 -c text.c -std=c99 -Wall -DPLATFORM_DESKTOP gcc -O2 -c models.c -std=c99 -Wall -DPLATFORM_DESKTOP -gcc -O2 -c audio.c -std=c99 -Wall -DPLATFORM_DESKTOP +gcc -O2 -c raudio.c -std=c99 -Wall -DPLATFORM_DESKTOP gcc -O2 -c external/mini_al.c -Wall -I. gcc -O2 -c utils.c -std=c99 -Wall -DPLATFORM_DESKTOP :: . :: . > Generate raylib library :: ------------------------------ -ar rcs libraylib.a core.o rglfw.o shapes.o textures.o text.o models.o audio.o mini_al.o utils.o +ar rcs libraylib.a core.o rglfw.o shapes.o textures.o text.o models.o raudio.o mini_al.o utils.o :: . :: > Installing raylib library :: ----------------------------- diff --git a/projects/Notepad++/npes_saved_mingw.txt b/projects/Notepad++/npes_saved_mingw.txt Binary files differindex 6857fa13..6d10a1b0 100644 --- a/projects/Notepad++/npes_saved_mingw.txt +++ b/projects/Notepad++/npes_saved_mingw.txt diff --git a/projects/Notepad++/npes_saved_tcc.txt b/projects/Notepad++/npes_saved_tcc.txt Binary files differindex 6b8d6f2e..32d72c2f 100644 --- a/projects/Notepad++/npes_saved_tcc.txt +++ b/projects/Notepad++/npes_saved_tcc.txt diff --git a/projects/scripts/linux-build.sh b/projects/scripts/linux-build.sh index 851ea1a5..abbe0e47 100755 --- a/projects/scripts/linux-build.sh +++ b/projects/scripts/linux-build.sh @@ -114,7 +114,7 @@ if [ ! -d "$TEMP_DIR" ]; then mkdir -p $TEMP_DIR cd $TEMP_DIR RAYLIB_DEFINES="-D_DEFAULT_SOURCE -DPLATFORM_DESKTOP -DGRAPHICS_API_OPENGL_33" - RAYLIB_C_FILES="$RAYLIB_SRC/core.c $RAYLIB_SRC/shapes.c $RAYLIB_SRC/textures.c $RAYLIB_SRC/text.c $RAYLIB_SRC/models.c $RAYLIB_SRC/utils.c $RAYLIB_SRC/audio.c $RAYLIB_SRC/rglfw.c $RAYLIB_SRC/external/mini_al.c" + RAYLIB_C_FILES="$RAYLIB_SRC/core.c $RAYLIB_SRC/shapes.c $RAYLIB_SRC/textures.c $RAYLIB_SRC/text.c $RAYLIB_SRC/models.c $RAYLIB_SRC/utils.c $RAYLIB_SRC/raudio.c $RAYLIB_SRC/rglfw.c $RAYLIB_SRC/external/mini_al.c" RAYLIB_INCLUDE_FLAGS="-I$RAYLIB_SRC -I$RAYLIB_SRC/external/glfw/include" if [ -n "$REALLY_QUIET" ]; then diff --git a/projects/scripts/osx-build.sh b/projects/scripts/osx-build.sh index 36558f63..fd4f77b7 100755 --- a/projects/scripts/osx-build.sh +++ b/projects/scripts/osx-build.sh @@ -108,7 +108,7 @@ if [ ! -d "$TEMP_DIR" ]; then mkdir -p $TEMP_DIR cd $TEMP_DIR RAYLIB_DEFINES="-D_DEFAULT_SOURCE -DPLATFORM_DESKTOP -DGRAPHICS_API_OPENGL_33" - RAYLIB_C_FILES="$RAYLIB_SRC/core.c $RAYLIB_SRC/shapes.c $RAYLIB_SRC/textures.c $RAYLIB_SRC/text.c $RAYLIB_SRC/models.c $RAYLIB_SRC/utils.c $RAYLIB_SRC/audio.c $RAYLIB_SRC/external/mini_al.c" + RAYLIB_C_FILES="$RAYLIB_SRC/core.c $RAYLIB_SRC/shapes.c $RAYLIB_SRC/textures.c $RAYLIB_SRC/text.c $RAYLIB_SRC/models.c $RAYLIB_SRC/utils.c $RAYLIB_SRC/raudio.c $RAYLIB_SRC/external/mini_al.c" RAYLIB_INCLUDE_FLAGS="-I$RAYLIB_SRC -I$RAYLIB_SRC/external/glfw/include" if [ -n "$REALLY_QUIET" ]; then diff --git a/projects/scripts/windows-build.bat b/projects/scripts/windows-build.bat index c4be4c89..e56141bc 100644 --- a/projects/scripts/windows-build.bat +++ b/projects/scripts/windows-build.bat @@ -159,7 +159,7 @@ IF NOT EXIST !TEMP_DIR!\ ( cd !TEMP_DIR! REM Raylib's src folder set "RAYLIB_DEFINES=/D_DEFAULT_SOURCE /DPLATFORM_DESKTOP /DGRAPHICS_API_OPENGL_33" - set RAYLIB_C_FILES="!RAYLIB_SRC!\core.c" "!RAYLIB_SRC!\shapes.c" "!RAYLIB_SRC!\textures.c" "!RAYLIB_SRC!\text.c" "!RAYLIB_SRC!\models.c" "!RAYLIB_SRC!\utils.c" "!RAYLIB_SRC!\audio.c" "!RAYLIB_SRC!\rglfw.c" "!RAYLIB_SRC!\external\mini_al.c" + set RAYLIB_C_FILES="!RAYLIB_SRC!\core.c" "!RAYLIB_SRC!\shapes.c" "!RAYLIB_SRC!\textures.c" "!RAYLIB_SRC!\text.c" "!RAYLIB_SRC!\models.c" "!RAYLIB_SRC!\utils.c" "!RAYLIB_SRC!\raudio.c" "!RAYLIB_SRC!\rglfw.c" "!RAYLIB_SRC!\external\mini_al.c" set RAYLIB_INCLUDE_FLAGS=/I"!RAYLIB_SRC!" /I"!RAYLIB_SRC!\external\glfw\include" IF DEFINED REALLY_QUIET ( diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 7a91f13a..504930d4 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -51,7 +51,7 @@ if(USE_AUDIO) else() MESSAGE(STATUS "Audio Backend: None (-DUSE_AUDIO=OFF)") set(INCLUDE_AUDIO_MODULE 0) - list(REMOVE_ITEM raylib_sources ${CMAKE_CURRENT_SOURCE_DIR}/audio.c) + list(REMOVE_ITEM raylib_sources ${CMAKE_CURRENT_SOURCE_DIR}/raudio.c) set(sources ${raylib_sources}) endif() @@ -250,7 +250,7 @@ file(COPY "raylib.h" DESTINATION ".") file(COPY "rlgl.h" DESTINATION ".") file(COPY "physac.h" DESTINATION ".") file(COPY "raymath.h" DESTINATION ".") -file(COPY "audio.h" DESTINATION ".") +file(COPY "raudio.h" DESTINATION ".") # Print the flags for the user message(STATUS "Compiling with the flags:") diff --git a/src/CMakeOptions.txt b/src/CMakeOptions.txt index ee63c5b4..b69c443f 100644 --- a/src/CMakeOptions.txt +++ b/src/CMakeOptions.txt @@ -61,7 +61,7 @@ option(SUPPORT_FILEFORMAT_OBJ "Support loading OBJ file format" ON) option(SUPPORT_FILEFORMAT_MTL "Support loading MTL file format" ON) option(SUPPORT_MESH_GENERATION "Support procedural mesh generation functions, uses external par_shapes.h library. NOTE: Some generated meshes DO NOT include generated texture coordinates" ON) -# audio.c +# raudio.c option(SUPPORT_FILEFORMAT_WAV "Support loading WAV for sound" ON) option(SUPPORT_FILEFORMAT_OGG "Support loading OGG for sound" ON) option(SUPPORT_FILEFORMAT_XM "Support loading XM for sound" ON) diff --git a/src/Makefile b/src/Makefile index 2c2bfb27..b99ff711 100644 --- a/src/Makefile +++ b/src/Makefile @@ -403,7 +403,7 @@ ifeq ($(PLATFORM),PLATFORM_DESKTOP) endif ifeq ($(INCLUDE_AUDIO_MODULE),TRUE) - OBJS += audio.o + OBJS += raudio.o OBJS += mini_al.o endif @@ -529,7 +529,7 @@ models.o : models.c raylib.h rlgl.h raymath.h $(CC) -c $< $(CFLAGS) $(INCLUDE_PATHS) -D$(PLATFORM) -D$(GRAPHICS) # Compile audio module -audio.o : audio.c raylib.h +raudio.o : raudio.c raylib.h $(CC) -c $< $(CFLAGS) $(INCLUDE_PATHS) -D$(PLATFORM) # Compile mini_al audio library diff --git a/src/config.h b/src/config.h index 6d16207c..d45ff707 100644 --- a/src/config.h +++ b/src/config.h @@ -25,7 +25,7 @@ * **********************************************************************************************/ -#define RAYLIB_VERSION "2.3-dev" +#define RAYLIB_VERSION "2.4-dev" // Edit to control what features Makefile'd raylib is compiled with #if defined(RAYLIB_CMAKE) diff --git a/src/config.h.in b/src/config.h.in index 928405cd..b1c524f7 100644 --- a/src/config.h.in +++ b/src/config.h.in @@ -65,7 +65,7 @@ * NOTE: Some generated meshes DO NOT include generated texture coordinates */ #cmakedefine SUPPORT_MESH_GENERATION 1 -// audio.c +// raudio.c /* Desired fileformats to be supported for loading. */ #cmakedefine SUPPORT_FILEFORMAT_WAV 1 #cmakedefine SUPPORT_FILEFORMAT_OGG 1 diff --git a/src/libraylib.a b/src/libraylib.a Binary files differnew file mode 100644 index 00000000..5aa7099d --- /dev/null +++ b/src/libraylib.a diff --git a/src/audio.c b/src/raudio.c index a76481b4..3510acd5 100644 --- a/src/audio.c +++ b/src/raudio.c @@ -12,7 +12,7 @@ * * CONFIGURATION: * -* #define AUDIO_STANDALONE +* #define RAUDIO_STANDALONE * Define to use the module as standalone library (independently of raylib). * Required types and functions are defined in the same module. * @@ -70,8 +70,8 @@ * **********************************************************************************************/ -#if defined(AUDIO_STANDALONE) - #include "audio.h" +#if defined(RAUDIO_STANDALONE) + #include "raudio.h" #include <stdarg.h> // Required for: va_list, va_start(), vfprintf(), va_end() #else #include "raylib.h" // Declares module functions @@ -169,7 +169,7 @@ typedef struct MusicData { unsigned int samplesLeft; // Number of samples left to end } MusicData; -#if defined(AUDIO_STANDALONE) +#if defined(RAUDIO_STANDALONE) typedef enum { LOG_INFO = 0, LOG_ERROR, @@ -201,7 +201,7 @@ static Wave LoadFLAC(const char *fileName); // Load FLAC file static Wave LoadMP3(const char *fileName); // Load MP3 file #endif -#if defined(AUDIO_STANDALONE) +#if defined(RAUDIO_STANDALONE) bool IsFileExtension(const char *fileName, const char *ext); // Check file extension void TraceLog(int msgType, const char *text, ...); // Show trace log messages (LOG_INFO, LOG_WARNING, LOG_ERROR, LOG_DEBUG) #endif @@ -1918,7 +1918,7 @@ static Wave LoadMP3(const char *fileName) #endif // Some required functions for audio standalone module version -#if defined(AUDIO_STANDALONE) +#if defined(RAUDIO_STANDALONE) // Check file extension bool IsFileExtension(const char *fileName, const char *ext) { diff --git a/src/audio.h b/src/raudio.h index 01c93741..01c93741 100644 --- a/src/audio.h +++ b/src/raudio.h |
