Skip to content

Commit

Permalink
Clippy fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
djeedai committed Aug 5, 2024
1 parent e5238d3 commit bf404da
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 19 deletions.
21 changes: 11 additions & 10 deletions src/asset.rs
Original file line number Diff line number Diff line change
Expand Up @@ -259,17 +259,18 @@ impl EffectAsset {
///
/// The effect assets requires 2 essential pieces:
/// - The capacities of the effect, which together represent the maximum
/// number of particles which can be stored and simulated at the same time
/// for each group. There will be one capacity value per group; thus, the
/// `capacities` array also specifies the number of groups. All capacities
/// must be non-zero and should be the smallest possible values which allow
/// you to author the effect. These values directly impact the GPU memory
/// consumption of the effect, which will allocate some buffers to store
/// that many particles for as long as the effect exists. The capacities of
/// an effect are immutable. See also [`capacities()`] for more details.
/// number of particles which can be stored and simulated at the same time
/// for each group. There will be one capacity value per group; thus, the
/// `capacities` array also specifies the number of groups. All capacities
/// must be non-zero and should be the smallest possible values which
/// allow you to author the effect. These values directly impact the GPU
/// memory consumption of the effect, which will allocate some buffers to
/// store that many particles for as long as the effect exists. The
/// capacities of an effect are immutable. See also [`capacities()`] for
/// more details.
/// - The [`Spawner`], which defines when particles are emitted. All
/// spawners spawn particles into group 0. (To add particles to other
/// groups, use the [`crate::modifier::clone::CloneModifier`].)
/// spawners spawn particles into group 0. (To add particles to other
/// groups, use the [`crate::modifier::clone::CloneModifier`].)
///
/// Additionally, if any modifier added to this effect uses some [`Expr`] to
/// customize its behavior, then those [`Expr`] are stored into a [`Module`]
Expand Down
12 changes: 6 additions & 6 deletions src/modifier/position.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,12 +39,12 @@ pub struct SetPositionCircleModifier {
/// Note the particular interpretation of the dimension for this shape,
/// which unlike other shapes is a 2D one to begin with:
/// - [`ShapeDimension::Volume`] randomly position the particle anywhere on
/// the "volume" of the shape, which here is understood to be the 2D disc
/// surface including its origin (`dist <= r`).
/// - [`ShapeDimension::Surface`] randomly position the particle
/// anywhere on the "surface" of the shape, which here is understood to
/// be the perimeter circle, the set of points at a distance from the center
/// exactly equal to the radius (`dist == r`).
/// the "volume" of the shape, which here is understood to be the 2D disc
/// surface including its origin (`dist <= r`).
/// - [`ShapeDimension::Surface`] randomly position the particle anywhere on
/// the "surface" of the shape, which here is understood to be the
/// perimeter circle, the set of points at a distance from the center
/// exactly equal to the radius (`dist == r`).
pub dimension: ShapeDimension,
}

Expand Down
6 changes: 3 additions & 3 deletions src/render/buffer_table.rs
Original file line number Diff line number Diff line change
Expand Up @@ -73,9 +73,9 @@ impl AllocatedBuffer {
///
/// - During the [`RenderStage::Prepare`] stage, call
/// [`clear_previous_frame_resizes()`] to clear any stale buffer from the
/// previous frame. Then insert new rows with [`insert()`] and if you made
/// changes call [`allocate_gpu()`] at the end to allocate any new buffer
/// needed.
/// previous frame. Then insert new rows with [`insert()`] and if you made
/// changes call [`allocate_gpu()`] at the end to allocate any new buffer
/// needed.
/// - During the [`RenderStage::Render`] stage, call [`write_buffer()`] from a
/// command encoder before using any row, to perform any buffer resize copy
/// pending.
Expand Down

0 comments on commit bf404da

Please sign in to comment.