engine/include/util/gltf_loader.h
2024-03-31 11:11:22 +01:00

20 lines
500 B
C++

#pragma once
#include <string>
#include "scene.h"
namespace engine::util {
/*
* Loads the default scene found in a glTF file into 'scene'.
* 'isStatic' will mark every transform as static to aid rendering optimisation.
* Returns the top-level glTF node as an engine entity.
*
* Loader limitations:
* - Can only load .glb files
* - glTF files must contain all textures
*/
engine::Entity LoadGLTF(Scene& scene, const std::string& path, bool isStatic = false);
} // namespace engine::util