Add 1x1x1 slope model

This commit is contained in:
Jordan Irwin 2021-08-26 08:40:27 -07:00
parent a4d98539b0
commit c08ce7e665
5 changed files with 92 additions and 0 deletions

View File

@ -54,6 +54,17 @@ simple_models_stair_1x1x1:
<img src="textures/simple_models_sample_stair_1x1x1_map.png" />
simple_models_slope_1x1x1:
- for slope-like nodes with dimensions 1x1x1
- preview:
<img src="previews/slope_1x1x1_model.png" />
- texture map:
<img src="textures/simple_models_sample_slope_1x1x1_map.png" />
#### Tables
`smodel` is an alias of `simple_models`.
@ -90,6 +101,23 @@ simple_models.stair_1x1x1:
- mesh: "simple_models_stair_1x1x1.obj"
- box: {{-0.5, -0.5, -0.5, 0.5, 0.0, 0.5}, {-0.5, 0.0, 0.0, 0.5, 0.5, 0.5}}
- alias: simple_models.stair
simple_models.slope_1x1x1:
- fields:
- mesh: "simple_models_slope_1x1x1.obj"
- box: {
{-0.5, -0.5, 0.4, 0.5, 0.5, 0.5},
{-0.5, -0.5, 0.3, 0.5, 0.4, 0.5},
{-0.5, -0.5, 0.2, 0.5, 0.3, 0.5},
{-0.5, -0.5, 0.1, 0.5, 0.2, 0.5},
{-0.5, -0.5, 0.0, 0.5, 0.1, 0.5},
{-0.5, -0.5, -0.1, 0.5, 0.0, 0.5},
{-0.5, -0.5, -0.2, 0.5, -0.1, 0.5},
{-0.5, -0.5, -0.3, 0.5, -0.2, 0.5},
{-0.5, -0.5, -0.4, 0.5, -0.3, 0.5},
{-0.5, -0.5, -0.5, 0.5, -0.4, 0.5},
}
- alias: simple_models.slope
```
#### Helper Methods

View File

@ -73,6 +73,29 @@ simple_models = {
{-0.5, 0.0, 0.0, 0.5, 0.5, 0.5},
},
},
--- Slope
--
-- Alias: simple_models.slope
--
-- @table simple_models.slope_1x1x1
-- @tfield string mesh simple_models_slope_1x1x1.obj
-- @tfield table box
slope_1x1x1 = {
mesh = "simple_models_slope_1x1x1.obj",
box = {
{-0.5, -0.5, 0.4, 0.5, 0.5, 0.5},
{-0.5, -0.5, 0.3, 0.5, 0.4, 0.5},
{-0.5, -0.5, 0.2, 0.5, 0.3, 0.5},
{-0.5, -0.5, 0.1, 0.5, 0.2, 0.5},
{-0.5, -0.5, 0.0, 0.5, 0.1, 0.5},
{-0.5, -0.5, -0.1, 0.5, 0.0, 0.5},
{-0.5, -0.5, -0.2, 0.5, -0.1, 0.5},
{-0.5, -0.5, -0.3, 0.5, -0.2, 0.5},
{-0.5, -0.5, -0.4, 0.5, -0.3, 0.5},
{-0.5, -0.5, -0.5, 0.5, -0.4, 0.5},
},
},
}
simple_models.cube = simple_models.cube_1x2x1
@ -80,6 +103,7 @@ simple_models.panel = simple_models.panel_1x2x1
simple_models.panel_mid = simple_models.panel_mid_1x2x1
simple_models.panel_rear = simple_models.panel_rear_1x2x1
simple_models.stair = simple_models.stair_1x1x1
simple_models.slope = simple_models.slope_1x1x1
--- Global table.
--

Binary file not shown.

View File

@ -0,0 +1,40 @@
# Blender v2.93.2 OBJ File: 'simple_models_slope_1x1x1.blend'
# www.blender.org
mtllib simple_models_slope_1x1x1.mtl
o Cube
v 0.500000 -0.500000 -0.500000
v 0.500000 0.500000 0.500000
v 0.500000 -0.500000 0.500000
v -0.500000 -0.500000 -0.500000
v -0.500000 0.500000 0.500000
v -0.500000 -0.500000 0.500000
vt 0.333333 -0.000000
vt 0.333333 0.500000
vt 0.000000 0.500000
vt -0.000000 0.000000
vt 1.000000 0.500000
vt 0.666667 0.500000
vt 0.666667 0.000000
vt 1.000000 0.000000
vt 1.000000 0.500000
vt 1.000000 1.000000
vt 0.666667 0.500000
vt 0.000000 0.500000
vt 0.333333 0.500000
vt 0.000000 1.000000
vt 0.666667 -0.000000
vt 0.666667 1.000000
vt 0.333333 1.000000
vt 0.333333 0.000000
vn 0.0000 0.0000 1.0000
vn 0.0000 -1.0000 0.0000
vn -1.0000 0.0000 0.0000
vn 1.0000 0.0000 0.0000
vn 0.0000 0.7071 -0.7071
usemtl Material
s off
f 3/1/1 2/2/1 5/3/1 6/4/1
f 4/5/2 1/6/2 3/7/2 6/8/2
f 6/9/3 5/10/3 4/11/3
f 3/12/4 1/13/4 2/14/4
f 4/15/5 5/16/5 2/17/5 1/18/5

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB