Texture(ID)

base classes — bpy_struct, ID

subclasses — BlendTexture, CloudsTexture, DistortedNoiseTexture, ImageTexture, MagicTexture, MarbleTexture, MusgraveTexture, NoiseTexture, StucciTexture, VoronoiTexture, WoodTexture

class bpy.types.Texture(ID)

Texture data-block used by materials, lights, worlds and brushes

animation_data

Animation data for this data-block (readonly)

Type:

AnimData

color_ramp

(readonly)

Type:

ColorRamp

contrast

Adjust the contrast of the texture (in [0, 5], default 1.0)

Type:

float

factor_blue

(in [0, 2], default 1.0)

Type:

float

factor_green

(in [0, 2], default 1.0)

Type:

float

factor_red

(in [0, 2], default 1.0)

Type:

float

intensity

Adjust the brightness of the texture (in [0, 2], default 1.0)

Type:

float

node_tree

Node tree for node-based textures (readonly)

Type:

NodeTree

saturation

Adjust the saturation of colors in the texture (in [0, 2], default 1.0)

Type:

float

type

(default 'IMAGE')

Type:

Literal[Texture Type Items]

use_clamp

Set negative texture RGB and intensity values to zero, for some uses like displacement this option can be disabled to get the full range (default False)

Type:

bool

use_color_ramp

Map the texture intensity to the color ramp. Note that the alpha value is used for image textures, enable “Calculate Alpha” for images without an alpha channel. (default False)

Type:

bool

use_nodes

Make this a node-based texture (default False)

Type:

bool

use_preview_alpha

Show Alpha in Preview Render (default False)

Type:

bool

users_material

Materials that use this texture

Type:

tuple[Material, …]

Note

Takes O(len(bpy.data.materials) * len(material.texture_slots)) time.

(readonly)

users_object_modifier

Object modifiers that use this texture

Type:

tuple[Object, …]

Note

Takes O(len(bpy.data.objects) * len(obj.modifiers)) time.

(readonly)

evaluate(value)

Evaluate the texture at the given coordinate and returns the result

Parameters:

value (mathutils.Vector) – The coordinates (x,y,z) of the texture, in case of a 3D texture, the z value is the slice of the texture that is evaluated. For 2D textures such as images, the z value is ignored., (array of 3 items, in [-inf, inf])

Returns:

The result of the texture where (x,y,z,w) are (red, green, blue, intensity). For grayscale textures, often intensity only will be used., (array of 4 items, in [-inf, inf])

Return type:

mathutils.Vector

classmethod bl_rna_get_subclass(id, default=None, /)
Parameters:

id (str) – The RNA type identifier.

Returns:

The RNA type or default when not found.

Return type:

bpy.types.Struct

classmethod bl_rna_get_subclass_py(id, default=None, /)
Parameters:

id (str) – The RNA type identifier.

Returns:

The class or default when not found.

Return type:

type

Inherited Properties

Inherited Functions

References