Crate bevy_sprite[−][src]
Modules
Utilities for detecting if and on which side two axis-aligned bounding boxes (AABB) collide.
Structs
A 2d material that renders 2d meshes with a texture tinted by a uniform color
The GPU representation of the uniform data of a ColorMaterial
.
The GPU representation of a ColorMaterial
.
Adds the necessary ECS resources and render logic to enable rendering entities using the given SpecializedMaterial2d
asset type (which includes Material2d
types).
A component bundle for entities with a Mesh2dHandle
and a SpecializedMaterial2d
.
Component for rendering with meshes in the 2d pipeline, usually with a 2d material such as ColorMaterial
.
A rectangle defined by two points. There is no defined origin, so 0,0 could be anywhere (top-left, bottom-left, etc)
A Bundle of components for drawing a single sprite from a sprite sheet (also referred
to as a TextureAtlas
)
An atlas containing multiple textures (like a spritesheet or a tilemap). Example usage animating sprite. Example usage loading sprite sheet.
A builder which is used to create a texture atlas from many individual sprites.
Enums
Constants
Traits
Materials are used alongside Material2dPlugin
and MaterialMesh2dBundle
to spawn entities that are rendered with a specific Material2d
type. They serve as an easy to use high level
way to render Mesh2dHandle
entities with custom shader logic. For materials that can specialize their RenderPipelineDescriptor
based on specific material values, see SpecializedMaterial2d
. Material2d
automatically implements SpecializedMaterial2d
and can be used anywhere that type is used (such as Material2dPlugin
).
Materials are used alongside Material2dPlugin
and MaterialMesh2dBundle
to spawn entities that are rendered with a specific SpecializedMaterial2d
type. They serve as an easy to use high level
way to render Mesh2dHandle
entities with custom shader logic. SpecializedMaterial2d
s use their SpecializedMaterial2d::Key
to customize their RenderPipelineDescriptor
based on specific material values. The slightly simpler Material2d
trait
should be used for materials that do not need specialization. Material2d
types automatically implement SpecializedMaterial2d
.
Functions
Type Definitions
A component bundle for entities with a Mesh2dHandle
and a ColorMaterial
.