Remove namespaces, and make file-local helpers static
Names that only a namespace told apart get prefixes: TOOL_PAN, FONT_BOLD, ICON_FOLDER, COLOR_WHITE, path_to_utf8 and so on. The OpenGL shader class is ShaderProgram, and its uniform ShaderUniform, beside the document's Shader and Uniform. Free functions a member of the same name would hide are called through :: for now. Two unused shader window helpers are gone.
This commit is contained in:
1 parent
7fb2c607c2
commit
666f65bf3a
174 files changed
+2396
-3154
No files matched your search
+3
-9
@@ -7,15 +7,10 @@
|
||||
#include "math_util.h"
|
||||
#include "model/frames.h"
|
||||
|
||||
using namespace anm2ed::model;
|
||||
using namespace anm2ed::util;
|
||||
|
||||
namespace anm2ed::edit
|
||||
{
|
||||
// An alpha offset joins the alpha tint: exact on opaque pixels, which the offset can only fade.
|
||||
void alpha_offsets_bridge(Model& model)
|
||||
static void alpha_offsets_bridge(Model& model)
|
||||
{
|
||||
auto is_offset = [](const Frame& frame) { return math::float_to_uint8(frame.colorOffset.a) != 0; };
|
||||
auto is_offset = [](const Frame& frame) { return float_to_uint8(frame.colorOffset.a) != 0; };
|
||||
for (int i = 0; i < model.animations_count_get(); ++i)
|
||||
{
|
||||
auto isUsed = false;
|
||||
@@ -38,7 +33,7 @@ namespace anm2ed::edit
|
||||
// A layer frame's depth becomes a copy of its layer, named for the depth, standing where the editor draws it (the
|
||||
// layer at the copy's place + depth, past the layer already there), and showing only the frames at that depth; the
|
||||
// layer itself shows the rest. Groups can't stand apart in the game, so their roots go into their tracks first.
|
||||
void depths_bridge(Model& model)
|
||||
static void depths_bridge(Model& model)
|
||||
{
|
||||
auto& content = model.content;
|
||||
std::map<std::pair<int, int>, int> copyIds{};
|
||||
@@ -117,4 +112,3 @@ namespace anm2ed::edit
|
||||
depths_bridge(model);
|
||||
return model;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user