Skip to content

Commit

Permalink
Upgrade to Bevy 0.14
Browse files Browse the repository at this point in the history
  • Loading branch information
rparrett committed Aug 17, 2024
1 parent 22b60e2 commit ae78b3f
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 6 deletions.
9 changes: 6 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,14 @@ documentation = "https://docs.rs/bevy_generative"

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
bevy = { version = "0.13.0", default-features = false, features = ["bevy_core_pipeline", "bevy_pbr", "bevy_ui"] }
bevy = { version = "0.14.0", default-features = false, features = [
"bevy_core_pipeline",
"bevy_pbr",
"bevy_ui",
] }
colorgrad = "0.6.2"
gltf = "1.3.0"
image = "0.24.7"
image = "0.25"
noise = { version = "0.9.0", git = "https://github.com/Razaekel/noise-rs.git" }
rfd = "0.12.1"
serde = "1.0.195"
Expand All @@ -34,4 +38,3 @@ opt-level = 1

[profile.release]
lto = "thin"

4 changes: 2 additions & 2 deletions src/terrain.rs
Original file line number Diff line number Diff line change
Expand Up @@ -171,8 +171,8 @@ fn generate_terrain(
let mut indices: Vec<u32> = Vec::with_capacity(triangle_count);
let mut colors: Vec<[f32; 4]> = Vec::with_capacity(vertices_count);

let rows = terrain.size[0] * terrain.resolution + 1;
let cols = terrain.size[1] * terrain.resolution + 1;
let rows = terrain.size[0] * terrain.resolution;
let cols = terrain.size[1] * terrain.resolution;
let width = terrain.size[0] as f32 + 1.0;
let depth = terrain.size[1] as f32 + 1.0;
for row in 0..rows {
Expand Down
2 changes: 1 addition & 1 deletion src/util/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ pub fn export_asset(image_buffer: ImageBuffer<Rgba<u8>, Vec<u8>>) {
&image_buffer,
image_buffer.width(),
image_buffer.height(),
color_type,
color_type.into(),
)
.expect("Failed to write to png");

Expand Down

0 comments on commit ae78b3f

Please sign in to comment.