diff --git a/CMakeLists.txt b/CMakeLists.txt
index 2850a647..82683907 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1,7 +1,7 @@
cmake_minimum_required(VERSION 3.11)
set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake")
project (raylib_cpp
- VERSION 4.2.4
+ VERSION 4.2.5
DESCRIPTION "raylib-cpp C++ Object Oriented Wrapper for raylib"
HOMEPAGE_URL "https://github.com/robloach/raylib-cpp"
LANGUAGES C CXX)
diff --git a/clib.json b/clib.json
index f61d4ca4..43686af0 100644
--- a/clib.json
+++ b/clib.json
@@ -1,6 +1,6 @@
{
"name": "raylib-cpp",
- "version": "4.2.2",
+ "version": "4.2.5",
"repo": "RobLoach/raylib-cpp",
"description": "raylib-cpp: C++ Object-Oriented Wrapper for raylib",
"homepage": "https://github.com/robloach/raylib-cpp",
@@ -39,7 +39,6 @@
"include/Mouse.hpp",
"include/Music.hpp",
"include/physac.hpp",
- "include/Physics.hpp",
"include/Ray.hpp",
"include/RayCollision.hpp",
"include/RaylibException.hpp",
@@ -53,6 +52,7 @@
"include/Sound.hpp",
"include/Text.hpp",
"include/Texture.hpp",
+ "include/Touch.hpp",
"include/Vector2.hpp",
"include/Vector3.hpp",
"include/Vector4.hpp",
diff --git a/docs/_audio_device_8hpp_source.html b/docs/_audio_device_8hpp_source.html
index 4f5c0848..a753b363 100644
--- a/docs/_audio_device_8hpp_source.html
+++ b/docs/_audio_device_8hpp_source.html
@@ -84,45 +84,46 @@
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
- 55 return ::IsAudioDeviceReady();
-
-
-
- 64 ::SetMasterVolume(volume);
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+ 57 return ::IsAudioDeviceReady();
+
+
+
+ 66 ::SetMasterVolume(volume);
+
+
+
+
+
+
+
+
Audio device management functions.
-void Close()
Close the audio device and context.
-bool IsReady() const
Check if audio device has been initialized successfully.
-bool Init()
Initialize audio device and context.
-~AudioDevice()
Close the audio device and context.
+void Close()
Close the audio device and context.
+bool IsReady() const
Check if audio device has been initialized successfully.
+void Init()
Initialize audio device and context.
+~AudioDevice()
Close the audio device and context.
AudioDevice(bool lateInit=false)
Initialize audio device and context.
-AudioDevice & SetVolume(float volume)
Set master volume (listener).
+AudioDevice & SetVolume(float volume)
Set master volume (listener).
Exception used for most raylib-related exceptions.
All raylib-cpp classes and functions appear in the raylib namespace.
diff --git a/docs/_audio_stream_8hpp_source.html b/docs/_audio_stream_8hpp_source.html
index 2db013e8..0080354d 100644
--- a/docs/_audio_stream_8hpp_source.html
+++ b/docs/_audio_stream_8hpp_source.html
@@ -87,24 +87,24 @@
- 19 unsigned int sampleRate = 0,
- 20 unsigned int sampleSize = 0,
- 21 unsigned int channels = 0) :
::AudioStream{buffer, sampleRate, sampleSize, channels} {
-
-
-
- 30 AudioStream(
unsigned int SampleRate,
unsigned int SampleSize,
unsigned int Channels = 2) {
- 31 if (!
Load(SampleRate, SampleSize, Channels)) {
-
-
-
-
-
-
-
-
-
- 41 other.buffer =
nullptr;
+ 19 rAudioProcessor *processor =
nullptr,
+ 20 unsigned int sampleRate = 0,
+ 21 unsigned int sampleSize = 0,
+ 22 unsigned int channels = 0) :
::AudioStream{buffer, processor, sampleRate, sampleSize, channels} {
+
+
+
+ 31 AudioStream(
unsigned int sampleRate,
unsigned int sampleSize,
unsigned int channels = 2) {
+ 32 Load(sampleRate, sampleSize, channels);
+
+
+
+
+
+
+
+ 40 other.buffer =
nullptr;
+ 41 other.processor =
nullptr;
@@ -115,120 +115,148 @@
51 GETTERSETTER(rAudioBuffer *, Buffer, buffer)
- 52 GETTERSETTER(
unsigned int, SampleRate, sampleRate)
- 53 GETTERSETTER(
unsigned int, SampleSize, sampleSize)
- 54 GETTERSETTER(
unsigned int, Channels, channels)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 71 other.buffer =
nullptr;
-
-
-
-
-
-
-
-
- 83 ::UpdateAudioStream(*
this, data, samplesCount);
-
-
-
-
- 91 ::UnloadAudioStream(*
this);
-
-
-
- 98 return ::IsAudioStreamProcessed(*
this);
-
-
-
- 105 ::PlayAudioStream(*
this);
-
-
-
-
- 113 ::PauseAudioStream(*
this);
-
-
-
-
- 121 ::ResumeAudioStream(*
this);
-
-
-
-
- 129 return ::IsAudioStreamPlaying(*
this);
-
-
-
- 136 ::StopAudioStream(*
this);
-
-
-
-
- 144 ::SetAudioStreamVolume(*
this, volume);
-
-
-
-
- 152 ::SetAudioStreamPitch(*
this, pitch);
-
-
-
-
- 160 ::SetAudioStreamBufferSizeDefault(size);
-
-
-
-
-
-
- 175 bool Load(
unsigned int SampleRate,
unsigned int SampleSize,
unsigned int Channels = 2) {
- 176 set(::LoadAudioStream(SampleRate, SampleSize, Channels));
-
+ 52 GETTERSETTER(rAudioProcessor *, Processor, processor)
+ 53 GETTERSETTER(
unsigned int, SampleRate, sampleRate)
+ 54 GETTERSETTER(
unsigned int, SampleSize, sampleSize)
+ 55 GETTERSETTER(
unsigned int, Channels, channels)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 72 other.buffer =
nullptr;
+ 73 other.processor =
nullptr;
+
+
+
+
+
+
+
+
+ 85 ::UpdateAudioStream(*
this, data, samplesCount);
+
+
+
+
+ 93 ::UnloadAudioStream(*
this);
+
+
+
+ 100 return ::IsAudioStreamProcessed(*
this);
+
+
+
+ 107 ::PlayAudioStream(*
this);
+
+
+
+
+ 115 ::PauseAudioStream(*
this);
+
+
+
+
+ 123 ::ResumeAudioStream(*
this);
+
+
+
+
+ 131 return ::IsAudioStreamPlaying(*
this);
+
+
+
+ 138 ::StopAudioStream(*
this);
+
+
+
+
+ 146 ::SetAudioStreamVolume(*
this, volume);
+
+
+
+
+ 154 ::SetAudioStreamPitch(*
this, pitch);
+
+
+
+
+ 162 ::SetAudioStreamPitch(*
this, pan);
+
+
+
+
+ 170 ::SetAudioStreamBufferSizeDefault(size);
+
+
+
+ 177 ::SetAudioStreamCallback(*
this, callback);
-
- 181 void set(const ::AudioStream& stream) {
- 182 buffer = stream.buffer;
- 183 sampleRate = stream.sampleRate;
- 184 sampleSize = stream.sampleSize;
- 185 channels = stream.channels;
-
-
-
-
-
-
+
+ 184 ::SetAudioStreamCallback(*
this, processor);
+
+
+
+ 191 ::SetAudioStreamCallback(*
this, processor);
+
+
+
+
+
+
+ 206 void Load(
unsigned int SampleRate,
unsigned int SampleSize,
unsigned int Channels = 2) {
+
+ 208 set(::LoadAudioStream(SampleRate, SampleSize, Channels));
+
+
+
+
+
+
+ 215 void set(const ::AudioStream& stream) {
+ 216 buffer = stream.buffer;
+ 217 processor = stream.processor;
+ 218 sampleRate = stream.sampleRate;
+ 219 sampleSize = stream.sampleSize;
+ 220 channels = stream.channels;
+
+
+
+
+
+
+
AudioStream management functions.
-bool IsProcessed() const
Check if any audio stream buffers requires refill.
-AudioStream & Stop()
Stop audio stream.
-AudioStream & SetPitch(float pitch)
Set pitch for audio stream (1.0 is base level)
-bool IsPlaying() const
Check if audio stream is playing.
-AudioStream & Play()
Play audio stream.
-AudioStream(unsigned int SampleRate, unsigned int SampleSize, unsigned int Channels=2)
Init audio stream (to stream raw audio pcm data)
-AudioStream & SetVolume(float volume)
Set volume for audio stream (1.0 is max level)
-void Unload()
Unload audio stream and free memory.
-static void SetBufferSizeDefault(int size)
Default size for new audio streams.
-AudioStream & Pause()
Pause audio stream.
-AudioStream & Resume()
Resume audio stream.
-AudioStream & Update(const void *data, int samplesCount)
Update audio stream buffers with data.
-bool Load(unsigned int SampleRate, unsigned int SampleSize, unsigned int Channels=2)
Init audio stream (to stream raw audio pcm data)
-bool IsReady()
Retrieve whether or not the audio stream is ready.
+void SetCallback(::AudioCallback callback)
Audio thread callback to request new data.
+bool IsProcessed() const
Check if any audio stream buffers requires refill.
+AudioStream & Stop()
Stop audio stream.
+AudioStream & SetPitch(float pitch)
Set pitch for audio stream (1.0 is base level)
+bool IsPlaying() const
Check if audio stream is playing.
+void AttachProcessor(::AudioCallback processor)
Attach audio stream processor to stream.
+AudioStream & SetVolume(float volume=1.0f)
Set volume for audio stream (1.0 is max level)
+AudioStream & Play()
Play audio stream.
+void Load(unsigned int SampleRate, unsigned int SampleSize, unsigned int Channels=2)
Load audio stream (to stream raw audio pcm data)
+void Unload()
Unload audio stream and free memory.
+static void SetBufferSizeDefault(int size)
Default size for new audio streams.
+AudioStream(unsigned int sampleRate, unsigned int sampleSize, unsigned int channels=2)
Init audio stream (to stream raw audio pcm data)
+AudioStream & Pause()
Pause audio stream.
+AudioStream & Resume()
Resume audio stream.
+AudioStream & SetPan(float pan=0.5f)
Set pan for audio stream (0.5 is centered)
+AudioStream & Update(const void *data, int samplesCount)
Update audio stream buffers with data.
+bool IsReady()
Retrieve whether or not the audio stream is ready.
+void DetachProcessor(::AudioCallback processor)
Detach audio stream processor from stream.
Exception used for most raylib-related exceptions.
All raylib-cpp classes and functions appear in the raylib namespace.
diff --git a/docs/_bounding_box_8hpp_source.html b/docs/_bounding_box_8hpp_source.html
index 0289e0d8..9dd684ed 100644
--- a/docs/_bounding_box_8hpp_source.html
+++ b/docs/_bounding_box_8hpp_source.html
@@ -82,76 +82,70 @@
-
+
-
+
-
-
-
-
-
+
+ 24 set(::GetMeshBoundingBox(mesh));
-
- 31 set(::GetMeshBoundingBox(mesh));
-
-
-
- 35 BoundingBox(::Vector3 min, ::Vector3 max) : ::BoundingBox{min, max} {}
-
-
-
-
-
-
-
-
-
-
- 49 DrawBoundingBox(*
this, color);
-
+
+ 28 BoundingBox(::Vector3 min, ::Vector3 max) : ::BoundingBox{min, max} {}
+
+
+
+
+
+
+
+
+
+
+ 42 ::DrawBoundingBox(*
this, color);
+
+
+
+
+ 50 return CheckCollisionBoxes(*
this, box2);
-
- 57 return CheckCollisionBoxes(*
this, box2);
+
+ 57 return CheckCollisionBoxSphere(*
this, center, radius);
-
- 64 return CheckCollisionBoxSphere(*
this, center, radius);
+
+ 64 return GetRayCollisionBox(ray, *
this).hit;
-
- 71 return GetRayCollisionBox(ray, *
this).hit;
+
+ 71 return GetRayCollisionBox(ray, *
this);
-
- 78 return GetRayCollisionBox(ray, *
this);
-
-
-
- 82 void set(const ::BoundingBox& box) {
-
-
-
- 86 void set(const ::Vector3& _min, const ::Vector3& _max) {
-
-
-
-
-
-
-
-
+
+ 75 void set(const ::BoundingBox& box) {
+
+
+
+ 79 void set(const ::Vector3& _min, const ::Vector3& _max) {
+
+
+
+
+
+
+
+
+
-bool CheckCollision(::Vector3 center, float radius) const
Detect collision between box and sphere.
-RayCollision GetCollision(const ::Ray &ray) const
Get collision information between ray and bounding box.
-BoundingBox(const ::Mesh &mesh)
Compute mesh bounding box limits.
-BoundingBox & Draw(::Color color={255, 255, 255, 255})
Draw a bounding box with wires.
-bool CheckCollision(const ::BoundingBox &box2) const
Detect collision between two boxes.
-bool CheckCollision(const ::Ray &ray) const
Detect collision between ray and bounding box.
+bool CheckCollision(::Vector3 center, float radius) const
Detect collision between box and sphere.
+RayCollision GetCollision(const ::Ray &ray) const
Get collision information between ray and bounding box.
+BoundingBox(const ::Mesh &mesh)
Compute mesh bounding box limits.
+BoundingBox & Draw(::Color color={255, 255, 255, 255})
Draw a bounding box with wires.
+bool CheckCollision(const ::BoundingBox &box2) const
Detect collision between two boxes.
+bool CheckCollision(const ::Ray &ray) const
Detect collision between ray and bounding box.
diff --git a/docs/_camera2_d_8hpp_source.html b/docs/_camera2_d_8hpp_source.html
index 3ca1a877..3f81d1c5 100644
--- a/docs/_camera2_d_8hpp_source.html
+++ b/docs/_camera2_d_8hpp_source.html
@@ -131,9 +131,10 @@
-
-
-
+
+
+
+
Camera2D type, defines a 2d camera.
Vector2 GetScreenToWorld(::Vector2 position) const
Returns the world space position for a 2d camera screen space position.
Matrix GetMatrix() const
Returns camera 2d transform matrix.
diff --git a/docs/_camera3_d_8hpp_source.html b/docs/_camera3_d_8hpp_source.html
index 5e98bc89..a0852f6d 100644
--- a/docs/_camera3_d_8hpp_source.html
+++ b/docs/_camera3_d_8hpp_source.html
@@ -185,14 +185,16 @@
161 typedef Camera3D Camera;
-
-
-
-
-
+
+
+
+
+
+
+
Camera type, defines a camera position/orientation in 3d space.
Camera3D & BeginMode()
Initializes 3D mode with custom camera (3D)
-Matrix GetMatrix() const
Get transform matrix for camera.
+Matrix GetMatrix() const
Get camera transform matrix (view matrix)
Camera3D & DrawBillboard(const ::Texture2D &texture, ::Rectangle sourceRec, ::Vector3 center, ::Vector2 size, ::Color tint={255, 255, 255, 255})
Draw a billboard texture defined by source.
Camera3D & DrawBillboard(const ::Texture2D &texture, ::Vector3 center, float size, ::Color tint={255, 255, 255, 255})
Draw a billboard texture.
Vector2 GetWorldToScreen(::Vector3 position) const
Returns the screen space position for a 3d world space position.
@@ -211,7 +213,7 @@
All raylib-cpp classes and functions appear in the raylib namespace.
-static void UpdateCamera(const ::Camera &camera)
Update camera depending on selected mode.
+static void UpdateCamera(const ::Camera &camera)
Update camera depending on selected mode.