#ifndef EDITSCENE_CAMERA_HPP
#define EDITSCENE_CAMERA_HPP
#pragma once

#include <Ogre.h>

/**
 * Camera component - attaches an Ogre::Camera to the entity's SceneNode
 */
struct CameraComponent {
	// Camera properties
	float fovY = 45.0f;           // Vertical field of view in degrees
	float nearClip = 0.1f;        // Near clip distance
	float farClip = 1000.0f;      // Far clip distance
	float aspectRatio = 16.0f / 9.0f;  // Aspect ratio (width/height)
	
	// For orthographic camera
	bool orthographic = false;
	float orthoWidth = 10.0f;     // Width for orthographic view
	float orthoHeight = 10.0f;    // Height for orthographic view
	
	// The Ogre camera object (created by CameraSystem)
	Ogre::Camera* camera = nullptr;
	
	// For preview (optional RTT - created on demand)
	Ogre::RenderTarget* previewTarget = nullptr;
	Ogre::TexturePtr previewTexture;
	bool showPreview = false;
	int previewWidth = 400;
	int previewHeight = 300;
	
	void markDirty() { needsRebuild = true; }
	bool needsRebuild = true;
	bool needsPreviewUpdate = false;
};

#endif // EDITSCENE_CAMERA_HPP
