Commit 634e5785 authored by Alberto Villa's avatar Alberto Villa

Reorganize and cleanup build structure

src/CMakeLists.txt gets splitted in several files; #include's are now
relative to src/ (or, when in one of its direct sub directories, on
it).
parent 3bdc55dc
macro_optional_find_package(Nepomuk)
macro_optional_find_package(QJSON)
add_subdirectory(audioscopes)
add_subdirectory(beziercurve) add_subdirectory(beziercurve)
add_subdirectory(blackmagic)
add_subdirectory(colorcorrection) add_subdirectory(colorcorrection)
add_subdirectory(colorscopes)
add_subdirectory(commands)
add_subdirectory(databackup)
add_subdirectory(kiss_fft) add_subdirectory(kiss_fft)
add_subdirectory(mimetypes) add_subdirectory(mimetypes)
add_subdirectory(onmonitoritems) add_subdirectory(onmonitoritems)
add_subdirectory(rotoscoping) add_subdirectory(simplekeyframes)
add_subdirectory(widgets) add_subdirectory(stopmotion)
add_subdirectory(databackup)
add_subdirectory(commands)
macro_optional_find_package(Nepomuk) if(QJSON_FOUND)
macro_optional_find_package(QJSON) add_subdirectory(rotoscoping)
add_subdirectory(onmonitoritems/rotoscoping)
include_directories(QJSON_INCLUDE_DIR)
set(optional_libs ${optional_libs} ${QJSON_LIBRARIES})
add_definitions(-DQJSON)
else(QJSON_FOUND)
message(STATUS "Install QJson to use the rotoscoping filter")
endif(QJSON_FOUND)
if(NOT APPLE AND NOT CMAKE_SYSTEM_NAME STREQUAL "FreeBSD" AND NOT CMAKE_SYSTEM_NAME STREQUAL "GNU/kFreeBSD")
add_subdirectory(v4l)
endif(NOT APPLE AND NOT CMAKE_SYSTEM_NAME STREQUAL "FreeBSD" AND NOT CMAKE_SYSTEM_NAME STREQUAL "GNU/kFreeBSD")
include_directories( include_directories(
${KDE4_INCLUDE_DIR} ${KDE4_INCLUDE_DIR}
...@@ -18,32 +35,16 @@ include_directories( ...@@ -18,32 +35,16 @@ include_directories(
${LIBMLT_INCLUDE_DIR} ${LIBMLT_INCLUDE_DIR}
${LIBMLTPLUS_INCLUDE_DIR} ${LIBMLTPLUS_INCLUDE_DIR}
${QDBUS_INCLUDE_DIRS} ${QDBUS_INCLUDE_DIRS}
${CMAKE_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR}
${CMAKE_BINARY_DIR} ${CMAKE_BINARY_DIR}
${CMAKE_SOURCE_DIR}/src/audioscopes
${CMAKE_SOURCE_DIR}/src/beziercurve
${CMAKE_SOURCE_DIR}/src/colorcorrection
${CMAKE_SOURCE_DIR}/src/kiss_fft
${CMAKE_SOURCE_DIR}/src/onmonitoritems
${CMAKE_SOURCE_DIR}/src/onmonitoritems/rotoscoping
${CMAKE_SOURCE_DIR}/src/widgets
) )
if(Nepomuk_FOUND) if(Nepomuk_FOUND)
include_directories(NEPOMUK_INCLUDES) include_directories(NEPOMUK_INCLUDES)
set(optional_libs ${NEPOMUK_LIBRARIES}) set(optional_libs ${optional_libs} ${NEPOMUK_LIBRARIES})
add_definitions(-DNEPOMUK) add_definitions(-DNEPOMUK)
endif(Nepomuk_FOUND) endif(Nepomuk_FOUND)
if(QJSON_FOUND)
include_directories(QJSON_INCLUDE_DIR)
set(optional_libs ${optional_libs} ${QJSON_LIBRARIES})
add_definitions(-DQJSON)
else(QJSON_FOUND)
message(STATUS "Install QJson to use the rotoscoping filter")
endif(QJSON_FOUND)
if(Q_WS_X11) if(Q_WS_X11)
include_directories(${X11_Xlib_INCLUDE_PATH}) include_directories(${X11_Xlib_INCLUDE_PATH})
endif(Q_WS_X11) endif(Q_WS_X11)
...@@ -203,44 +204,17 @@ set(kdenlive_SRCS ...@@ -203,44 +204,17 @@ set(kdenlive_SRCS
timecodedisplay.cpp timecodedisplay.cpp
tracksconfigdialog.cpp tracksconfigdialog.cpp
abstractscopewidget.cpp abstractscopewidget.cpp
audioscopes/abstractaudioscopewidget.cpp
audioscopes/audiospectrum.cpp
audioscopes/spectrogram.cpp
audioscopes/ffttools.cpp
colorscopes/abstractgfxscopewidget.cpp
colorscopes/histogram.cpp
colorscopes/rgbparade.cpp
colorscopes/vectorscope.cpp
colorscopes/waveform.cpp
colorplaneexport.cpp colorplaneexport.cpp
colortools.cpp colortools.cpp
colorcorrection/histogramgenerator.cpp
colorcorrection/rgbparadegenerator.cpp
colorcorrection/vectorscopegenerator.cpp
colorcorrection/waveformgenerator.cpp
colorpickerwidget.cpp colorpickerwidget.cpp
choosecolorwidget.cpp choosecolorwidget.cpp
monitorscene.cpp monitorscene.cpp
geometrywidget.cpp geometrywidget.cpp
doubleparameterwidget.cpp doubleparameterwidget.cpp
audiosignal.cpp audiosignal.cpp
blackmagic/include/DeckLinkAPIDispatch.cpp
stopmotion/stopmotion.cpp
blackmagic/devices.cpp
onmonitoritems/onmonitorrectitem.cpp
onmonitoritems/onmonitorcornersitem.cpp
cornerswidget.cpp cornerswidget.cpp
kiss_fft/_kiss_fft_guts.h
kiss_fft/kiss_fft.c
kiss_fft/tools/kiss_fftr.c
beziercurve/beziersplineeditor.cpp
beziercurve/beziersplinewidget.cpp
beziercurve/bpoint.cpp
beziercurve/cubicbezierspline.cpp
dragvalue.cpp dragvalue.cpp
monitoreditwidget.cpp monitoreditwidget.cpp
simplekeyframes/simpletimelinewidget.cpp
simplekeyframes/simplekeyframewidget.cpp
noteswidget.cpp noteswidget.cpp
archivewidget.cpp archivewidget.cpp
mltdevicecapture.cpp mltdevicecapture.cpp
...@@ -265,24 +239,6 @@ if(APPLE OR OPENGL_FOUND) ...@@ -265,24 +239,6 @@ if(APPLE OR OPENGL_FOUND)
set(kdenlive_SRCS videoglwidget.cpp ${kdenlive_SRCS}) set(kdenlive_SRCS videoglwidget.cpp ${kdenlive_SRCS})
endif(APPLE OR OPENGL_FOUND) endif(APPLE OR OPENGL_FOUND)
if(NOT APPLE AND NOT CMAKE_SYSTEM_NAME STREQUAL "FreeBSD" AND NOT CMAKE_SYSTEM_NAME STREQUAL "GNU/kFreeBSD")
set(kdenlive_SRCS
${kdenlive_SRCS}
v4l/v4lcapture.cpp
v4l/src.c
)
endif(NOT APPLE AND NOT CMAKE_SYSTEM_NAME STREQUAL "FreeBSD" AND NOT CMAKE_SYSTEM_NAME STREQUAL "GNU/kFreeBSD")
if(QJSON_FOUND)
set(kdenlive_SRCS
${kdenlive_SRCS}
onmonitoritems/rotoscoping/bpointitem.cpp
onmonitoritems/rotoscoping/nearestpoint.cpp
onmonitoritems/rotoscoping/splineitem.cpp
rotoscoping/rotowidget.cpp
)
endif(QJSON_FOUND)
# Add libdl # Add libdl
find_library(DL_LIB NAMES ${CMAKE_DL_LIBS}) find_library(DL_LIB NAMES ${CMAKE_DL_LIBS})
message(STATUS "using dl library: ${DL_LIB}") message(STATUS "using dl library: ${DL_LIB}")
......
...@@ -8,12 +8,11 @@ ...@@ -8,12 +8,11 @@
* (at your option) any later version. * * (at your option) any later version. *
***************************************************************************/ ***************************************************************************/
#include "qtconcurrentrun.h"
#include "abstractscopewidget.h" #include "abstractscopewidget.h"
#include "renderer.h" #include "renderer.h"
#include "monitor.h" #include "monitor.h"
#include <QtConcurrentRun>
#include <QFuture> #include <QFuture>
#include <QColor> #include <QColor>
#include <QMenu> #include <QMenu>
......
set(kdenlive_SRCS
${kdenlive_SRCS}
audioscopes/abstractaudioscopewidget.cpp
audioscopes/audiospectrum.cpp
audioscopes/ffttools.cpp
audioscopes/spectrogram.cpp
PARENT_SCOPE
)
...@@ -8,12 +8,11 @@ ...@@ -8,12 +8,11 @@
* (at your option) any later version. * * (at your option) any later version. *
***************************************************************************/ ***************************************************************************/
#include "qtconcurrentrun.h"
#include "abstractaudioscopewidget.h" #include "abstractaudioscopewidget.h"
#include "renderer.h" #include "renderer.h"
#include "monitor.h" #include "monitor.h"
#include <QtConcurrentRun>
#include <QFuture> #include <QFuture>
#include <QColor> #include <QColor>
#include <QMenu> #include <QMenu>
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
#include "audiospectrum.h" #include "audiospectrum.h"
#include "ffttools.h" #include "ffttools.h"
#include "tools/kiss_fftr.h" #include "kiss_fft/tools/kiss_fftr.h"
#include <QMenu> #include <QMenu>
#include <QPainter> #include <QPainter>
......
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
#include "abstractaudioscopewidget.h" #include "abstractaudioscopewidget.h"
#include "ui_audiospectrum_ui.h" #include "ui_audiospectrum_ui.h"
#include "tools/kiss_fftr.h" #include "kiss_fft/tools/kiss_fftr.h"
#include "ffttools.h" #include "ffttools.h"
class AudioSpectrum_UI; class AudioSpectrum_UI;
......
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
#include <QVector> #include <QVector>
#include <QHash> #include <QHash>
#include <tools/kiss_fftr.h> #include "kiss_fft/tools/kiss_fftr.h"
class FFTTools class FFTTools
{ {
......
...@@ -18,7 +18,6 @@ ...@@ -18,7 +18,6 @@
***************************************************************************/ ***************************************************************************/
#include "audiosignal.h" #include "audiosignal.h"
#include "math.h"
#include <KLocale> #include <KLocale>
...@@ -29,6 +28,7 @@ ...@@ -29,6 +28,7 @@
#include <QDebug> #include <QDebug>
#include <QList> #include <QList>
#include <math.h>
AudioSignal::AudioSignal(QWidget *parent): QWidget(parent) AudioSignal::AudioSignal(QWidget *parent): QWidget(parent)
{ {
......
set(kdenlive_SRCS
${kdenlive_SRCS}
beziercurve/beziersplineeditor.cpp
beziercurve/beziersplinewidget.cpp
beziercurve/bpoint.cpp
beziercurve/cubicbezierspline.cpp
PARENT_SCOPE
)
set(kdenlive_SRCS
${kdenlive_SRCS}
blackmagic/devices.cpp
blackmagic/include/DeckLinkAPIDispatch.cpp
PARENT_SCOPE
)
set(kdenlive_SRCS
${kdenlive_SRCS}
colorcorrection/histogramgenerator.cpp
colorcorrection/rgbparadegenerator.cpp
colorcorrection/vectorscopegenerator.cpp
colorcorrection/waveformgenerator.cpp
PARENT_SCOPE
)
set(kdenlive_SRCS
${kdenlive_SRCS}
colorscopes/abstractgfxscopewidget.cpp
colorscopes/histogram.cpp
colorscopes/rgbparade.cpp
colorscopes/vectorscope.cpp
colorscopes/waveform.cpp
PARENT_SCOPE
)
...@@ -8,12 +8,11 @@ ...@@ -8,12 +8,11 @@
* (at your option) any later version. * * (at your option) any later version. *
***************************************************************************/ ***************************************************************************/
#include "qtconcurrentrun.h"
#include "abstractgfxscopewidget.h" #include "abstractgfxscopewidget.h"
#include "renderer.h" #include "renderer.h"
#include "monitormanager.h" #include "monitormanager.h"
#include <QtConcurrentRun>
#include <QFuture> #include <QFuture>
#include <QColor> #include <QColor>
#include <QMenu> #include <QMenu>
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
#include <QMenu> #include <QMenu>
#include <QTime> #include <QTime>
#include "histogramgenerator.h" #include "colorcorrection/histogramgenerator.h"
#include "histogram.h" #include "histogram.h"
#include "renderer.h" #include "renderer.h"
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
#include <QTime> #include <QTime>
#include "renderer.h" #include "renderer.h"
#include "rgbparade.h" #include "rgbparade.h"
#include "rgbparadegenerator.h" #include "colorcorrection/rgbparadegenerator.h"
RGBParade::RGBParade(MonitorManager *manager, QWidget *parent) : RGBParade::RGBParade(MonitorManager *manager, QWidget *parent) :
AbstractGfxScopeWidget(manager, true, parent) AbstractGfxScopeWidget(manager, true, parent)
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
#include "colortools.h" #include "colortools.h"
#include "renderer.h" #include "renderer.h"
#include "vectorscope.h" #include "vectorscope.h"
#include "vectorscopegenerator.h" #include "colorcorrection/vectorscopegenerator.h"
const float P75 = .75; const float P75 = .75;
const unsigned char DEFAULT_Y = 255; const unsigned char DEFAULT_Y = 255;
......
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
#include "renderer.h" #include "renderer.h"
#include "waveform.h" #include "waveform.h"
#include "waveformgenerator.h" #include "colorcorrection/waveformgenerator.h"
const QSize Waveform::m_textWidth(35,0); const QSize Waveform::m_textWidth(35,0);
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
***************************************************************************/ ***************************************************************************/
#include "commands/addclipcommand.h" #include "addclipcommand.h"
#include "kdenlivedoc.h" #include "kdenlivedoc.h"
#include <KLocale> #include <KLocale>
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA * * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA *
***************************************************************************/ ***************************************************************************/
#include "commands/addclipcutcommand.h" #include "addclipcutcommand.h"
#include "projectlist.h" #include "projectlist.h"
#include <KLocale> #include <KLocale>
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
***************************************************************************/ ***************************************************************************/
#include "commands/addeffectcommand.h" #include "addeffectcommand.h"
#include "customtrackview.h" #include "customtrackview.h"
#include <KLocale> #include <KLocale>
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
***************************************************************************/ ***************************************************************************/
#include "commands/addfoldercommand.h" #include "addfoldercommand.h"
#include "projectlist.h" #include "projectlist.h"
#include <KLocale> #include <KLocale>
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
***************************************************************************/ ***************************************************************************/
#include "commands/addmarkercommand.h" #include "addmarkercommand.h"
#include "customtrackview.h" #include "customtrackview.h"
#include <KLocale> #include <KLocale>
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
***************************************************************************/ ***************************************************************************/
#include "commands/addtimelineclipcommand.h" #include "addtimelineclipcommand.h"
#include "customtrackview.h" #include "customtrackview.h"
#include <KLocale> #include <KLocale>
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
***************************************************************************/ ***************************************************************************/
#include "commands/addtrackcommand.h" #include "addtrackcommand.h"
#include "customtrackview.h" #include "customtrackview.h"
#include <KLocale> #include <KLocale>
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
***************************************************************************/ ***************************************************************************/
#include "commands/addtransitioncommand.h" #include "addtransitioncommand.h"
#include "customtrackview.h" #include "customtrackview.h"
#include <KLocale> #include <KLocale>
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
***************************************************************************/ ***************************************************************************/
#include "commands/changecliptypecommand.h" #include "changecliptypecommand.h"
#include "customtrackview.h" #include "customtrackview.h"
#include <KLocale> #include <KLocale>
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
***************************************************************************/ ***************************************************************************/
#include "commands/changespeedcommand.h" #include "changespeedcommand.h"
#include "customtrackview.h" #include "customtrackview.h"
#include <KLocale> #include <KLocale>
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
***************************************************************************/ ***************************************************************************/
#include "commands/configtrackscommand.h" #include "configtrackscommand.h"
#include "customtrackview.h" #include "customtrackview.h"
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA * * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA *
***************************************************************************/ ***************************************************************************/
#include "commands/editclipcommand.h" #include "editclipcommand.h"
#include "projectlist.h" #include "projectlist.h"
#include <KLocale> #include <KLocale>
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA * * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA *
***************************************************************************/ ***************************************************************************/
#include "commands/editclipcutcommand.h" #include "editclipcutcommand.h"
#include "projectlist.h" #include "projectlist.h"
#include <KLocale> #include <KLocale>
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
***************************************************************************/ ***************************************************************************/
#include "commands/editeffectcommand.h" #include "editeffectcommand.h"
#include "customtrackview.h" #include "customtrackview.h"
#include <KLocale> #include <KLocale>
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
***************************************************************************/ ***************************************************************************/
#include "commands/editfoldercommand.h" #include "editfoldercommand.h"
#include "projectlist.h" #include "projectlist.h"
#include <KLocale> #include <KLocale>
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
***************************************************************************/ ***************************************************************************/
#include "commands/editguidecommand.h" #include "editguidecommand.h"
#include "customtrackview.h" #include "customtrackview.h"
#include <KLocale> #include <KLocale>
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
***************************************************************************/ ***************************************************************************/
#include "commands/editkeyframecommand.h" #include "editkeyframecommand.h"
#include "customtrackview.h" #include "customtrackview.h"
#include <KLocale> #include <KLocale>
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
* * * *
***************************************************************************/ ***************************************************************************/
#include "commands/edittransitioncommand.h" #include "edittransitioncommand.h"
#include "customtrackview.h" #include "customtrackview.h"
#include <KLocale> #include <KLocale>
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
***************************************************************************/ ***************************************************************************/
#include "commands/groupclipscommand.h" #include "groupclipscommand.h"
#include "customtrackview.h" #include "customtrackview.h"
#include <KLocale> #include <KLocale>
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
***************************************************************************/ ***************************************************************************/
#include "commands/insertspacecommand.h" #include "insertspacecommand.h"
#include "customtrackview.h" #include "customtrackview.h"
#include <KLocale> #include <KLocale>
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA * * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA *
***************************************************************************/ ***************************************************************************/
#include "commands/locktrackcommand.h" #include "locktrackcommand.h"
#include "customtrackview.h" #include "customtrackview.h"
#include <KLocale> #include <KLocale>
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
***************************************************************************/ ***************************************************************************/
#include "commands/moveclipcommand.h" #include "moveclipcommand.h"
#include "customtrackview.h" #include "customtrackview.h"
#include <KLocale> #include <KLocale>
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
***************************************************************************/ ***************************************************************************/