Skip to content

Commit

Permalink
update for raylib 5.5
Browse files Browse the repository at this point in the history
  • Loading branch information
perigrin committed Nov 21, 2024
1 parent 51d0b4b commit 93a8788
Show file tree
Hide file tree
Showing 14 changed files with 369 additions and 228 deletions.
18 changes: 16 additions & 2 deletions .github/workflows/install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ jobs:
strategy:
fail-fast: false
matrix:
#os: [ubuntu-latest, macos-latest] # for now we drop windows
os: [ubuntu-latest, macos-latest, windows-latest]
perl-version: ['5.38', '5.40']

Expand All @@ -21,7 +20,9 @@ jobs:

steps:
- uses: actions/checkout@v4

- uses: shogo82148/actions-setup-perl@v1
with:
perl-version: ${{ matrix.perl-version }}
- name: Install System Dependencies (Linux)
if: runner.os == 'Linux'
run: |
Expand All @@ -38,6 +39,19 @@ jobs:
libwayland-dev \
libxkbcommon-dev
- name: Install Alien-raylib5
uses: perl-actions/[email protected]
with:
install: https://github.com/perigrin/Alien-raylib5.git
verbose: true

# as of right now 6.2 doesn't pass tests so we install it by hand
- name: Install Module::Pluggable
uses: perl-actions/[email protected]
with:
install: Module::Pluggable
tests: false

- name: Build and Test
uses: perl-actions/[email protected]
with:
Expand Down
4 changes: 2 additions & 2 deletions Build.PL
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# This Build.PL for Raylib-FFI was generated by mbtiny 0.044.
use 5.008;
# This Build.PL for Raylib-FFI was generated by mbtiny 0.047.
use v5.38.0;
use Module::Build::Tiny 0.039;
Build_PL();
11 changes: 9 additions & 2 deletions Changes
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
Revision history for Raylib-FFI

0.001 2024-06-26
First release
0.02 2024-11-20 Added support for raylib 5.5
- Updated validation function names from "Ready" to "Valid" to match
raylib 5.5
- Added new window management functions (ToggleBorderlessWindowed,
SetWindowIcons, SetWindowFocused, GetWindowScaleDPI)
- Added new clipboard function (GetClipboardImage)
- Added event waiting functions (EnableEventWaiting, DisableEventWaiting)

0.01 2024-06-26
First release
24 changes: 17 additions & 7 deletions META.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"Ahmad Fatoum C<< <[email protected]> >>, L<http://a3f.at>"
],
"dynamic_config" : 0,
"generated_by" : "App::ModuleBuildTiny version 0.044",
"generated_by" : "App::ModuleBuildTiny version 0.047",
"license" : [
"perl_5"
],
Expand All @@ -23,19 +23,20 @@
},
"develop" : {
"requires" : {
"App::ModuleBuildTiny" : "0.044"
"App::ModuleBuildTiny" : "0.047"
}
},
"runtime" : {
"requires" : {
"Alien::raylib" : "0",
"Alien::raylib5" : "0",
"Convert::Color" : "0",
"FFI::C" : "0",
"FFI::CheckLib" : "0",
"FFI::Platypus" : "0",
"FFI::Platypus" : "2.08",
"File::Share" : "0",
"Module::Build::Tiny" : "0",
"builtin::Backport" : "0"
"builtin::Backport" : "0",
"perl" : "v5.38.0"
}
}
},
Expand All @@ -48,11 +49,17 @@
},
"Raylib::FFI" : {
"file" : "lib/Raylib/FFI.pm",
"version" : "0.01"
"version" : "0.02"
},
"Raylib::FFI::AudioStream" : {
"file" : "lib/Raylib/FFI.pm"
},
"Raylib::FFI::AutomationEvent" : {
"file" : "lib/Raylib/FFI.pm"
},
"Raylib::FFI::AutomationEventList" : {
"file" : "lib/Raylib/FFI.pm"
},
"Raylib::FFI::BoneInfo" : {
"file" : "lib/Raylib/FFI.pm"
},
Expand All @@ -68,6 +75,9 @@
"Raylib::FFI::Color" : {
"file" : "lib/Raylib/FFI.pm"
},
"Raylib::FFI::FilePathList" : {
"file" : "lib/Raylib/FFI.pm"
},
"Raylib::FFI::Font" : {
"file" : "lib/Raylib/FFI.pm"
},
Expand Down Expand Up @@ -160,7 +170,7 @@
}
},
"release_status" : "stable",
"version" : "0.01",
"version" : "0.02",
"x_serialization_backend" : "JSON::PP version 4.16",
"x_spdx_expression" : "Artistic-1.0-Perl OR GPL-1.0-or-later"
}
17 changes: 12 additions & 5 deletions META.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ build_requires: {}
configure_requires:
Module::Build::Tiny: '0.039'
dynamic_config: 0
generated_by: 'App::ModuleBuildTiny version 0.044, CPAN::Meta::Converter version 2.150010'
generated_by: 'App::ModuleBuildTiny version 0.047, CPAN::Meta::Converter version 2.150010'
license: perl
meta-spec:
url: http://module-build.sourceforge.net/META-spec-v1.4.html
Expand All @@ -21,9 +21,13 @@ provides:
file: lib/Raylib/Color.pm
Raylib::FFI:
file: lib/Raylib/FFI.pm
version: '0.01'
version: '0.02'
Raylib::FFI::AudioStream:
file: lib/Raylib/FFI.pm
Raylib::FFI::AutomationEvent:
file: lib/Raylib/FFI.pm
Raylib::FFI::AutomationEventList:
file: lib/Raylib/FFI.pm
Raylib::FFI::BoneInfo:
file: lib/Raylib/FFI.pm
Raylib::FFI::BoundingBox:
Expand All @@ -34,6 +38,8 @@ provides:
file: lib/Raylib/FFI.pm
Raylib::FFI::Color:
file: lib/Raylib/FFI.pm
Raylib::FFI::FilePathList:
file: lib/Raylib/FFI.pm
Raylib::FFI::Font:
file: lib/Raylib/FFI.pm
Raylib::FFI::GlyphInfo:
Expand Down Expand Up @@ -95,14 +101,15 @@ provides:
Raylib::Texture:
file: lib/Raylib/Texture.pm
requires:
Alien::raylib: '0'
Alien::raylib5: '0'
Convert::Color: '0'
FFI::C: '0'
FFI::CheckLib: '0'
FFI::Platypus: '0'
FFI::Platypus: '2.08'
File::Share: '0'
Module::Build::Tiny: '0'
builtin::Backport: '0'
version: '0.01'
perl: v5.38.0
version: '0.02'
x_serialization_backend: 'CPAN::Meta::YAML version 0.018'
x_spdx_expression: 'Artistic-1.0-Perl OR GPL-1.0-or-later'
46 changes: 27 additions & 19 deletions README
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ FUNCTIONS
Check if application should close (KEY_ESCAPE pressed or windows close
icon clicked).

IsWindowReady() : bool
IsWindowValid() : bool

Check if window has been initialized successfully.

Expand Down Expand Up @@ -274,6 +274,10 @@ FUNCTIONS

Set window opacity [0.0f..1.0f]

SetWindowFocused()

Set window focused

GetScreenWidth() : int

Get current screen width.
Expand Down Expand Up @@ -342,6 +346,10 @@ FUNCTIONS

Get clipboard text content.

GetClipboardImage() : Raylib::FFI::Image

Get clipboard image content.

EnableEventWaiting()

Enable waiting for events on EndDrawing, automatic event polling.
Expand Down Expand Up @@ -459,9 +467,9 @@ FUNCTIONS

Load shader from code strings and bind default locations.

IsShaderReady( $shader ) : bool
IsShaderValid( $shader ) : bool

Check if a shader is ready.
Check if a shader is valid.

GetShaderLocation( $shader, $uniformName ) : int

Expand Down Expand Up @@ -1082,7 +1090,7 @@ FUNCTIONS
Load image from screen buffer and (screenshot) NOTE: This function
requires GPU access

IsImageReady( $image ) : bool
IsImageValid( $image ) : bool

Check if an image is ready

Expand Down Expand Up @@ -1356,15 +1364,15 @@ FUNCTIONS
Load texture for rendering (framebuffer) NOTE: This function requires
GPU access

IsTextureReady( $texture ) : bool
IsTextureValid( $texture ) : bool

Check if a texture is ready
Check if a texture is valid

UnloadTexture( $texture )

Unload texture from GPU memory (VRAM)

IsRenderTextureReady( $renderTexture ) : bool
IsReanderTextureValid( $renderTexture ) : bool

Check if a render texture is ready

Expand Down Expand Up @@ -1498,9 +1506,9 @@ FUNCTIONS

Load font from memory buffer, fileType refers to extension: i.e. '.ttf'

IsFontReady( $font ) : bool
IsFontValid( $font ) : bool

Check if a font is ready
Check if a font is valid.

LoadFontData( $fileData, $dataSize, $fontSize, $fontChars, $glyphCount,
$type ) : Raylib::FFI::GlyphInfo
Expand Down Expand Up @@ -1698,7 +1706,7 @@ FUNCTIONS

Load model from generated mesh (default material)

IsModelReady( $model ) : bool
IsModelValid( $model ) : bool

Check if an model is ready

Expand Down Expand Up @@ -1822,7 +1830,7 @@ FUNCTIONS
Load default material (Supports: Diffuse Maps, Specular Maps, Normal
Maps)

IsMaterialReady( $material ) : bool
IsMaterialValid( $material ) : bool

Check if a material is ready

Expand Down Expand Up @@ -1901,7 +1909,7 @@ FUNCTIONS

Close the audio device and context

IsAudioDeviceReady() : bool
IsAudioDeviceValid() : bool

Check if audio device has been initialized successfully

Expand Down Expand Up @@ -1934,7 +1942,7 @@ FUNCTIONS
Create a new sound that shares the same sound data as another existing
sound

IsSoundReady( $sound ) : bool
IsSoundValid( $sound ) : bool

Check if a sound is ready

Expand Down Expand Up @@ -2015,7 +2023,7 @@ FUNCTIONS

Load music stream from data

IsMusicReady( $music ) : bool
IsMusicValid( $music ) : bool

Check if music stream is ready

Expand Down Expand Up @@ -2076,9 +2084,9 @@ FUNCTIONS

Load audio stream (to stream raw audio pcm data)

IsAudioStreamReady( $audioStream ) : bool
IsAudioStreamValid( $audioStream ) : bool

Check if an audio stream is ready
Check if an audio stream is valid

UnloadAudioStream( $audioStream )

Expand Down Expand Up @@ -2171,15 +2179,15 @@ POD ERRORS
Hey! The above document had some coding errors, which are explained
below:

Around line 2685:
Around line 2732:

Unknown directive: =head

Around line 2689:
Around line 2736:

Unknown directive: =head

Around line 2693:
Around line 2740:

Unknown directive: =head

6 changes: 4 additions & 2 deletions cpanfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
requires 'perl' => '5.38.0';

requires 'Module::Build::Tiny';
requires 'Alien::raylib';
requires 'Alien::raylib5';
requires 'Convert::Color';
requires 'FFI::C';
requires 'FFI::CheckLib';
requires 'FFI::Platypus';
requires 'FFI::Platypus' => '2.08';
requires 'File::Share';
requires 'builtin::Backport';
Loading

0 comments on commit 93a8788

Please sign in to comment.