Graphics::Raylib::Util - Utility functions for use With Graphics::Raylib::XS
version 0.018
use Graphics::Raylib::Util; # returns Graphics::Raylib::XS::{Vector2,Vector3} depending on scalar @coords my $vector = Graphics::Raylib::Util::vector(@coords);
Raylib deals a lot in value-passed structs. This module builds these structs.
Constructs a Graphics::Raylib::XS::Vector2 or Graphics::Raylib::XS::Vector3 depending on number of arguments. Croaks otherwise.
Graphics::Raylib::XS::Vector2
Graphics::Raylib::XS::Vector3
typedef struct Vector2 { float x; float y; } Vector2; typedef struct Vector3 { float x; float y; float z; } Vector3;
Constructs a Graphics::Raylib::XS::Rectangle.
Graphics::Raylib::XS::Rectangle
Constructs a Graphics::Raylib::XS::Camera3D.
Graphics::Raylib::XS::Camera3D
typedef struct Camera3D { Vector3 position; Vector3 target; Vector3 up; float fovy; int type; } Camera3D;
Constructs a Graphics::Raylib::XS::Image.
Graphics::Raylib::XS::Image
typedef struct Image { void *data; // Image raw data int width; // Image base width int height; // Image base height int mipmaps; // Mipmap levels, 1 by default int format; // Data format (PixelFormat type) } Image;
http://github.com/athreef/Graphics-Raylib
Graphics::Raylib Graphics::Raylib::Color
Ahmad Fatoum <athreef@cpan.org>, http://a3f.at
<athreef@cpan.org>
Copyright (C) 2017 Ahmad Fatoum
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install Graphics::Raylib, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Graphics::Raylib
CPAN shell
perl -MCPAN -e shell install Graphics::Raylib
For more information on module installation, please visit the detailed CPAN module installation guide.