Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions crates/bevy_sprite/src/texture_atlas.rs
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,8 @@ impl TextureAtlas {
}

/// Generate a `TextureAtlas` by splitting a texture into a grid where each
/// `tile_size` by `tile_size` grid-cell is one of the textures in the atlas
/// `tile_size` by `tile_size` grid-cell is one of the textures in the
/// atlas. Resulting `TextureAtlas` is indexed left to right, top to bottom.
pub fn from_grid(
texture: Handle<Image>,
tile_size: Vec2,
Expand All @@ -81,7 +82,8 @@ impl TextureAtlas {
/// Generate a `TextureAtlas` by splitting a texture into a grid where each
/// `tile_size` by `tile_size` grid-cell is one of the textures in the
/// atlas. Grid cells are separated by some `padding`, and the grid starts
/// at `offset` pixels from the top left corner.
/// at `offset` pixels from the top left corner. Resulting `TextureAtlas` is
/// indexed left to right, top to bottom.
pub fn from_grid_with_padding(
texture: Handle<Image>,
tile_size: Vec2,
Expand Down