TextureCubeBuilder WithMips( int mips )

book_4_sparkGenerated
code_blocksInput

Description

The WithMips method is a member of the TextureCubeBuilder class in the Sandbox namespace. This method allows you to specify the number of mipmap levels for a texture cube being built. Mipmaps are used to create different levels of detail for a texture, which can improve performance and visual quality when rendering textures at various distances.

Usage

To use the WithMips method, call it on an instance of TextureCubeBuilder and pass the desired number of mipmap levels as an integer parameter. This method returns the TextureCubeBuilder instance, allowing for method chaining.

Example

// Example of using WithMips method
TextureCubeBuilder builder = new TextureCubeBuilder();
builder.WithMips(4); // Set the texture to have 4 mipmap levels
Texture texture = builder.Finish(); // Finalize and create the texture