mirror of
https://github.com/hannobraun/Fornjot
synced 2025-05-04 18:08:26 +00:00
Inline redundant variable
This commit is contained in:
parent
d344880c75
commit
552bdc4c96
@ -1,21 +1,6 @@
|
||||
use crate::mesh::Mesh;
|
||||
|
||||
pub fn model() -> anyhow::Result<Mesh> {
|
||||
let triangles = vec![
|
||||
[0, 4, 6], // left
|
||||
[0, 6, 2],
|
||||
[1, 3, 7], // right
|
||||
[1, 7, 5],
|
||||
[0, 1, 5], // front
|
||||
[0, 5, 4],
|
||||
[2, 7, 3], // back
|
||||
[2, 6, 7],
|
||||
[0, 2, 1], // bottom
|
||||
[1, 2, 3],
|
||||
[4, 5, 7], // top
|
||||
[4, 7, 6],
|
||||
];
|
||||
|
||||
Ok(Mesh {
|
||||
vertices: vec![
|
||||
[-0.5, -0.5, -0.5], // 0
|
||||
@ -27,6 +12,19 @@ pub fn model() -> anyhow::Result<Mesh> {
|
||||
[-0.5, 0.5, 0.5], // 6
|
||||
[0.5, 0.5, 0.5], // 7
|
||||
],
|
||||
triangles,
|
||||
triangles: vec![
|
||||
[0, 4, 6], // left
|
||||
[0, 6, 2],
|
||||
[1, 3, 7], // right
|
||||
[1, 7, 5],
|
||||
[0, 1, 5], // front
|
||||
[0, 5, 4],
|
||||
[2, 7, 3], // back
|
||||
[2, 6, 7],
|
||||
[0, 2, 1], // bottom
|
||||
[1, 2, 3],
|
||||
[4, 5, 7], // top
|
||||
[4, 7, 6],
|
||||
],
|
||||
})
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user