Checkpoint 3: deliver playable samples and complete native authoring workflows

This commit is contained in:
Emil
2026-09-18 04:29:41 +03:00
parent fad5eb4e55
commit d834cfad67
92 changed files with 8335 additions and 353 deletions
+2
View File
@@ -20,6 +20,8 @@ class EditorUI {
void select_document(const std::string& document);
const std::string& selected_entity() const;
void select_entity(const std::string& entity);
bool project_switch_requested() const;
void set_project_switch_enabled(bool enabled);
private:
struct Impl;
+2
View File
@@ -23,6 +23,8 @@ class StdioTransport {
bool closed() const noexcept {
return closed_;
}
// Write failure closes this transport; a disconnected client never exits
// the Editor process. A GUI can continue after closed() becomes true.
void send(const Json& message);
private:
+34
View File
@@ -0,0 +1,34 @@
#pragma once
#include <faset/ui/ui.hpp>
#include <optional>
namespace faset::editor {
struct ProjectSelection {
std::filesystem::path path;
std::string name;
int dimension = 3;
bool create = false;
};
// Records only existing, valid projects. Call after successful Session setup.
void remember_project(const std::filesystem::path& project);
class ProjectLauncher {
public:
ProjectLauncher(render::Renderer&, const std::filesystem::path& engine_root,
const std::filesystem::path& initial_project = {},
const std::filesystem::path& recent_store = {});
~ProjectLauncher();
void frame(const std::vector<render::Event>&);
const render::Snapshot& snapshot() const;
ui::Context& widgets();
const std::optional<ProjectSelection>& selection() const;
bool cancelled() const;
private:
struct Impl;
std::unique_ptr<Impl> impl_;
};
std::optional<ProjectSelection>
run_project_launcher(const std::filesystem::path& engine_root,
const std::filesystem::path& initial_project = {},
std::uint64_t max_frames = 0, const std::filesystem::path& capture = {});
} // namespace faset::editor
+6
View File
@@ -46,6 +46,8 @@ class Session {
void register_commands();
Json assets_list() const;
Json jobs() const;
std::string source_signature() const;
Json schema_status() const;
Json job(const std::string& id) const;
void load_schema(const std::filesystem::path& path);
void launch_player(Json scene, const std::filesystem::path& executable);
@@ -65,5 +67,9 @@ class Session {
std::string pending_play_job_;
Json pending_play_scene_;
std::unique_ptr<PluginManager> plugins_;
std::map<std::string, std::string> submitted_sources_;
std::string schema_source_signature_;
bool schema_loaded_ = false;
std::string schema_error_;
};
} // namespace faset::editor