Export to .glb

This commit is contained in:
ackwell 2024-04-18 21:47:07 +10:00
parent fd1f9b95d6
commit dbfaf37800
2 changed files with 3 additions and 3 deletions

View file

@ -213,7 +213,7 @@ public sealed class ModelManager(IFramework framework, ActiveCollections collect
Penumbra.Log.Debug("[GLTF Export] Saving..."); Penumbra.Log.Debug("[GLTF Export] Saving...");
var gltfModel = scene.ToGltf2(); var gltfModel = scene.ToGltf2();
gltfModel.SaveGLTF(outputPath); gltfModel.Save(outputPath);
Penumbra.Log.Debug("[GLTF Export] Done."); Penumbra.Log.Debug("[GLTF Export] Done.");
} }

View file

@ -145,8 +145,8 @@ public partial class ModEditWindow
if (ImGuiUtil.DrawDisabledButton("Export to glTF", Vector2.Zero, "Exports this mdl file to glTF, for use in 3D authoring applications.", if (ImGuiUtil.DrawDisabledButton("Export to glTF", Vector2.Zero, "Exports this mdl file to glTF, for use in 3D authoring applications.",
tab.PendingIo || gamePath.IsEmpty)) tab.PendingIo || gamePath.IsEmpty))
_fileDialog.OpenSavePicker("Save model as glTF.", ".gltf", Path.GetFileNameWithoutExtension(gamePath.Filename().ToString()), _fileDialog.OpenSavePicker("Save model as glTF.", ".glb", Path.GetFileNameWithoutExtension(gamePath.Filename().ToString()),
".gltf", (valid, path) => ".glb", (valid, path) =>
{ {
if (!valid) if (!valid)
return; return;