diff --git a/samples/ComputeSharp.SwapChain/Program.cs b/samples/ComputeSharp.SwapChain/Program.cs index 3e54f1ef..29381a57 100644 --- a/samples/ComputeSharp.SwapChain/Program.cs +++ b/samples/ComputeSharp.SwapChain/Program.cs @@ -11,7 +11,7 @@ class Program /// /// A texture for \Textures\RustyMetal.png. /// - private static readonly IReadOnlyNormalizedTexture2D RustyMetal = LoadTexture(); + private static readonly Lazy> RustyMetal = new(static () => LoadTexture()); /// /// The mapping of available samples to choose from. @@ -28,7 +28,8 @@ class Program (nameof(ProteanClouds), new SwapChainApplication(static time => new((float)time.TotalSeconds))), (nameof(ExtrudedTruchetPattern), new SwapChainApplication(static time => new((float)time.TotalSeconds))), (nameof(PyramidPattern), new SwapChainApplication(static time => new((float)time.TotalSeconds))), - (nameof(TriangleGridContouring), new SwapChainApplication(static time => new((float)time.TotalSeconds))) + (nameof(TriangleGridContouring), new SwapChainApplication(static time => new((float)time.TotalSeconds))), + (nameof(ContouredLayers), new SwapChainApplication(static time => new((float)time.TotalSeconds, RustyMetal.Value))) }; static void Main()