Texture for 2D and 3D.
A texture works by registering an image in the video hardware, which then can be used in 3D models or 2D [Sprite] or GUI [Control]. Textures are often created by loading them from a file. See [method @GDScript.load].
Returns the texture height.
Returns the texture size.
Returns the texture width.
- The texture's flags.
Default flags. [constant FLAG_MIPMAPS], [constant FLAG_REPEAT] and [constant FLAG_FILTER] are enabled.
Generates mipmaps, which are smaller versions of the same texture to use when zoomed out, keeping the aspect ratio.
Repeats the texture (instead of clamp to edge).
Uses a magnifying filter, to enable smooth zooming in of the texture.
Uses anisotropic mipmap filtering. Generates smaller versions of the same texture with different aspect ratios. This results in better-looking textures when viewed from oblique angles.
Converts the texture to the sRGB color space.
Repeats the texture with alternate sections mirrored.
Texture is a video surface.