using System.Numerics; using Raylib_cs; namespace BakeryGame.Models; public class CameraRef { private Camera3D _cam; public CameraRef(Vector3 position, Vector3 target, Vector3 up, float fovy) { _cam = new Camera3D(position, target, up, fovy, 0); } /// /// Camera position /// public void SetPosition(Vector3 position) { _cam.Position = position; } /// /// Camera target it looks-at /// public void SetTarget(Vector3 target) { _cam.Target = target; } /// /// Camera up vector (rotation over its axis) /// public void SetUp(Vector3 up) { _cam.Up = up; } /// /// Camera field-of-view apperture in Y (degrees) in perspective, used as near plane width in orthographic /// public void FovY(float fovy) { _cam.FovY = fovy; } /// /// Camera type, defines projection type: CAMERA_PERSPECTIVE or CAMERA_ORTHOGRAPHIC /// public void SetProjection(CameraProjection projection) { _cam.Projection = projection; } public Camera3D GetCamera3D() => _cam; }