various: encapsulate all code in the olive namespace to avoid name collisions

Large-scale code cleanup. Also adds a license to the top of all files that were
missing it.
This commit is contained in:
itsmattkc
2020-04-06 15:29:53 +10:00
parent 82b6ddccc8
commit 1aa87cbda6
519 changed files with 7939 additions and 158 deletions
+3
View File
@@ -25,6 +25,8 @@
#include "node/output/track/track.h"
#include "transition/transition.h"
OLIVE_NAMESPACE_ENTER
Block::Block() :
previous_(nullptr),
next_(nullptr)
@@ -330,3 +332,4 @@ void Block::InvalidateCache(const rational &start_range, const rational &end_ran
Node::InvalidateCache(start_range, end_range, from);
}
OLIVE_NAMESPACE_EXIT
+4
View File
@@ -23,6 +23,8 @@
#include "node/node.h"
OLIVE_NAMESPACE_ENTER
/**
* @brief A Node that represents a block of time, also displayable on a Timeline
*
@@ -136,4 +138,6 @@ private slots:
};
OLIVE_NAMESPACE_EXIT
#endif // BLOCK_H
+4
View File
@@ -20,6 +20,8 @@
#include "clip.h"
OLIVE_NAMESPACE_ENTER
ClipBlock::ClipBlock()
{
texture_input_ = new NodeInput("buffer_in", NodeInput::kBuffer);
@@ -117,3 +119,5 @@ void ClipBlock::Retranslate()
texture_input_->set_name(tr("Buffer"));
}
OLIVE_NAMESPACE_EXIT
+4
View File
@@ -23,6 +23,8 @@
#include "node/block/block.h"
OLIVE_NAMESPACE_ENTER
/**
* @brief Node that represents a block of Media
*/
@@ -60,4 +62,6 @@ private:
};
OLIVE_NAMESPACE_EXIT
#endif // TIMELINEBLOCK_H
+4
View File
@@ -20,6 +20,8 @@
#include "gap.h"
OLIVE_NAMESPACE_ENTER
GapBlock::GapBlock()
{
}
@@ -48,3 +50,5 @@ QString GapBlock::Description() const
{
return tr("A time-based node that represents an empty space.");
}
OLIVE_NAMESPACE_EXIT
+4
View File
@@ -23,6 +23,8 @@
#include "node/block/block.h"
OLIVE_NAMESPACE_ENTER
/**
* @brief Node that represents nothing in its respective track for a certain period of time
*/
@@ -44,4 +46,6 @@ private:
};
OLIVE_NAMESPACE_EXIT
#endif // TIMELINEBLOCK_H
@@ -1,5 +1,27 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2019 Olive Team
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
***/
#include "externaltransition.h"
OLIVE_NAMESPACE_ENTER
ExternalTransition::ExternalTransition(const QString &xml_meta_filename) :
meta_(xml_meta_filename)
{
@@ -62,3 +84,5 @@ NodeInput *ExternalTransition::ShaderIterativeInput() const
{
return meta_.iteration_input();
}
OLIVE_NAMESPACE_EXIT
@@ -1,3 +1,23 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2019 Olive Team
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
***/
#ifndef EXTERNALTRANSITION_H
#define EXTERNALTRANSITION_H
@@ -5,6 +25,8 @@
#include "node/metareader.h"
OLIVE_NAMESPACE_ENTER
class ExternalTransition : public TransitionBlock
{
public:
@@ -29,4 +51,6 @@ private:
NodeMetaReader meta_;
};
OLIVE_NAMESPACE_EXIT
#endif // EXTERNALTRANSITION_H
+24
View File
@@ -1,7 +1,29 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2019 Olive Team
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
***/
#include "transition.h"
#include "common/clamp.h"
OLIVE_NAMESPACE_ENTER
TransitionBlock::TransitionBlock() :
connected_out_block_(nullptr),
connected_in_block_(nullptr)
@@ -133,3 +155,5 @@ void TransitionBlock::BlockDisconnected(NodeEdgePtr edge)
connected_in_block_ = nullptr;
}
}
OLIVE_NAMESPACE_EXIT
+24
View File
@@ -1,8 +1,30 @@
/***
Olive - Non-Linear Video Editor
Copyright (C) 2019 Olive Team
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
***/
#ifndef TRANSITIONBLOCK_H
#define TRANSITIONBLOCK_H
#include "node/block/block.h"
OLIVE_NAMESPACE_ENTER
class TransitionBlock : public Block
{
public:
@@ -43,4 +65,6 @@ private slots:
};
OLIVE_NAMESPACE_EXIT
#endif // TRANSITIONBLOCK_H