TextureBuilder WithScreenMultiSample()

book_4_sparkGenerated
code_blocksInput

Description

The WithScreenMultiSample method configures the texture to use the same multisampling settings as the screen or framebuffer. This is useful when you want the texture to match the display's multisampling settings, ensuring consistency in rendering quality and performance.

Usage

To use the WithScreenMultiSample method, call it on an instance of TextureBuilder when setting up your texture. This method is part of a fluent interface, allowing you to chain multiple configuration methods together.

Example

// Example of using WithScreenMultiSample
TextureBuilder textureBuilder = new TextureBuilder();
Texture texture = textureBuilder
    .WithSize(1024, 768)
    .WithScreenMultiSample()
    .Create("MyTexture", false, data, data.Length);