refactor: ICamera interface added with view and projection matrices fields

This commit is contained in:
2026-01-26 23:48:16 +03:00
parent af6dde84fd
commit 7c9973a5e7
6 changed files with 69 additions and 38 deletions

View File

@@ -0,0 +1,17 @@
namespace Engine.Core;
/// <summary>
/// Represents a camera with view and projections matrices in the engine.
/// </summary>
public interface ICamera
{
/// <summary>
/// View <see cref="Matrix4x4"/> of the <see cref="ICamera"/>.
/// </summary>
Matrix4x4 ViewMatrix { get; }
/// <summary>
/// Projection <see cref="Matrix4x4"/> of the <see cref="ICamera"/>.
/// </summary>
Matrix4x4 ProjectionMatrix { get; }
}

View File

@@ -3,7 +3,7 @@ namespace Engine.Core;
/// <summary>
/// Represents a 2D camera in the engine.
/// </summary>
public interface ICamera2D : IBehaviour2D
public interface ICamera2D : ICamera, IBehaviour2D
{
/// <summary>
/// The zoom level of the camera.

View File

@@ -3,7 +3,7 @@ namespace Engine.Core;
/// <summary>
/// Represents a 3D camera in the engine.
/// </summary>
public interface ICamera3D : IBehaviour3D
public interface ICamera3D : ICamera, IBehaviour3D
{
/// <summary>
/// Event triggered when the near plane of the <see cref="ICamera3D"/> changes.