public sealed struct Sandbox.TextureBuilder
Methods
Showing 23 methods
public Sandbox.Texture Create(string name = null, bool anonymous = True, System.ReadOnlySpan`1<byte> data = null, int dataLength = 0)
Parameters
name: Default: nullanonymous: Default: Truedata: Default: nulldataLength: Default: 0
public Sandbox.TextureBuilder WithDepth(int depth)
public Sandbox.TextureBuilder WithDepthFormat()
Uses the same depth format as what the screen/framebuffer uses.
public Sandbox.TextureBuilder WithDynamicUsage()
Provides a hint to the GPU that this texture will be updated regularly. (almost every frame)
public Sandbox.TextureBuilder WithFormat(Sandbox.ImageFormat format)
The internal texture format to use.
Parameters
format: Texture format
public Sandbox.TextureBuilder WithGPUOnlyUsage()
Specify the texture to ONLY be used on the GPU on not allow CPU access.
public Sandbox.TextureBuilder WithHeight(int height)
public Sandbox.TextureBuilder WithInitialColor(Color color)
Once the texture is created it will be cleared to this color
public Sandbox.TextureBuilder WithMips(System.Nullable`1<int> mips = null)
Parameters
mips: Default: null
public Sandbox.TextureBuilder WithMSAA(Sandbox.MultisampleAmount amount)
public Sandbox.TextureBuilder WithMultiSample16X()
Sets the texture to use 16x multisampling.
public Sandbox.TextureBuilder WithMultiSample2X()
Sets the texture to use 2x multisampling.
public Sandbox.TextureBuilder WithMultiSample4X()
Sets the texture to use 4x multisampling.
public Sandbox.TextureBuilder WithMultiSample6X()
Sets the texture to use 6x multisampling.
public Sandbox.TextureBuilder WithMultiSample8X()
Sets the texture to use 8x multisampling.
public Sandbox.TextureBuilder WithScreenFormat()
Sets the internal texture format to use the same format as the screen/frame buffer.
public Sandbox.TextureBuilder WithScreenMultiSample()
Sets the texture to use the same multisampling as whatever the screen/framebuffer uses
public Sandbox.TextureBuilder WithSemiStaticUsage()
Provides a hint to the GPU that this texture will only be updated sometimes.
public Sandbox.TextureBuilder WithStaticUsage()
Provides a hint to the GPU that this texture will not be modified.
public Sandbox.TextureBuilder WithUAVBinding(bool uav = True)
Support binding the texture as a Unordered Access View in a compute or pixel shader. This is required for binding a texture within a compute shader.
Parameters
uav: Default: True
public Sandbox.TextureBuilder WithWidth(int width)
No results match this filter.
Metadata
| Field | Value |
|---|---|
| Namespace | Sandbox |
| Type | class |
| Assembly | Sandbox.Engine |
| Doc ID | T:Sandbox.TextureBuilder |