Browse Source

Resync .obj models! gitignore was ignoring them!

pull/2073/head
Ray 3 years ago
parent
commit
7763ccd8ad
16 changed files with 29501 additions and 5 deletions
  1. +1
    -0
      .gitignore
  2. +5
    -5
      examples/models/models_loading.c
  3. +1725
    -0
      examples/models/resources/models/obj/bridge.obj
  4. BIN
      examples/models/resources/models/obj/bridge_diffuse.png
  5. +12919
    -0
      examples/models/resources/models/obj/castle.obj
  6. BIN
      examples/models/resources/models/obj/castle_diffuse.png
  7. +68
    -0
      examples/models/resources/models/obj/cube.obj
  8. BIN
      examples/models/resources/models/obj/cube_diffuse.png
  9. +4564
    -0
      examples/models/resources/models/obj/house.obj
  10. BIN
      examples/models/resources/models/obj/house_diffuse.png
  11. +7301
    -0
      examples/models/resources/models/obj/market.obj
  12. BIN
      examples/models/resources/models/obj/market_diffuse.png
  13. +1888
    -0
      examples/models/resources/models/obj/turret.obj
  14. BIN
      examples/models/resources/models/obj/turret_diffuse.png
  15. +1030
    -0
      examples/models/resources/models/obj/well.obj
  16. BIN
      examples/models/resources/models/obj/well_diffuse.png

+ 1
- 0
.gitignore View File

@ -45,6 +45,7 @@ ipch/
*.db
*.opendb
packages/
!examples/models/resources/models/obj/
# Ignore compiled binaries
*.o

+ 5
- 5
examples/models/models_loading.c View File

@ -39,13 +39,13 @@ int main(void)
camera.fovy = 45.0f; // Camera field-of-view Y
camera.projection = CAMERA_PERSPECTIVE; // Camera mode type
Model model = LoadModel("resources/models/castle.obj"); // Load model
Texture2D texture = LoadTexture("resources/models/castle_diffuse.png"); // Load model texture
model.materials[0].maps[MATERIAL_MAP_DIFFUSE].texture = texture; // Set map diffuse texture
Model model = LoadModel("resources/models/obj/castle.obj"); // Load model
Texture2D texture = LoadTexture("resources/models/obj/castle_diffuse.png"); // Load model texture
model.materials[0].maps[MATERIAL_MAP_DIFFUSE].texture = texture; // Set map diffuse texture
Vector3 position = { 0.0f, 0.0f, 0.0f }; // Set model position
Vector3 position = { 0.0f, 0.0f, 0.0f }; // Set model position
BoundingBox bounds = GetMeshBoundingBox(model.meshes[0]); // Set model bounds
BoundingBox bounds = GetMeshBoundingBox(model.meshes[0]); // Set model bounds
// NOTE: bounds are calculated from the original size of the model,
// if model is scaled on drawing, bounds must be also scaled

+ 1725
- 0
examples/models/resources/models/obj/bridge.obj
File diff suppressed because it is too large
View File


BIN
examples/models/resources/models/obj/bridge_diffuse.png View File

Before After
Width: 1024  |  Height: 1024  |  Size: 311 KiB

+ 12919
- 0
examples/models/resources/models/obj/castle.obj
File diff suppressed because it is too large
View File


BIN
examples/models/resources/models/obj/castle_diffuse.png View File

Before After
Width: 1024  |  Height: 1024  |  Size: 434 KiB

+ 68
- 0
examples/models/resources/models/obj/cube.obj View File

@ -0,0 +1,68 @@
# reference material
#mtllib cube.mtl
# object box
# vertex (XZY)
v 5.5 0 1.5
v 8.5 0 1.5
v 5.5 0 -1.5
v 8.5 0 -1.5
v 5.5 3 1.5
v 8.5 3 1.5
v 5.5 3 -1.5
v 8.5 3 -1.5
# normals (XYZ)
vn 0 -1 0
vn 0 1 0
vn 0 0 1
vn 1 0 0
vn 0 0 -1
vn -1 0 0
# UVs (XY)
vt 0.5 0 0
vt 1 0 0
vt 1 0.5 0
vt 0.5 0.5 0
vt 0.5 0.5 0
vt 1 0.5 0
vt 0.5 1 0
vt 1 1 0
vt 0 0.5 0
vt 1 0.5 0
vt 1 0 0
vt 0 0 0
vt 0 0.5 0
vt 1 0.5 0
vt 1 1 0
vt 0 1 0
vt 0.5 0 0
vt 0 0 0
vt 0 0.5 0
vt 0.5 0.5 0
vt 0 0.5 0
vt 0.5 0.5 0
vt 0.5 1 0
vt 0 1 0
# merger
g box
# reference material
#usemtl mat01
# faces
f 1/9/1 3/10/1 4/11/1
f 4/11/1 2/12/1 1/9/1
f 5/13/2 6/14/2 8/15/2
f 8/15/2 7/16/2 5/13/2
f 1/17/6 2/18/6 6/19/6
f 6/19/6 5/20/6 1/17/6
f 2/6/1 4/5/1 8/7/1
f 8/7/1 6/8/1 2/6/1
f 4/2/3 3/1/3 7/4/3
f 7/4/3 8/3/3 4/2/3
f 3/22/5 1/21/5 5/24/5
f 5/24/5 7/23/5 3/22/5

BIN
examples/models/resources/models/obj/cube_diffuse.png View File

Before After
Width: 256  |  Height: 256  |  Size: 23 KiB

+ 4564
- 0
examples/models/resources/models/obj/house.obj
File diff suppressed because it is too large
View File


BIN
examples/models/resources/models/obj/house_diffuse.png View File

Before After
Width: 1024  |  Height: 1024  |  Size: 383 KiB

+ 7301
- 0
examples/models/resources/models/obj/market.obj
File diff suppressed because it is too large
View File


BIN
examples/models/resources/models/obj/market_diffuse.png View File

Before After
Width: 1024  |  Height: 1024  |  Size: 380 KiB

+ 1888
- 0
examples/models/resources/models/obj/turret.obj
File diff suppressed because it is too large
View File


BIN
examples/models/resources/models/obj/turret_diffuse.png View File

Before After
Width: 1024  |  Height: 1024  |  Size: 371 KiB

+ 1030
- 0
examples/models/resources/models/obj/well.obj
File diff suppressed because it is too large
View File


BIN
examples/models/resources/models/obj/well_diffuse.png View File

Before After
Width: 1024  |  Height: 1024  |  Size: 334 KiB

Loading…
Cancel
Save