RayLib, a popular open source C/C++ based framework for game and multimedia development, just released RayLib 4.2. Almost a year after the release of RayLib 4.0, RayLib 4.2 has seen rapid growth in the number of contributors and much of the development of this release should make it easier for the project to scale up. Of course there are several new features as well.
Highlights of the RayLib 4.2 release include:
raylib extra libraries cleanup: raylib has been on diet and all the extra libraries included on previous releases have been removed from raylib. Now raylib only includes the original 7 raylib modules: rcore, rlgl, rshapes, rtextures, rtext, rmodels and raudio. But no worries, extra libraries have not been deleted, they have been moved to their own repos for better maintainability and more focus on its functionality. The libraries moved out from raylib repo are: raygui, physac, rmem, reasings and raudio (standalone mode). On that same line, a new amazing GitHub group: raylib-extras has been created by @JeffM2501 to contain raylib extra libraries as well as other raylib add-ons provided by the community. Jeff has done an amazing work on that line, providing multiple libraries and examples for raylib, like custom first-person and third person camera systems, Dear ImGui raylib integration, multiple specific examples and even a complete RPG Game Example! Great work Jeff! 😀
raylib examples review: The +120 raylib examples have been reviewed to add clearer information about when they were first created (raylib version used) and when they were updated for the last time. But the greatest improvement for users has been the addition of an estimated difficulty level for every example, web has been updated accordingly to reflect those difficulty levels. Now examples are classified with 1 to 4 stars depending on difficulty to help users with their learning process. Personally, I think this “small” addition could be a game-changer to better guide new users on the library adoption! Additionally, this new raylib release includes 7 new examples; the most interesting one: text_codepoints_loading that illustrates how to load and draw custom codepoints from a font file, very useful for Asian languages.
rres 1.0: New rres resources packaging file-format, including a rres-raylib library implementation and rrespacker tool. rres file format has been under development for +8 years and it was originally created to be part of raylib. It was highly inspired by XNA XNB resources file format but design has changed a lot along the years. This first release of the format specs is engine-agnostic and has been designed to be portable to any engine, including lots of professional features like data processing, compression and encryption.
raygui 3.2: The official raylib immediate-mode gui library designed for tools development has been updated to a new version aligned with raylib 4.2. Multiple controls have been reviewed for library consistency, now all controls follow a similar function signature. It has been battle-tested with the development of +8 published tools in the last months. The tools can be seen and used for free in the raylib technologies tools page. Worth mentioning that several of those tools have been open sourced for anyone to use, compile, contribute or learn how the code works.
raylib_parser: Multiple contributors using the tool to automatize bindings creation have contributed with improvements of this tool to parse raylib.h (and other raylib-style headers) to tokenize its enums, structs and functions. Processed data can be exported to custom file formats (i.e XML, JSON, LUA) for bindings generation or even docs generation if required.
New file system API: Current API has been redesigned to be more comprehensive and better aligned with raylib naming conventions, two new functions are provided LoadDirectoryFiles()/LoadDirectoryFilesEx() to load a FilePathList for provided path, supporting extension filtering and recursive directory scan. LoadDroppedFiles() has been renamed to better reflect its internal functionality. Now, all raylib functions that start with Load() allocate memory internally and a equivalent Unload() function is defined to take care of that memory internally when not required any more!
New audio stream processors API (experimental): Now real-time audio stream data processors can be added using callbacks to played Music. It allows users to create custom effects for audio like delays of low-pass-filtering (example provided). The new API uses a callback system and it’s still _ highly experimental_, it differs from the usual level of complexity that provides raylib and it is intended for advance users. It could change in the future but, actually, raudio module is in the spotlight for future updates; miniaudio implements a new higher-level API that can be useful in the future for raylib.
You can learn more about the RayLib 4.2 release in the video below.