Graphics: Add RenderSystem and frame pipeline
This commit is contained in:
28
src/Nazara/Graphics/Components/CameraComponent.cpp
Normal file
28
src/Nazara/Graphics/Components/CameraComponent.cpp
Normal file
@@ -0,0 +1,28 @@
|
||||
// Copyright (C) 2021 Jérôme Leclercq
|
||||
// This file is part of the "Nazara Engine - Utility module"
|
||||
// For conditions of distribution and use, see copyright notice in Prerequisites.hpp
|
||||
|
||||
#include <Nazara/Graphics/Components/CameraComponent.hpp>
|
||||
#include <stdexcept>
|
||||
#include <Nazara/Graphics/Debug.hpp>
|
||||
|
||||
namespace Nz
|
||||
{
|
||||
const RenderTarget& CameraComponent::GetRenderTarget()
|
||||
{
|
||||
if (!m_renderTarget)
|
||||
throw std::runtime_error("no rendertarget set");
|
||||
|
||||
return* m_renderTarget;
|
||||
}
|
||||
|
||||
ViewerInstance& CameraComponent::GetViewerInstance()
|
||||
{
|
||||
return m_viewerInstance;
|
||||
}
|
||||
|
||||
const ViewerInstance& CameraComponent::GetViewerInstance() const
|
||||
{
|
||||
return m_viewerInstance;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user