Skip to content

Commit a0e19c9

Browse files
committed
Merge branch 'master' of github.com:RobLoach/raylib-cpp into next
2 parents bf0be19 + 7d2ce8f commit a0e19c9

33 files changed

+130
-77
lines changed

.github/workflows/Tests.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,9 @@ jobs:
3838
- uses: actions/checkout@v2
3939
with:
4040
submodules: recursive
41-
4241
- name: Install Linux Dependencies
4342
if: runner.os == 'Linux'
44-
run: sudo apt-get install xorg-dev libglu1-mesa-dev -y
43+
run: sudo apt-get install libasound2-dev libx11-dev libxrandr-dev libxi-dev libgl1-mesa-dev libglu1-mesa-dev libxcursor-dev libxinerama-dev -y
4544

4645
- name: Configure
4746
run: cmake -B build -S . -DBUILD_TESTING=ON -DCMAKE_CXX_FLAGS="-Wall -Wextra -Wpedantic" ${{ matrix.platform.flags }} ${{ matrix.type.flags }} ${{ matrix.config.flags }}

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
cmake_minimum_required(VERSION 3.11)
22
set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake")
33
project (raylib_cpp
4-
VERSION 4.6.0
4+
VERSION 5.0.0
55
DESCRIPTION "raylib-cpp C++ Object Oriented Wrapper for raylib"
66
HOMEPAGE_URL "https://github.com/robloach/raylib-cpp"
77
LANGUAGES C CXX

clib.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "raylib-cpp",
3-
"version": "4.6.0-alpha1",
3+
"version": "5.0.0-alpha1",
44
"repo": "RobLoach/raylib-cpp",
55
"description": "raylib-cpp: C++ Object-Oriented Wrapper for raylib",
66
"homepage": "https://github.com/robloach/raylib-cpp",

examples/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ if (NOT raylib_FOUND)
1515
FetchContent_Declare(
1616
raylib
1717
GIT_REPOSITORY https://github.com/raysan5/raylib.git
18-
GIT_TAG 334e96d470c5cb09d154e1c849d04adb721a7a8c
18+
GIT_TAG ae50bfa2cc569c0f8d5bc4315d39db64005b1b08
1919
)
2020
FetchContent_GetProperties(raylib)
2121
if (NOT raylib_POPULATED) # Have we downloaded raylib yet?

include/AudioStream.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,7 @@ class AudioStream : public ::AudioStream {
194194
/**
195195
* Retrieve whether or not the audio stream is ready.
196196
*/
197-
bool IsReady() {
197+
bool IsReady() const {
198198
return ::IsAudioStreamReady(*this);
199199
}
200200

@@ -211,7 +211,7 @@ class AudioStream : public ::AudioStream {
211211
}
212212
}
213213

214-
private:
214+
protected:
215215
void set(const ::AudioStream& stream) {
216216
buffer = stream.buffer;
217217
processor = stream.processor;

include/BoundingBox.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ class BoundingBox : public ::BoundingBox {
7070
return GetRayCollisionBox(ray, *this);
7171
}
7272

73-
private:
73+
protected:
7474
void set(const ::BoundingBox& box) {
7575
min = box.min;
7676
max = box.max;

include/Camera2D.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ class Camera2D : public ::Camera2D {
6060
return ::GetWorldToScreen2D(position, *this);
6161
}
6262

63-
private:
63+
protected:
6464
void set(const ::Camera2D& camera) {
6565
offset = camera.offset;
6666
target = camera.target;

include/Camera3D.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ class Camera3D : public ::Camera3D {
119119
::DrawBillboardRec(*this, texture, sourceRec, center, size, tint);
120120
}
121121

122-
private:
122+
protected:
123123
void set(const ::Camera3D& camera) {
124124
position = camera.position;
125125
target = camera.target;

include/Color.hpp

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,14 @@ class Color : public ::Color {
6565
return ::ColorToInt(*this);
6666
}
6767

68+
inline std::string ToString() const {
69+
return TextFormat("Color(%d, %d, %d, %d)", r, g, b, a);
70+
}
71+
72+
inline operator std::string() const {
73+
return ToString();
74+
}
75+
6876
/**
6977
* Returns color with alpha applied, alpha goes from 0.0f to 1.0f
7078
*/
@@ -257,7 +265,7 @@ class Color : public ::Color {
257265
inline static Color Magenta() { return MAGENTA; }
258266
inline static Color RayWhite() { return RAYWHITE; }
259267

260-
private:
268+
protected:
261269
void set(const ::Color& color) {
262270
r = color.r;
263271
g = color.g;

include/Font.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,7 @@ class Font : public ::Font {
206206
/**
207207
* Returns if the font is ready to be used.
208208
*/
209-
bool IsReady() {
209+
bool IsReady() const {
210210
return ::IsFontReady(*this);
211211
}
212212

@@ -287,7 +287,7 @@ class Font : public ::Font {
287287
return ::ImageTextEx(*this, text.c_str(), fontSize, spacing, tint);
288288
}
289289

290-
private:
290+
protected:
291291
void set(const ::Font& font) {
292292
baseSize = font.baseSize;
293293
glyphCount = font.glyphCount;

0 commit comments

Comments
 (0)