Files
FlaxEngine/Source/Engine/Renderer/ProbesRenderer.h
2025-07-03 10:18:51 +02:00

45 lines
1.2 KiB
C++

// Copyright (c) Wojciech Figat. All rights reserved.
#pragma once
#include "Engine/Core/Delegate.h"
#include "Engine/Core/Types/TimeSpan.h"
class Actor;
/// <summary>
/// Probes rendering service
/// </summary>
class ProbesRenderer
{
public:
/// <summary>
/// Time delay between probe updates. Can be used to improve performance by rendering probes less often.
/// </summary>
static TimeSpan UpdateDelay;
/// <summary>
/// Timeout after the last probe rendered when resources used to render it should be released.
/// </summary>
static TimeSpan ReleaseTimeout;
static Delegate<Actor*> OnRegisterBake;
static Delegate<Actor*> OnFinishBake;
public:
/// <summary>
/// Register probe to baking service.
/// </summary>
/// <param name="probe">Probe to bake</param>
/// <param name="timeout">Timeout in seconds left to bake it.</param>
static void Bake(class EnvironmentProbe* probe, float timeout = 0);
/// <summary>
/// Register probe to baking service.
/// </summary>
/// <param name="probe">Probe to bake</param>
/// <param name="timeout">Timeout in seconds left to bake it.</param>
static void Bake(class SkyLight* probe, float timeout = 0);
};