Stage 10a: delete dead code, merge tiny files, unify duplicated concepts

- Dead code: util/map, util/unordered_map, unused vector/math/string/input
  helpers, Document getters, special-interpolation bake leftovers,
  triggers_sort, SnapshotStack::max_size_get, AudioStream capture API.
- Merges: util/xml, util/string, resource/strings.cpp inlined; constants
  into input.hpp; tooltip into layout; Recorder into render; onionskin,
  tools, welcome and frame properties are panel functions; timeline
  popups.cpp folded into timeline.cpp.
- util/origin.hpp replaced by model Origin (the merge setting stays a
  combo index, so saved preferences keep their meaning).
- Item type names/icons/colors moved from model/common.hpp to the
  timeline header; the model no longer includes icon/strings headers.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
shweetandClaude Opus 5.5 committed 2026-10-03 18:35:22 -04:00
1 parent 4d16f21541
commit 4c569cb1e5
60 files changed
+605 -1021

No files matched your search

+48
View File
@@ -2,10 +2,17 @@
#include <algorithm>
#include <cmath>
#include <filesystem>
#include <vector>
#include "audio_stream.hpp"
#include "texture.hpp"
namespace anm2ed
{
class Document;
}
namespace anm2ed::render
{
#define RENDER_LIST \
@@ -103,6 +110,47 @@ namespace anm2ed::render
return {rows, columns};
}
struct RecorderOptions
{
Type type{};
std::filesystem::path path{};
std::filesystem::path format{};
std::filesystem::path ffmpegPath{};
int start{};
int end{};
int animationFps{1};
int fps{1};
int rows{};
int columns{};
bool isSound{};
bool isIsolated{};
bool isBounded{};
};
// A render in progress: which animation times to capture, the frames captured so far (written to disk) and the
// trigger sound of each, and assembling the output when done.
class Recorder
{
public:
RecorderOptions options{};
int index{};
int count{};
bool start(const RecorderOptions&);
bool is_done() const;
float time_get() const;
bool is_sound_frame() const;
bool frame_capture(std::vector<uint8_t>, glm::ivec2, int);
void finish(const Document&, AudioStream&);
void cancel();
private:
std::filesystem::path directory{};
std::vector<std::filesystem::path> frames{};
std::vector<int> soundIds{};
int soundTime{-1};
};
}
namespace anm2ed