lettier / 3d-game-shaders-for-beginners

🎮 A step-by-step guide to implementing SSAO, depth of field, lighting, normal mapping, and more for your 3D game.
https://lettier.github.io/3d-game-shaders-for-beginners/index.html
17.35k stars 1.35k forks source link

About the materials format. #2

Open Danny1451 opened 5 years ago

Danny1451 commented 5 years ago

Hi, the repo is awesome ! 🎉 As I'm an iOS developer , and i would like to implement a Metal version with your tutorial. But i have some problem with the materials , it's the Panda3D format like '.egg' , Could u provide the model file with the universal format (e.g. OBJ, FBX, 3DS, PLY, STL, etc.).

GabLeRoux commented 3 years ago

Well, Panda3d provides command lines to do conversion. If you really don'y want to install python on your computer, here's a Google Collabotary script which allows you to convert from .egg to what you probably want (ex; .obj):

https://colab.research.google.com/drive/1SpIwOZ4JLuX53-ZGjoHcB41XuH9paeaG?usp=sharing

Note that it could have been a couple of bash commands instead of a python script. I started from a script I found, not so clean, but it works.

image

Here I imported .obj files in a unity project.

image

Note that you may need to fix rotation when importing (x: -90)

Some related documentation:

Also note that there are many tools available in there:

ls /usr/local/bin/ | grep egg
bam2egg
dae2egg
dxf2egg
egg2bam
egg2c
egg2dxf
egg2flt
egg2obj
egg2x
eggcacher
egg-crop
egg-list-textures
egg-make-tube
egg-mkfont
egg-optchar
egg-palettize
egg-qtess
egg-rename
egg-retarget-anim
egg-texture-cards
egg-topstrip
egg-trans
flt2egg
lwo2egg
obj2egg
vrml2egg
x2egg
ls /usr/local/bin/ | grep bam
bam2egg
bam-info
egg2bam

:v:

rdb commented 3 years ago

This may also be useful: https://github.com/rdb/blender-egg-importer/

lettier commented 3 years ago

Hello,

To clear up any confusion, the included license only applies to the software and not the data or literature.

Thank you for your understanding.

:+1: