Add **Global Sign Distance Field** rendering (work in progress)

This commit is contained in:
Wojciech Figat
2022-03-18 16:18:00 +01:00
parent 10d09711d9
commit 8cca7f884b
18 changed files with 1109 additions and 5 deletions

View File

@@ -340,6 +340,8 @@ bool TextRender::HasContentLoaded() const
void TextRender::Draw(RenderContext& renderContext)
{
if (renderContext.View.Pass == DrawPass::GlobalSDF)
return; // TODO: Text rendering to Global SDF
if (_isDirty)
{
UpdateLayout();
@@ -478,6 +480,10 @@ void TextRender::Deserialize(DeserializeStream& stream, ISerializeModifier* modi
DESERIALIZE_MEMBER(Scale, _layoutOptions.Scale);
DESERIALIZE_MEMBER(GapScale, _layoutOptions.BaseLinesGapScale);
// [Deprecated on 07.02.2022, expires on 07.02.2024]
if (modifier->EngineBuild <= 6330)
DrawModes |= DrawPass::GlobalSDF;
_isDirty = true;
}