1 #ifndef RAYLIB_CPP_CAMERA_HPP_ 2 #define RAYLIB_CPP_CAMERA_HPP_ 12 #include "Vector2.hpp" 21 rotation = rotationValue;
25 inline void set(const ::Camera2D& camera) {
26 offset = camera.offset;
27 target = camera.target;
28 rotation = camera.rotation;
33 offset = camera.offset;
34 target = camera.target;
35 rotation = camera.rotation;
50 GETTERSETTER(
float,Rotation,rotation)
51 GETTERSETTER(
float,Zoom,zoom)
64 return ::GetCameraMatrix2D(*
this);
67 return ::GetWorldToScreen2D(position, *
this);
70 return ::GetScreenToWorld2D(position, *
this);
Vector2 GetWorldToScreen2D(Vector2 position)
Camera2D & operator=(const Camera2D &camera)
Provides all the classes associated with raylib-cpp.
Camera2D(::Vector2 offsetValue, ::Vector2 targetValue, float rotationValue=0, float zoomValue=1)
Vector2 GetScreenToWorld2D(Vector2 position)