Skip to content

Commit

Permalink
Add obj file that is loaded as trimesh scene
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexanderFabisch committed Jan 5, 2025
1 parent f2ebec5 commit 5a54e88
Show file tree
Hide file tree
Showing 2 changed files with 73 additions and 0 deletions.
18 changes: 18 additions & 0 deletions test/test_data/scene.mtl
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
newmtl Box1
# ambient color
Ka 1.0 0.5 0.5
# diffuse color
Kd 1.0 0.5 0.5
# specular color
Ks 0.0 0.0 0.0
# transparency, opaque in this case
d 1.0
# illumination model: highlight on
illum 2

newmtl Box2
Ka 0.5 1.0 0.5
Kd 0.5 1.0 0.5
Ks 0.0 0.0 0.0
d 1.0
illum 2
55 changes: 55 additions & 0 deletions test/test_data/scene.obj
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
mtllib scene.mtl

g box1

# vertices
v 0. 0. 0.
v 1. 0. 0.
v 0. 0. 1.
v 1. 0. 1.
v 0. 1. 0.
v 1. 1. 0.
v 0. 1. 1.
v 1. 1. 1.

usemtl Box1
# faces
f 5 8 6
f 5 7 8
f 1 3 5
f 3 7 5
f 1 2 3
f 2 4 3
f 2 6 8
f 2 8 4
f 3 4 8
f 3 8 7
f 1 5 2
f 2 5 6

g box2

# vertices
v 2. 0. 0.
v 3. 0. 0.
v 2. 0. 1.
v 3. 0. 1.
v 2. 1. 0.
v 3. 1. 0.
v 2. 1. 1.
v 3. 1. 1.

usemtl Box2
# faces
f 13 16 14
f 13 15 16
f 9 11 13
f 11 15 13
f 9 10 11
f 10 12 11
f 10 14 16
f 10 16 12
f 11 12 16
f 11 16 15
f 9 13 10
f 10 13 14

0 comments on commit 5a54e88

Please sign in to comment.