Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Primitive Shapes #12

Merged
merged 59 commits into from
Dec 12, 2022
Merged
Changes from 1 commit
Commits
Show all changes
59 commits
Select commit Hold shift + click to select a range
6a67443
Create geometric-primitives.md
aevyrie Apr 21, 2021
3f4c7e0
Correct typo
aevyrie Apr 21, 2021
fa1fc1c
Adding details
aevyrie Apr 22, 2021
7f5f21f
Incremental updates
aevyrie Apr 24, 2021
9a890e7
Update rfcs/geometric-primitives.md
aevyrie Apr 24, 2021
175b8a0
Update rfcs/geometric-primitives.md
aevyrie Apr 24, 2021
b43acde
Update rfcs/geometric-primitives.md
aevyrie Apr 24, 2021
3533994
Apply suggestions from code review
aevyrie Apr 24, 2021
68f5485
Update all the things
aevyrie Apr 30, 2021
08565cc
Merge branch 'patch-1' of https://github.com/aevyrie/rfcs into patch-1
aevyrie Apr 30, 2021
66d8c9d
Add meshing section.
aevyrie Apr 30, 2021
ceac06d
Added plane
aevyrie Apr 30, 2021
88af32e
Add primitives and use demonstration
aevyrie May 1, 2021
e6a7275
Update rfcs/geometric-primitives.md
aevyrie May 3, 2021
f8c8fbe
Update rfcs/geometric-primitives.md
aevyrie May 3, 2021
6c9cbfd
Update rfcs/geometric-primitives.md
aevyrie May 7, 2021
da6871e
wip updates
aevyrie May 12, 2021
47ea3b6
Update table and rename
aevyrie May 17, 2021
5e84667
Rewrite all the things.
aevyrie May 25, 2021
f663bd1
Rename primitive-shapes.md to 12-primitive-shapes.md
aevyrie May 25, 2021
cef33e9
Update 12-primitive-shapes.md
aevyrie May 25, 2021
9dd6b67
Update 12-primitive-shapes.md
aevyrie May 25, 2021
b67f30e
Update 12-primitive-shapes.md
aevyrie May 25, 2021
47bcc26
Update 12-primitive-shapes.md
aevyrie May 25, 2021
7d58f91
Correct Mat3 -> Mat2
aevyrie May 25, 2021
a2aa8cf
Fix AABB error in table
aevyrie May 25, 2021
bd9d5e2
Update 12-primitive-shapes.md
aevyrie May 26, 2021
0f25cfe
Typo
aevyrie May 26, 2021
b3fcd7d
Add notes to bounding/collision
aevyrie Jun 1, 2021
cede313
Clarify traits as reference only
aevyrie Jun 1, 2021
5e381f6
improve bounding/collision discussion
aevyrie Jun 1, 2021
019047e
Add notes about Parry types
aevyrie Jun 3, 2021
24dbd0b
Update 12-primitive-shapes.md
aevyrie Jul 26, 2021
9ef4d2e
Merge branch 'bevyengine:main' into patch-1
aevyrie Oct 10, 2021
f37352e
Fix markdown lint violations
Weibye Oct 26, 2021
c50b330
Fixing typo
Weibye Oct 27, 2021
bc99e5b
Merge pull request #1 from Weibye/primitive-shapes
aevyrie Dec 8, 2021
e164fa5
Merge pull request #3 from Weibye/fix-typo
aevyrie Dec 8, 2021
cc192cb
Explicitly naming x2d or x3d where it makes sense
Weibye Oct 26, 2021
2ff5978
Rename Box2d to Rectangle
Weibye Oct 26, 2021
e88a42a
Removing unresolved question
Weibye Oct 26, 2021
2a33756
Fix typo
Weibye Nov 6, 2021
5222ee8
Moving 2d shapes ontop
Weibye Nov 6, 2021
fbcc8da
Moving 2d shapes before 3d shapes
Weibye Nov 6, 2021
bafe5a5
Adding descriptions to table
Weibye Nov 6, 2021
3494f3a
Collecting and rewording 2d / 3d section
Weibye Nov 6, 2021
2ac6358
Update rfcs/12-primitive-shapes.md
Weibye Nov 6, 2021
5ec59ee
2d before 3d consistency
Weibye Dec 13, 2021
550e522
Merge pull request #2 from Weibye/name-consolidation
aevyrie Jan 3, 2022
46ae46c
Removing point as a primitive type
Weibye Dec 13, 2021
7a5e2c1
Remove angle as a component
Weibye Jan 23, 2022
ca533b1
merging 'bounding and collision' with 'where are the transforms'
Weibye Jan 23, 2022
957bfca
Merge pull request #4 from Weibye/dev/remove-point
aevyrie Jan 23, 2022
dc58497
Merge pull request #5 from Weibye/remove-angle
aevyrie Jan 23, 2022
be92586
Merge pull request #6 from Weibye/where-transforms
aevyrie Jan 23, 2022
7981ae8
Update rfcs/12-primitive-shapes.md
aevyrie Jan 23, 2022
f632b2b
Removing torus and placing non-convex in future work
Weibye Apr 24, 2022
69e3ab0
Merge pull request #7 from Weibye/non-convex
aevyrie Apr 25, 2022
03eaf5f
Update rfcs/12-primitive-shapes.md
aevyrie Aug 26, 2022
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
24 changes: 20 additions & 4 deletions rfcs/geometric-primitives.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Geometric primitives are lightweight representations of geometry that describe t

```rust
pub struct Circle {
origin: Vec2
origin: Point,
radius: f32,
}
```
Expand All @@ -38,10 +38,24 @@ These types only exist in 2d space: their dimensions and location are only defin

- `Point`: type alias of Vec2
- `Direction`: Vec2 that is guaranteed to be normalized through its getter/setter
- `Axis`: (point: Point, normal: Vec2) axis with infinite length

#### Axis

Line with infinite length on the x/y plane.


```rust
struct Axis { point: Point, normal: Direction }
```

#### Line

- `Line`: (start: Point, end: Point) line bounded by two points
- `Arc`: (start: Point, end: Point, radius_origin: Point) segment of a circle
- `Circle`

```rust
struct Circle` { origin: Point, radius: f32 }
```
- `Triangle`
- `AABBCentered` origin and half-extents
- `AabbExtents` minimum and maximum extents
Expand All @@ -53,8 +67,10 @@ These types are fully defined in 3d space.

- `Point`: type alias of Vec3
- `Direction`: Vec3 that is guaranteed to be normalized through its getter/setter
- `Axis`
- `Axis`
aevyrie marked this conversation as resolved.
Show resolved Hide resolved
- `Line`
- `Plane`
- `Quad`
- `Sphere`
- `Cylinder`
- `Capsule`
Expand Down