Make game viewport authority runtime-neutral
This commit is contained in:
parent
da6ab814c8
commit
911bb72f69
45 changed files with 424 additions and 369 deletions
|
|
@ -26,7 +26,7 @@ public sealed class AetheriaUnityRenderSplatViewportSource : MonoBehaviour
|
|||
private bool renderInLateUpdate = true;
|
||||
|
||||
private float _nextRefreshTime;
|
||||
private AetheriaUnityRtsViewportDocuments _viewportDocuments;
|
||||
private AetheriaUnityGameViewportDocuments _viewportDocuments;
|
||||
private AetheriaRuntimeRenderSplatsViewportDocument _fallbackRenderSplatsViewport;
|
||||
private string _lastWarningMessage = "";
|
||||
|
||||
|
|
@ -150,19 +150,19 @@ public sealed class AetheriaUnityRenderSplatViewportSource : MonoBehaviour
|
|||
}
|
||||
|
||||
private static AetheriaRuntimeRenderSplatsViewportDocument EmptyRenderSplatsViewport(
|
||||
AetheriaRuntimeRtsViewportBounds viewport)
|
||||
AetheriaRuntimeViewportBounds viewport)
|
||||
{
|
||||
return new AetheriaRuntimeRenderSplatsViewportDocument
|
||||
{
|
||||
PublishedAtUtc = DateTimeOffset.UtcNow.ToString("O"),
|
||||
Viewport = viewport ?? new AetheriaRuntimeRtsViewportBounds()
|
||||
Viewport = viewport ?? new AetheriaRuntimeViewportBounds()
|
||||
};
|
||||
}
|
||||
|
||||
private AetheriaRuntimeRtsViewportBounds ResolveViewportBounds()
|
||||
private AetheriaRuntimeViewportBounds ResolveViewportBounds()
|
||||
{
|
||||
var halfSize = size * 0.5f;
|
||||
return new AetheriaRuntimeRtsViewportBounds
|
||||
return new AetheriaRuntimeViewportBounds
|
||||
{
|
||||
MinX = position.x - halfSize.x,
|
||||
MinY = position.y - halfSize.y,
|
||||
|
|
|
|||
Loading…
Reference in a new issue