render thread
This commit is contained in:
@@ -294,6 +294,12 @@ void OpenGLComposite::renderEffect()
|
|||||||
if (mRuntimeUpdateController)
|
if (mRuntimeUpdateController)
|
||||||
mRuntimeUpdateController->ProcessRuntimeWork();
|
mRuntimeUpdateController->ProcessRuntimeWork();
|
||||||
|
|
||||||
|
const RenderFrameInput frameInput = BuildRenderFrameInput();
|
||||||
|
RenderFrame(frameInput);
|
||||||
|
}
|
||||||
|
|
||||||
|
RenderFrameInput OpenGLComposite::BuildRenderFrameInput() const
|
||||||
|
{
|
||||||
RenderFrameInput frameInput;
|
RenderFrameInput frameInput;
|
||||||
frameInput.useCommittedLayerStates = mRuntimeCoordinator && mRuntimeCoordinator->UseCommittedLayerStates();
|
frameInput.useCommittedLayerStates = mRuntimeCoordinator && mRuntimeCoordinator->UseCommittedLayerStates();
|
||||||
frameInput.hasInputSource = mVideoBackend->HasInputSource();
|
frameInput.hasInputSource = mVideoBackend->HasInputSource();
|
||||||
@@ -305,7 +311,11 @@ void OpenGLComposite::renderEffect()
|
|||||||
frameInput.inputPixelFormat = mVideoBackend->InputPixelFormat();
|
frameInput.inputPixelFormat = mVideoBackend->InputPixelFormat();
|
||||||
frameInput.historyCap = mRuntimeStore ? mRuntimeStore->GetConfiguredMaxTemporalHistoryFrames() : 0;
|
frameInput.historyCap = mRuntimeStore ? mRuntimeStore->GetConfiguredMaxTemporalHistoryFrames() : 0;
|
||||||
frameInput.oscSmoothing = mRuntimeStore ? mRuntimeStore->GetConfiguredOscSmoothing() : 0.0;
|
frameInput.oscSmoothing = mRuntimeStore ? mRuntimeStore->GetConfiguredOscSmoothing() : 0.0;
|
||||||
|
return frameInput;
|
||||||
|
}
|
||||||
|
|
||||||
|
void OpenGLComposite::RenderFrame(const RenderFrameInput& frameInput)
|
||||||
|
{
|
||||||
RenderFrameState frameState;
|
RenderFrameState frameState;
|
||||||
if (mRuntimeServices)
|
if (mRuntimeServices)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -12,6 +12,7 @@
|
|||||||
#include <comutil.h>
|
#include <comutil.h>
|
||||||
|
|
||||||
#include "GLExtensions.h"
|
#include "GLExtensions.h"
|
||||||
|
#include "RenderFrameState.h"
|
||||||
|
|
||||||
#include <functional>
|
#include <functional>
|
||||||
#include <atomic>
|
#include <atomic>
|
||||||
@@ -87,6 +88,8 @@ private:
|
|||||||
|
|
||||||
bool InitOpenGLState();
|
bool InitOpenGLState();
|
||||||
void renderEffect();
|
void renderEffect();
|
||||||
|
RenderFrameInput BuildRenderFrameInput() const;
|
||||||
|
void RenderFrame(const RenderFrameInput& frameInput);
|
||||||
void ProcessScreenshotRequest();
|
void ProcessScreenshotRequest();
|
||||||
std::filesystem::path BuildScreenshotPath() const;
|
std::filesystem::path BuildScreenshotPath() const;
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user