From 203d0b4aaeced1247997810674686d78294a2e06 Mon Sep 17 00:00:00 2001 From: NiseVoid Date: Tue, 28 Jan 2025 06:29:05 +0100 Subject: [PATCH] Move bounding_2d example to math folder (#17523) # Objective The bounding_2d example was originally placed in 2d_rendering because there was no folder for bounding or math, but now that this folder exist it makes no sense for it to be here. ## Solution Move the example ## Testing I ran the example --- Cargo.toml | 6 +++--- examples/README.md | 2 +- examples/{2d => math}/bounding_2d.rs | 0 3 files changed, 4 insertions(+), 4 deletions(-) rename examples/{2d => math}/bounding_2d.rs (100%) diff --git a/Cargo.toml b/Cargo.toml index 7383747e7f..8c2543542b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -778,13 +778,13 @@ wasm = true [[example]] name = "bounding_2d" -path = "examples/2d/bounding_2d.rs" +path = "examples/math/bounding_2d.rs" doc-scrape-examples = true [package.metadata.example.bounding_2d] -name = "2D Bounding Volume Intersections" +name = "Bounding Volume Intersections (2D)" description = "Showcases bounding volumes and intersection tests" -category = "2D Rendering" +category = "Math" wasm = true [[example]] diff --git a/examples/README.md b/examples/README.md index 858d5b3f59..9ff424a1d2 100644 --- a/examples/README.md +++ b/examples/README.md @@ -103,7 +103,6 @@ Example | Description Example | Description --- | --- [2D Bloom](../examples/2d/bloom_2d.rs) | Illustrates bloom post-processing in 2d -[2D Bounding Volume Intersections](../examples/2d/bounding_2d.rs) | Showcases bounding volumes and intersection tests [2D Rotation](../examples/2d/rotation.rs) | Demonstrates rotating entities in 2D with quaternions [2D Shapes](../examples/2d/2d_shapes.rs) | Renders simple 2D primitive shapes like circles and polygons [2D Viewport To World](../examples/2d/2d_viewport_to_world.rs) | Demonstrates how to use the `Camera::viewport_to_world_2d` method @@ -372,6 +371,7 @@ Example | Description Example | Description --- | --- +[Bounding Volume Intersections (2D)](../examples/math/bounding_2d.rs) | Showcases bounding volumes and intersection tests [Cubic Splines](../examples/math/cubic_splines.rs) | Exhibits different modes of constructing cubic curves using splines [Custom Primitives](../examples/math/custom_primitives.rs) | Demonstrates how to add custom primitives and useful traits for them. [Random Sampling](../examples/math/random_sampling.rs) | Demonstrates how to sample random points from mathematical primitives diff --git a/examples/2d/bounding_2d.rs b/examples/math/bounding_2d.rs similarity index 100% rename from examples/2d/bounding_2d.rs rename to examples/math/bounding_2d.rs