textures
Standard resources for textures in simulation.
Package Contents
Classes
Enumerate different map types for textures. |
|
An abstract texture for geometric models. |
|
Reference texture information for the simulators. |
- class MapType(*args, **kwds)
Bases:
enum.Enum
Enumerate different map types for textures.
“MAP2D”: Maps the texture to a 2d surface.
“CUBE”: Wraps the texture around a cube object.
“SKYBOX”: Like “cube” but maps onto the inside of an object.
- MAP2D = '2d'
- CUBE = 'cube'
- SKYBOX = 'skybox'
- class Texture
An abstract texture for geometric models.
- reference: simulation.scene.geometry.textures._texture_reference.TextureReference | None
Reference the specific type of texture. If no reference is given, the base_color will be used on the Object.
- base_color: simulation.scene._color.Color
Determines the base color of a material and its alpha value.
- primary_color: simulation.scene._color.Color
Determines the primary color of the texture.
- secondary_color: simulation.scene._color.Color
facilitates more complex textures that use two colors.
- map_type: simulation.scene.geometry.textures._map_type.MapType
Represents how the texture is mapped to an object.
- repeat: tuple[int, int]
Allows you to set how often a texture should be repeated across the x and y axis (Only for 2d maps).
- size: tuple[int, int]
Allows to set the size of a texture. The higher the size, the higher the resolution
- specular: float
Specular ranges between [0, 1].
- shininess: float
Shininess ranges between [0, 1].
- reflectance: float
Reflectance ranges between [0, 1].
- emission: float
Allows Objects to emit light [0, inf).
- class TextureReference
Bases:
abc.ABC
Reference texture information for the simulators.
- builtin: str | None
Allows to reference builtin textures of the targeted simulator.
- file: str | None
The source file of the specified texture, if custom.
- content_type: str | None
The type of the source file. The supported types depend on the simulator used. Please check the simulators documentation for supported filetypes.
- gridlayout: str | None
Specify the layout of the texture to be mapped onto an object. This depends on the simulator used. Please check the simulators documentation for supported grid layouts.
- __post_init__() None
Check for potential conflicts due to missing arguments.
- Raises:
NotImplementedError – If not sufficient arguments are given.