diff --git a/CMakeLists.txt b/CMakeLists.txt
index 38abe4f30..ec608257d 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -75,18 +75,14 @@ option(USE_SYSTEM_JSONCPP "Use system installed JsonCpp, if found" ON)
option(DISABLE_BUNDLED_JSONCPP "Don't fall back to bundled JsonCpp" OFF)
option(ENABLE_IWYU "Enable 'Include What You Use' scanner (CMake 3.3+)" OFF)
option(ENABLE_TESTS "Build unit tests (requires UnitTest++)" ON)
+option(ENABLE_COVERAGE "Scan test coverage using gcov and report" OFF)
option(ENABLE_DOCS "Build API documentation (requires Doxygen)" ON)
option(APPIMAGE_BUILD "Build to install in an AppImage (Linux only)" OFF)
option(ENABLE_MAGICK "Use ImageMagick, if available" ON)
# Legacy commandline override
if (DISABLE_TESTS)
- if(ENABLE_COVERAGE)
- message(WARNING "ENABLE_COVERAGE requires tests, overriding DISABLE_TESTS")
- set(ENABLE_TESTS ON)
- else()
- set(ENABLE_TESTS OFF)
- endif()
+ set(ENABLE_TESTS OFF)
endif()
if(DEFINED ENABLE_TESTS)
@@ -110,9 +106,9 @@ IF (WIN32)
ENDIF(WIN32)
############## Code Coverage #########################
-if (DISABLE_TESTS AND ENABLE_COVERAGE)
- message(WARNING "ENABLE_COVERAGE requires tests, overriding DISABLE_TESTS")
- set(DISABLE_TESTS OFF CACHE BOOL "Don't build unit tests" FORCE)
+if (ENABLE_COVERAGE AND NOT ENABLE_TESTS)
+ message(WARNING "ENABLE_COVERAGE requires unit tests, forcing ENABLE_TESTS")
+ set(ENABLE_TESTS ON CACHE BOOL "Don't build unit tests" FORCE)
endif()
if (ENABLE_COVERAGE)
@@ -125,25 +121,29 @@ if (ENABLE_COVERAGE)
endif()
add_feature_info("Coverage" ENABLE_COVERAGE "analyze test coverage and generate report")
-# Juce requires either DEBUG or NDEBUG to be defined on MacOS.
-# -DNDEBUG is set by cmake for all release configs, so add
-# -DDEBUG for debug builds. We'll do this for all OSes, even
-# though only MacOS requires it.
-set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DDEBUG")
# Make sure we've picked some build type, default to release
if(NOT DEFINED CMAKE_BUILD_TYPE OR CMAKE_BUILD_TYPE STREQUAL "")
set(CMAKE_BUILD_TYPE "Release")
endif()
-############## PROCESS src/ DIRECTORIES ##############
+###
+### Process subdirectories
+###
add_subdirectory(src)
-
-########## Configure Version.h header ##############
-configure_file(include/OpenShotVersion.h.in include/OpenShotVersion.h @ONLY)
+add_subdirectory(examples)
+add_subdirectory(bindings)
+
+###
+### Configure Version.h header
+###
+# (Note: This comes after the subdirectories, because it needs variables
+# set during the dependency discovery in src/CMakeLists.txt)
+configure_file(src/OpenShotVersion.h.in src/OpenShotVersion.h @ONLY)
# We'll want that installed later
-install(FILES ${CMAKE_CURRENT_BINARY_DIR}/include/OpenShotVersion.h
+install(FILES ${CMAKE_CURRENT_BINARY_DIR}/src/OpenShotVersion.h
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/libopenshot)
+
################### DOCUMENTATION ###################
# Find Doxygen (used for documentation)
set(DOCS_ENABLED FALSE) # Only set true if Doxygen is found and configured
@@ -180,8 +180,10 @@ if (ENABLE_COVERAGE)
NAME coverage
LCOV_ARGS "--no-external"
EXECUTABLE openshot-test
- DEPENDENCIES openshot-test)
- message("Generate coverage report with 'make coverage'")
+ DEPENDENCIES openshot-test
+ EXCLUDE "bindings" "examples" "${CMAKE_CURRENT_BINARY_DIR}/bindings"
+ )
+ message("Generate coverage report with 'make coverage'")
endif()
########### PRINT FEATURE SUMMARY ##############
diff --git a/Doxyfile.in b/Doxyfile.in
index c47d6e651..343190a17 100644
--- a/Doxyfile.in
+++ b/Doxyfile.in
@@ -148,7 +148,7 @@ INLINE_INHERITED_MEMB = NO
# shortest path that makes the file name unique will be used
# The default value is: YES.
-FULL_PATH_NAMES = NO
+FULL_PATH_NAMES = YES
# The STRIP_FROM_PATH tag can be used to strip a user-defined part of the path.
# Stripping is only done if one of the specified strings matches the left-hand
@@ -160,7 +160,7 @@ FULL_PATH_NAMES = NO
# will be relative from the directory where doxygen is started.
# This tag requires that the tag FULL_PATH_NAMES is set to YES.
-STRIP_FROM_PATH =
+STRIP_FROM_PATH = "@PROJECT_SOURCE_DIR@/src"
# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of the
# path mentioned in the documentation of a class, which tells the reader which
@@ -169,7 +169,7 @@ STRIP_FROM_PATH =
# specify the list of include paths that are normally passed to the compiler
# using the -I flag.
-STRIP_FROM_INC_PATH =
+STRIP_FROM_INC_PATH = "@PROJECT_SOURCE_DIR@/src"
# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter (but
# less readable) file names. This can be useful is your file systems doesn't
@@ -803,9 +803,9 @@ WARN_LOGFILE =
# spaces. See also FILE_PATTERNS and EXTENSION_MAPPING
# Note: If this tag is empty the current directory is searched.
-INPUT = "@CMAKE_CURRENT_SOURCE_DIR@/include" \
- "@CMAKE_CURRENT_SOURCE_DIR@/src" \
- "@CMAKE_CURRENT_SOURCE_DIR@/doc"
+INPUT = "@PROJECT_SOURCE_DIR@/src" \
+ "@PROJECT_SOURCE_DIR@/doc" \
+ "@PROJECT_BINARY_DIR@/src/OpenShotVersion.h"
# This tag can be used to specify the character encoding of the source files
@@ -862,11 +862,7 @@ EXCLUDE_SYMLINKS = NO
# Note that the wildcards are matched against the file with absolute path, so to
# exclude all test directories for example use the pattern */test/*
-EXCLUDE_PATTERNS = "*/.*" \
- "*/.*/*" \
- "*/src/examples/*" \
- "*/src/bindings/*" \
- "*.py"
+EXCLUDE_PATTERNS =
# The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names
# (namespaces, classes, functions, etc.) that should be excluded from the
@@ -883,27 +879,27 @@ EXCLUDE_SYMBOLS =
# that contain example code fragments that are included (see the \include
# command).
-EXAMPLE_PATH = "@CMAKE_CURRENT_SOURCE_DIR@/tests"
+EXAMPLE_PATH = "@PROJECT_SOURCE_DIR@/examples"
# If the value of the EXAMPLE_PATH tag contains directories, you can use the
# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp and
# *.h) to filter out the source-files in the directories. If left blank all
# files are included.
-EXAMPLE_PATTERNS =
+EXAMPLE_PATTERNS = "*.cpp"
# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be
# searched for input files to be used with the \include or \dontinclude commands
# irrespective of the value of the RECURSIVE tag.
# The default value is: NO.
-EXAMPLE_RECURSIVE = NO
+EXAMPLE_RECURSIVE = YES
# The IMAGE_PATH tag can be used to specify one or more files or directories
# that contain images that are to be included in the documentation (see the
# \image command).
-IMAGE_PATH = "@CMAKE_CURRENT_SOURCE_DIR@"
+IMAGE_PATH = "@PROJECT_SOURCE_DIR@"
# The INPUT_FILTER tag can be used to specify a program that doxygen should
# invoke to filter for each input file. Doxygen will invoke the filter program
@@ -2086,7 +2082,7 @@ INCLUDE_PATH =
# used.
# This tag requires that the tag ENABLE_PREPROCESSING is set to YES.
-INCLUDE_FILE_PATTERNS =
+INCLUDE_FILE_PATTERNS = "*.h"
# The PREDEFINED tag can be used to specify one or more macro names that are
# defined before the preprocessor is started (similar to the -D option of e.g.
diff --git a/INSTALL.md b/INSTALL.md
index f2d0dda77..b1ddc7961 100644
--- a/INSTALL.md
+++ b/INSTALL.md
@@ -2,74 +2,100 @@
Operating system specific install instructions are located in:
-* [doc/INSTALL-LINUX.md][INSTALL-LINUX]
-* [doc/INSTALL-MAC.md][INSTALL-MAC]
-* [doc/INSTALL-WINDOWS.md][INSTALL-WINDOWS]
+* [doc/INSTALL-LINUX.md][INSTALL-LINUX]
+* [doc/INSTALL-MAC.md][INSTALL-MAC]
+* [doc/INSTALL-WINDOWS.md][INSTALL-WINDOWS]
## Getting Started
-The best way to get started with libopenshot, is to learn about our build system, obtain all the source code,
-install a development IDE and tools, and better understand our dependencies. So, please read through the
-following sections, and follow the instructions. And keep in mind, that your computer is likely different
-than the one used when writing these instructions. Your file paths and versions of applications might be
-slightly different, so keep an eye out for subtle file path differences in the commands you type.
+The best way to get started with libopenshot is to learn about our build system,
+obtain all the source code, install a development IDE and tools,
+and better understand our dependencies.
+So, please read through the following sections, and follow the instructions.
+And keep in mind, your computer is likely different than the one used when writing these instructions.
+Your file paths and versions of applications will be different,
+so you should treat the specifics used here as examples and adjust as necessary.
+Keep an eye out for subtle file path differences in the commands you type.
## Dependencies
The following libraries are required to build libopenshot.
Instructions on how to install these dependencies vary for each operating system.
-Libraries and Executables have been labeled in the list below to help distinguish between them.
+Libraries and executables have been labeled in the list below to help distinguish between them.
#### FFmpeg (libavformat, libavcodec, libavutil, libavdevice, libavresample, libswscale)
+* **(Library)**
- * http://www.ffmpeg.org/ **(Library)**
- * This library is used to decode and encode video, audio, and image files. It is also used to obtain information about media files, such as frame rate, sample rate, aspect ratio, and other common attributes.
+* This library is used to decode and encode video, audio, and image files.
+ It is also used to obtain information about media files,
+ such as frame rate, sample rate, aspect ratio, and other common attributes.
#### ImageMagick++ (libMagick++, libMagickWand, libMagickCore)
- * http://www.imagemagick.org/script/magick++.php **(Library)**
- * This library is **optional**, and used to decode and encode images.
+* **(Library)**
+* This library is **optional**, and used to decode and encode images.
#### OpenShot Audio Library (libopenshot-audio)
- * https://github.com/OpenShot/libopenshot-audio/ **(Library)**
- * This library is used to mix, resample, host plug-ins, and play audio. It is based on the JUCE project, which is an outstanding audio library used by many different applications
+* **(Library)**
+
+* This library is used to mix, resample, host plug-ins, and play audio.
+ It is based on the JUCE project,
+ an outstanding audio library used by many different applications.
#### Qt 5 (libqt5)
- * http://www.qt.io/qt5/ **(Library)**
- * Qt5 is used to display video, store image data, composite images, apply image effects, and many other utility functions, such as file system manipulation, high resolution timers, etc...
+* **(Library)**
+
+* Qt5 is used to display video, store image data, composite images,
+ apply image effects, and many other utility functions,
+ such as file system manipulation, high resolution timers, etc.
#### ZeroMQ (libzmq)
- * http://zeromq.org/ **(Library)**
- * This library is used to communicate between libopenshot and other applications (publisher / subscriber). Primarily used to send debug data from libopenshot.
+* **(Library)**
+
+* This library is used to communicate between libopenshot and other applications (publisher / subscriber).
+ Primarily used to send debug data from libopenshot.
#### OpenMP (`-fopenmp`)
- * http://openmp.org/wp/ **(Compiler Flag)**
- * If your compiler supports this flag (GCC, Clang, and most other compilers), it provides libopenshot with easy methods of using parallel programming techniques to improve performance and take advantage of multi-core processors.
+* **(Compiler Flag)**
+
+* If your compiler supports this flag (GCC, Clang, and most other compilers),
+ it provides libopenshot with implementations of common parallel programming techniques
+ used to improve performance and take advantage of multi-core processors.
#### CMake (`cmake`)
- * http://www.cmake.org/ **(Executable)**
- * This executable is used to automate the generation of Makefiles, check for dependencies, and is the backbone of libopenshot’s cross-platform build process.
+* **(Executable)**
+
+* This executable is used to automate the generation of Makefiles,
+ check for dependencies, and is the backbone of libopenshot’s cross-platform build process.
#### SWIG (`swig`)
- * http://www.swig.org/ **(Executable)**
- * This executable is used to generate the Python and Ruby bindings for libopenshot. It is a simple and powerful wrapper for C++ libraries, and supports many languages.
+* **(Executable)**
+
+* This executable is used to generate the Python and Ruby bindings for libopenshot.
+ It is a powerful wrapper for C++ libraries, and supports many languages.
#### Python 3 (libpython)
- * http://www.python.org/ **(Executable and Library)**
- * This library is used by swig to create the Python (version 3+) bindings for libopenshot. This is also the official language used by OpenShot Video Editor (a graphical interface to libopenshot).
+* **(Executable and Library)**
+
+* This library is used by swig to create the Python (version 3+) bindings for libopenshot.
+ This is also the official language used by OpenShot Video Editor (a graphical interface to libopenshot).
#### Doxygen (doxygen)
- * http://www.stack.nl/~dimitri/doxygen/ **(Executable)**
- * This executable is used to auto-generate the documentation used by libopenshot.
+* **(Executable)**
+* This executable is used to auto-generate the documentation used by libopenshot.
#### UnitTest++ (libunittest++)
- * https://github.com/unittest-cpp/ **(Library)**
- * This library is used to execute unit tests for libopenshot. It contains many macros used to keep our unit testing code very clean and simple.
+* **(Library)**
+
+* This library is used to execute unit tests for libopenshot.
+ It contains many macros used to keep our unit testing code clean and easy-to-follow.
## Obtaining Source Code
-The first step in installing libopenshot is to obtain the most recent source code. The source code is available on [GitHub](https://github.com/OpenShot/libopenshot). Use the following command to obtain the latest libopenshot source code.
+The first step in installing libopenshot is to obtain the most recent source code.
+The source code is available on [GitHub](https://github.com/OpenShot/libopenshot).
+Use the following command to obtain the latest libopenshot source code.
-```
+```sh
git clone https://github.com/OpenShot/libopenshot.git
git clone https://github.com/OpenShot/libopenshot-audio.git
```
@@ -79,27 +105,36 @@ git clone https://github.com/OpenShot/libopenshot-audio.git
The source code is divided up into the following folders.
#### `build/`
-This folder needs to be manually created, and is used by cmake to store the temporary build files, such as makefiles, as well as the final binaries (library and test executables).
+This folder needs to be manually created,
+and is used by cmake to store the build system control files and generated output
+(such as compiled object files and the result of template-file processing)
+as well as the final results of the build (library, tool, and test program binaries).
#### `cmake/`
This folder contains custom modules not included by default in cmake.
-CMake find modules are used to discover dependency libraries on the system, and to incorporate their headers and object files.
+CMake find modules are used to discover dependency libraries on the system,
+and to incorporate their headers and object files.
CMake code modules are used to implement build features such as test coverage scanning.
#### `doc/`
This folder contains documentation and related files.
This includes logos and images required by the doxygen-generated API documentation.
-#### `include/`
-This folder contains all headers (*.h) used by libopenshot.
-
#### `src/`
-This folder contains all source code (*.cpp) used by libopenshot.
+This folder contains all source code (`*.cpp`) and headers (`*.h`) for libopenshot.
+
+#### `bindings/`
+This folder contains language bindings for the libopenshot API.
+Current supported languages are Python and Ruby.
+
+#### `examples/`
+This folder contains various pieces of example code written in C++, Ruby, or Python.
+It also holds the media files (data files) used in examples and unit tests.
#### `tests/`
This folder contains all unit test code.
Each test file (`_Tests.cpp`) contains the tests for the named class.
-We use UnitTest++ macros to keep the test code simple and manageable.
+We use UnitTest++ macros to keep the test code uncomplicated and manageable.
#### `thirdparty/`
This folder contains code not written by the OpenShot team.
@@ -113,79 +148,91 @@ locates header files and libraries, and generates a build system in various form
We use CMake's Makefile generators to compile libopenshot and libopenshot-audio.
CMake uses an out-of-source build concept.
-This means that the build system, all temporary files, and all generated products are kept separate from the source code.
+This means that the build system,
+along with all temporary/intermediate files and generated products output during the build,
+is kept strictly separate from the source code.
This includes Makefiles, object files, and even the final binaries.
-While it is possible to build in-tree, we highly recommend you use a `/build/` sub-folder to compile each library.
-This prevents the build process from cluttering up the source
-code.
-These instructions have only been tested with the GNU compiler suite (including MSYS2/MinGW for Windows), and the Clang compiler (including AppleClang on MacOS).
+The source code files and directories are never modified by the build system,
+which makes it convenient and safe to re-run, reconfigure, or discard builds as needed.
+While it is possible to build in-tree,
+we highly recommend you use a `/build/` sub-folder to compile each library.
+
+These instructions have only been tested with the following compiler stacks:
+* The GNU compiler suite (including MSYS2/MinGW for Windows)
+* The Clang compiler (including AppleClang on MacOS)
+
+Other compilers, including MSVC, are entirely unsupported.
+It may be possible to build libopenshot using other compiler stacks,
+but most likely not without modifications to the build system which you would have to make yourself.
-## CMake Flags (Optional)
-There are many different build flags that can be passed to cmake to adjust how libopenshot is compiled. Some of these flags might be required when compiling on certain OSes, just depending on how your build environment is setup.
+### CMake Flags (Optional)
+There are many different build flags that can be passed to cmake to adjust how libopenshot is compiled.
+Some of these flags might be required when compiling on certain OSes,
+depending on how your build environment is setup.
To add a build flag, follow this general syntax:
```sh
-$ cmake -DMAGICKCORE_HDRI_ENABLE=1 -DENABLE_TESTS=1 ..
+cmake -B build -S . -DMAGICKCORE_HDRI_ENABLE=1 -DENABLE_TESTS=1 ...
```
Following are some of the flags you might need to set when generating your build system.
-##### Optional behavior:
-* `-DENABLE_TESTS=0` (default: `ON`)
-* `-DENABLE_COVERAGE=1` (default: `OFF`)
-* `-DENABLE_DOCS=0` (default: `ON` if doxygen found)
-
-##### Compiler configuration:
-* `-DCMAKE_BUILD_TYPE=Release`, `-DCMAKE_BUILD_TYPE=Debug` (default: `Debug` if unset)
-* `-DCMAKE_CXX_FLAGS="-Wall -Wextra"` (default: CMake builtin defaults for build type)
-* `-DCMAKE_CXX_COMPILER=/path/to/g++`, `-DCMAKE_CXX_COMPILER=/path/to/clang++`
-* `-DCMAKE_C_COMPILER=/path/to/gcc`, `-DCMAKE_CXX_COMPILER=/path/to/clang` (used by CMake for OS probes)
-
-##### Dependency configuration:
-* `-DCMAKE_PREFIX_PATH=/extra/path/to/search/for/libraries/`
-* `-DUSE_SYSTEM_JSONCPP=0` (default: auto if discovered)
-* `-DImageMagick_FOUND=0` (default: auto if discovered)
-
-##### To compile bindings for a specific Python installation:
-* `-DPYTHON_INCLUDE_DIR=/location/of/python/includes/`
-* `-DPYTHON_LIBRARY=/location/of/libpython*.so`
-* `-DPYTHON_FRAMEWORKS=/usr/local/Cellar/python3/3.3.2/Frameworks/Python.framework/` (MacOS only)
-
-##### Only used when building with ImageMagick enabled:
-* `-DMAGICKCORE_HDRI_ENABLE=1` (default `0`)
-* `-DMAGICKCORE_QUANTUM_DEPTH=8` (default `16`)
+#### Optional behaviors of the build system
+* `-DENABLE_TESTS=0` (default: `ON`)
+* `-DENABLE_COVERAGE=1` (default: `OFF`)
+* `-DENABLE_DOCS=0` (default: `ON` if doxygen found)
+* `-DENABLE_RUBY=0` (default: `ON` if SWIG and Ruby detected)
+* `-DENABLE_PYTHON=0` (default: `ON` if SWIG and Python detected)
+
+#### Options to configure the compiler
+* `-DCMAKE_BUILD_TYPE=Release`, `-DCMAKE_BUILD_TYPE=Debug` (default: `Release` if unset)
+* `-DCMAKE_CXX_FLAGS="-Wall -Wextra"` (default: CMake builtin defaults for build type)
+* `-DCMAKE_CXX_COMPILER=/path/to/g++`, `-DCMAKE_CXX_COMPILER=/path/to/clang++`
+* `-DCMAKE_C_COMPILER=/path/to/gcc`, `-DCMAKE_CXX_COMPILER=/path/to/clang` (used by CMake for OS probes)
+
+#### Options to configure dependencies
+* `-DCMAKE_PREFIX_PATH=/extra/path/to/search/for/libraries/`
+* `-DUSE_SYSTEM_JSONCPP=0` (default: auto if discovered)
+* `-DENABLE_MAGICK=0` (default: auto if discovered)
+
+#### Options to compile bindings for a specific Python installation
+* `-DPYTHON_INCLUDE_DIR=/location/of/python/includes/`
+* `-DPYTHON_LIBRARY=/location/of/libpython*.so`
+* `-DPYTHON_FRAMEWORKS=/usr/local/Cellar/python3/3.3.2/Frameworks/Python.framework/` (MacOS only)
+
+#### Options only relevant when building with ImageMagick
+* `-DMAGICKCORE_HDRI_ENABLE=1` (default `0`)
+* `-DMAGICKCORE_QUANTUM_DEPTH=8` (default `16`)
## Linux Build Instructions (libopenshot-audio)
-To compile libopenshot-audio, we need to go through a few additional steps to manually build and install it. Launch a terminal and enter:
+To compile libopenshot-audio, we need to build it from source code and install the results.
+Launch a terminal and enter:
-```
+```sh
cd [libopenshot-audio repo folder]
-mkdir build
-cd build
-cmake ../
-make
-make install
-./src/openshot-audio-test-sound (This should play a test sound)
+cmake -B build -S .
+cmake --build build
+./build/src/openshot-audio-test-sound (This should play a test sound)
+cmake --install build
```
## Linux Build Instructions (libopenshot)
Run the following commands to compile libopenshot:
-```
+```sh
cd [libopenshot repo directory]
-mkdir -p build
-cd build
-cmake ../
-make
-make install
+cmake -B build -S .
+cmake --build build
+cmake --build build --target test
+cmake --install build
```
For more detailed instructions, please see:
-* [doc/INSTALL-LINUX.md][INSTALL-LINUX]
-* [doc/INSTALL-MAC.md][INSTALL-MAC]
-* [doc/INSTALL-WINDOWS.md][INSTALL-WINDOWS]
+* [doc/INSTALL-LINUX.md][INSTALL-LINUX]
+* [doc/INSTALL-MAC.md][INSTALL-MAC]
+* [doc/INSTALL-WINDOWS.md][INSTALL-WINDOWS]
[INSTALL-LINUX]: https://github.com/OpenShot/libopenshot/blob/develop/doc/INSTALL-LINUX.md
[INSTALL-MAC]: https://github.com/OpenShot/libopenshot/blob/develop/doc/INSTALL-MAC.md
diff --git a/src/bindings/CMakeLists.txt b/bindings/CMakeLists.txt
similarity index 100%
rename from src/bindings/CMakeLists.txt
rename to bindings/CMakeLists.txt
diff --git a/src/bindings/python/CMakeLists.txt b/bindings/python/CMakeLists.txt
similarity index 97%
rename from src/bindings/python/CMakeLists.txt
rename to bindings/python/CMakeLists.txt
index 6d7ce79ea..b020592bd 100644
--- a/src/bindings/python/CMakeLists.txt
+++ b/bindings/python/CMakeLists.txt
@@ -50,11 +50,11 @@ include_directories(${PYTHON_INCLUDE_PATH})
if (CMAKE_VERSION VERSION_LESS 3.12)
### Include project headers
include_directories(
- "${PROJECT_SOURCE_DIR}/include"
- "${PROJECT_BINARY_DIR}/include")
+ "${PROJECT_SOURCE_DIR}/src"
+ "${PROJECT_BINARY_DIR}/src")
endif()
-### Enable C++ support in SWIG
+### Enable C++ in SWIG
set_property(SOURCE openshot.i PROPERTY CPLUSPLUS ON)
set_property(SOURCE openshot.i PROPERTY SWIG_MODULE_NAME openshot)
diff --git a/src/bindings/python/openshot.i b/bindings/python/openshot.i
similarity index 99%
rename from src/bindings/python/openshot.i
rename to bindings/python/openshot.i
index 53e514c15..e74b64940 100644
--- a/src/bindings/python/openshot.i
+++ b/bindings/python/openshot.i
@@ -237,5 +237,5 @@
%template(PointsVector) std::vector;
%template(FieldVector) std::vector;
%template(MappedFrameVector) std::vector;
-%template(MappedMetadata) std::map;
+%template(MetadataMap) std::map;
%template(AudioDeviceInfoVector) std::vector;
diff --git a/src/bindings/ruby/CMakeLists.txt b/bindings/ruby/CMakeLists.txt
similarity index 88%
rename from src/bindings/ruby/CMakeLists.txt
rename to bindings/ruby/CMakeLists.txt
index 2ec16dcf3..72d1a9857 100644
--- a/src/bindings/ruby/CMakeLists.txt
+++ b/bindings/ruby/CMakeLists.txt
@@ -46,11 +46,11 @@ endif()
option(SILENCE_RUBY_VERSION_WARNING
"Don't warn about possible SWIG incompatibilities with Ruby 2.7.0+" OFF)
-if (${RUBY_VERSION} VERSION_GREATER 2.6.9 AND ${SWIG_VERSION} VERSION_LESS 4.0.3)
+if (${RUBY_VERSION} VERSION_GREATER 2.6.9 AND ${SWIG_VERSION} VERSION_LESS 4.0.2)
if (NOT ${SILENCE_RUBY_VERSION_WARNING})
message(WARNING "\
Ruby 2.7.0+ detected, building the libopenshot Ruby API bindings \
-requires either SWIG 4.0.3 or an older version patched with this commit: \
+requires either SWIG 4.0.2+ or an older version patched with this commit: \
https://github.com/swig/swig/commit/5542cc228ad10bdc5c91107afb77c808c43bf2a4 \
(Recent Fedora and Ubuntu distro packages of SWIG 4.0.1 have already been \
patched.)")
@@ -64,19 +64,16 @@ endif()
include_directories(${RUBY_INCLUDE_DIRS})
if (CMAKE_VERSION VERSION_LESS 3.12)
- ### Include Ruby header files and project headers
+ ### Include project headers
include_directories(
- "${PROJECT_SOURCE_DIR}/include"
- "${PROJECT_BINARY_DIR}/include")
+ "${PROJECT_SOURCE_DIR}/src"
+ "${PROJECT_BINARY_DIR}/src")
endif()
### Enable C++ in SWIG
set_property(SOURCE openshot.i PROPERTY CPLUSPLUS ON)
set_property(SOURCE openshot.i PROPERTY SWIG_MODULE_NAME openshot)
-### Unbreak std::isfinite()
-add_definitions(-DHAVE_ISFINITE=1)
-
### Suppress a ton of warnings in the generated SWIG C++ code
set(SWIG_CXX_FLAGS "-Wno-unused-variable -Wno-unused-function \
-Wno-deprecated-copy -Wno-class-memaccess -Wno-cast-function-type \
@@ -99,6 +96,14 @@ else()
swig_add_library(rbopenshot LANGUAGE ruby SOURCES openshot.i)
endif()
+### Set name of target (with no prefix, since Ruby does not like that)
+# XXX: If this is not done exactly this way, the module builds as
+# e.g. rbopenshot.so, but its initializer method will be named
+# 'Init_openshot()' (via the module name set in the SWIG .i file).
+# Which leads to Ruby barfing when it attempts to load the module.
+set_target_properties(${SWIG_MODULE_rbopenshot_REAL_NAME} PROPERTIES
+ PREFIX "" OUTPUT_NAME "openshot")
+
### Link the new Ruby wrapper library with libopenshot
target_link_libraries(${SWIG_MODULE_rbopenshot_REAL_NAME} PUBLIC
${RUBY_LIBRARY} openshot)
diff --git a/src/bindings/ruby/openshot.i b/bindings/ruby/openshot.i
similarity index 94%
rename from src/bindings/ruby/openshot.i
rename to bindings/ruby/openshot.i
index 2f24d2200..b27510e20 100644
--- a/src/bindings/ruby/openshot.i
+++ b/bindings/ruby/openshot.i
@@ -42,23 +42,20 @@
%include "std_list.i"
%include "std_vector.i"
%include "std_map.i"
+%include
/* Unhandled STL Exception Handling */
%include
-namespace std {
- template class shared_ptr {
- public:
- T *operator->();
- };
-}
+/* Include shared pointer code */
+%include
/* Mark these classes as shared_ptr classes */
#ifdef USE_IMAGEMAGICK
- %template(SPtrImage) std::shared_ptr;
+ %shared_ptr(Magick::Image)
#endif
-%template(SPtrAudioBuffer) std::shared_ptr;
-%template(SPtrOpenFrame) std::shared_ptr;
+%shared_ptr(juce::AudioSampleBuffer)
+%shared_ptr(openshot::Frame)
%{
/* Ruby and FFmpeg define competing RSHIFT macros,
@@ -227,5 +224,5 @@ namespace std {
%template(PointsVector) std::vector;
%template(FieldVector) std::vector;
%template(MappedFrameVector) std::vector;
-%template(MappedMetadata) std::map;
+%template(MetadataMap) std::map;
%template(AudioDeviceInfoVector) std::vector;
diff --git a/cmake/Modules/FindOpenShotAudio.cmake b/cmake/Modules/FindOpenShotAudio.cmake
index a0cb9200c..4716112e3 100644
--- a/cmake/Modules/FindOpenShotAudio.cmake
+++ b/cmake/Modules/FindOpenShotAudio.cmake
@@ -11,12 +11,14 @@ endif()
# Find the libopenshot-audio header files (check env/cache vars first)
find_path(
- LIBOPENSHOT_AUDIO_INCLUDE_DIR
+ OpenShotAudio_INCLUDE_DIR
JuceHeader.h
HINTS
ENV LIBOPENSHOT_AUDIO_DIR
PATHS
${LIBOPENSHOT_AUDIO_DIR}
+ ${OpenShotAudio_ROOT}
+ ${OpenShotAudio_INCLUDE_DIR}
PATH_SUFFIXES
include/libopenshot-audio
libopenshot-audio
@@ -26,12 +28,14 @@ find_path(
# Find the libopenshot-audio header files (fallback to std. paths)
find_path(
- LIBOPENSHOT_AUDIO_INCLUDE_DIR
+ OpenShotAudio_INCLUDE_DIR
JuceHeader.h
HINTS
ENV LIBOPENSHOT_AUDIO_DIR
PATHS
${LIBOPENSHOT_AUDIO_DIR}
+ ${OpenShotAudio_ROOT}
+ ${OpenShotAudio_INCLUDE_DIR}
PATH_SUFFIXES
include/libopenshot-audio
libopenshot-audio
@@ -40,7 +44,7 @@ find_path(
# Find libopenshot-audio.so / libopenshot-audio.dll (check env/cache vars first)
find_library(
- LIBOPENSHOT_AUDIO_LIBRARY
+ OpenShotAudio_LIBRARY
NAMES
libopenshot-audio
openshot-audio
@@ -48,6 +52,8 @@ find_library(
ENV LIBOPENSHOT_AUDIO_DIR
PATHS
${LIBOPENSHOT_AUDIO_DIR}
+ ${OpenShotAudio_ROOT}
+ ${OpenShotAudio_LIBRARY}
PATH_SUFFIXES
lib/libopenshot-audio
libopenshot-audio
@@ -57,7 +63,7 @@ find_library(
# Find libopenshot-audio.so / libopenshot-audio.dll (fallback)
find_library(
- LIBOPENSHOT_AUDIO_LIBRARY
+ OpenShotAudio_LIBRARY
NAMES
libopenshot-audio
openshot-audio
@@ -65,39 +71,41 @@ find_library(
ENV LIBOPENSHOT_AUDIO_DIR
PATHS
${LIBOPENSHOT_AUDIO_DIR}
+ ${OpenShotAudio_ROOT}
+ ${OpenShotAudio_LIBRARY}
PATH_SUFFIXES
lib/libopenshot-audio
libopenshot-audio
lib
)
-set(LIBOPENSHOT_AUDIO_LIBRARIES "${LIBOPENSHOT_AUDIO_LIBRARY}")
-set(LIBOPENSHOT_AUDIO_LIBRARY "${LIBOPENSHOT_AUDIO_LIBRARIES}")
-set(LIBOPENSHOT_AUDIO_INCLUDE_DIRS "${LIBOPENSHOT_AUDIO_INCLUDE_DIR}")
+set(OpenShotAudio_LIBRARIES "${OpenShotAudio_LIBRARY}")
+set(OpenShotAudio_LIBRARY "${OpenShotAudio_LIBRARIES}")
+set(OpenShotAudio_INCLUDE_DIRS "${OpenShotAudio_INCLUDE_DIR}")
-if(LIBOPENSHOT_AUDIO_INCLUDE_DIR AND EXISTS "${LIBOPENSHOT_AUDIO_INCLUDE_DIR}/JuceHeader.h")
- file(STRINGS "${LIBOPENSHOT_AUDIO_INCLUDE_DIR}/JuceHeader.h" libosa_version_str
+if(OpenShotAudio_INCLUDE_DIR AND EXISTS "${OpenShotAudio_INCLUDE_DIR}/JuceHeader.h")
+ file(STRINGS "${OpenShotAudio_INCLUDE_DIR}/JuceHeader.h" libosa_version_str
REGEX "versionString.*=.*\"[^\"]+\"")
if(libosa_version_str MATCHES "versionString.*=.*\"([^\"]+)\"")
- set(LIBOPENSHOT_AUDIO_VERSION_STRING ${CMAKE_MATCH_1})
+ set(OpenShotAudio_VERSION_STRING ${CMAKE_MATCH_1})
endif()
unset(libosa_version_str)
string(REGEX REPLACE "^([0-9]+\.[0-9]+\.[0-9]+).*$" "\\1"
- LIBOPENSHOT_AUDIO_VERSION "${LIBOPENSHOT_AUDIO_VERSION_STRING}")
+ OpenShotAudio_VERSION "${OpenShotAudio_VERSION_STRING}")
endif()
# If we couldn't parse M.N.B version, don't keep any of it
-if(NOT LIBOPENSHOT_AUDIO_VERSION)
- unset(LIBOPENSHOT_AUDIO_VERSION)
- unset(LIBOPENSHOT_AUDIO_VERSION_STRING)
+if(NOT OpenShotAudio_VERSION)
+ unset(OpenShotAudio_VERSION)
+ unset(OpenShotAudio_VERSION_STRING)
endif()
# Determine compatibility with requested version in find_package()
-if(OpenShotAudio_FIND_VERSION AND LIBOPENSHOT_AUDIO_VERSION)
- if("${OpenShotAudio_FIND_VERSION}" STREQUAL "${LIBOPENSHOT_AUDIO_VERSION}")
+if(OpenShotAudio_FIND_VERSION AND OpenShotAudio_VERSION)
+ if("${OpenShotAudio_FIND_VERSION}" STREQUAL "${OpenShotAudio_VERSION}")
set(OpenShotAudio_VERSION_EXACT TRUE)
endif()
- if("${OpenShotAudio_FIND_VERSION}" VERSION_GREATER "${LIBOPENSHOT_AUDIO_VERSION}")
+ if("${OpenShotAudio_FIND_VERSION}" VERSION_GREATER "${OpenShotAudio_VERSION}")
set(OpenShotAudio_VERSION_COMPATIBLE FALSE)
else()
set(OpenShotAudio_VERSION_COMPATIBLE TRUE)
@@ -105,12 +113,76 @@ if(OpenShotAudio_FIND_VERSION AND LIBOPENSHOT_AUDIO_VERSION)
endif()
include(FindPackageHandleStandardArgs)
-# handle the QUIETLY and REQUIRED arguments and set LIBOPENSHOT_AUDIO_FOUND to TRUE
+# handle the QUIETLY and REQUIRED arguments and set OpenShotAudio_FOUND to TRUE
# if all listed variables are TRUE
find_package_handle_standard_args(OpenShotAudio
REQUIRED_VARS
- LIBOPENSHOT_AUDIO_LIBRARY
- LIBOPENSHOT_AUDIO_INCLUDE_DIRS
+ OpenShotAudio_LIBRARIES
+ OpenShotAudio_INCLUDE_DIRS
VERSION_VAR
- LIBOPENSHOT_AUDIO_VERSION_STRING
+ OpenShotAudio_VERSION_STRING
)
+
+if(OpenShotAudio_FOUND)
+ set(OpenShotAudio_INCLUDE_DIRS "${OpenShotAudio_INCLUDE_DIRS}"
+ CACHE PATH "The paths to libopenshot-audio's header files" FORCE)
+ set(OpenShotAudio_LIBRARIES "${OpenShotAudio_LIBRARIES}"
+ CACHE STRING "The libopenshot-audio library to link with" FORCE)
+ if(DEFINED OpenShotAudio_VERSION)
+ set(OpenShotAudio_VERSION ${OpenShotAudio_VERSION}
+ CACHE STRING "The version of libopenshot-audio detected" FORCE)
+ endif()
+endif()
+
+if(OpenShotAudio_FOUND AND NOT TARGET OpenShot::Audio)
+ message(STATUS "Creating IMPORTED target OpenShot::Audio")
+ if(WIN32)
+ add_library(OpenShot::Audio UNKNOWN IMPORTED)
+ else()
+ add_library(OpenShot::Audio SHARED IMPORTED)
+ endif()
+
+ set_property(TARGET OpenShot::Audio APPEND PROPERTY
+ INTERFACE_INCLUDE_DIRECTORIES "${OpenShotAudio_INCLUDE_DIRS}")
+
+ # Juce requires either DEBUG or NDEBUG to be defined on MacOS.
+ # -DNDEBUG is set by cmake for all release configs, so add
+ # -DDEBUG for debug builds. We'll do this for all OSes, even
+ # though only MacOS requires it.
+ # The generator expression translates to:
+ # CONFIG == "DEBUG" ? "DEBUG" : ""
+ set_property(TARGET OpenShot::Audio APPEND PROPERTY
+ INTERFACE_COMPILE_DEFINITIONS $<$:DEBUG>)
+
+ # For the Ruby bindings
+ set_property(TARGET OpenShot::Audio APPEND PROPERTY
+ INTERFACE_COMPILE_DEFINITIONS HAVE_ISFINITE=1)
+
+ if(WIN32)
+ set_property(TARGET OpenShot::Audio APPEND PROPERTY
+ INTERFACE_COMPILE_DEFINITIONS IGNORE_JUCE_HYPOT=1)
+ set_property(TARGET OpenShot::Audio APPEND PROPERTY
+ INTERFACE_COMPILE_OPTIONS -include cmath)
+ elseif(APPLE)
+ # Prevent compiling with __cxx11
+ set_property(TARGET OpenShot::Audio APPEND PROPERTY
+ INTERFACE_COMPILE_DEFINITIONS _GLIBCXX_USE_CXX11_ABI=0)
+ list(APPEND framework_deps
+ "-framework Carbon"
+ "-framework Cocoa"
+ "-framework CoreFoundation"
+ "-framework CoreAudio"
+ "-framework CoreMidi"
+ "-framework IOKit"
+ "-framework AGL"
+ "-framework AudioToolbox"
+ "-framework QuartzCore"
+ "-lobjc"
+ "-framework Accelerate"
+ )
+ target_link_libraries(OpenShot::Audio INTERFACE ${framework_deps})
+ endif()
+
+ set_property(TARGET OpenShot::Audio APPEND PROPERTY
+ IMPORTED_LOCATION "${OpenShotAudio_LIBRARIES}")
+endif()
diff --git a/cmake/Modules/FindRESVG.cmake b/cmake/Modules/FindResvg.cmake
similarity index 59%
rename from cmake/Modules/FindRESVG.cmake
rename to cmake/Modules/FindResvg.cmake
index 0538eacd5..452a81c8b 100644
--- a/cmake/Modules/FindRESVG.cmake
+++ b/cmake/Modules/FindResvg.cmake
@@ -1,13 +1,13 @@
# vim: ts=2 sw=2
#[=======================================================================[.rst:
-FindRESVG
+FindResvg
---------
Try to find the shared-library build of resvg, the Rust SVG library
IMPORTED targets
^^^^^^^^^^^^^^^^
-This module defines :prop_tgt:`IMPORTED` target ``RESVG::resvg`` when
+This module defines :prop_tgt:`IMPORTED` target ``Resvg::Resvg`` when
the library and headers are found.
Result Variables
@@ -17,10 +17,10 @@ This module defines the following variables:
::
- RESVG_FOUND - Library and header files found
- RESVG_INCLUDE_DIRS - Include directory path
- RESVG_LIBRARIES - Link path to the library
- RESVG_DEFINITIONS - Compiler switches (currently unused)
+ Resvg_FOUND - Library and header files found
+ Resvg_INCLUDE_DIRS - Include directory path
+ Resvg_LIBRARIES - Link path to the library
+ Resvg_DEFINITIONS - Compiler switches (currently unused)
Backwards compatibility
^^^^^^^^^^^^^^^^^^^^^^^
@@ -47,7 +47,7 @@ if(DEFINED RESVGDIR AND CMAKE_VERSION VERSION_GREATER 3.4)
BASE_DIR ${CMAKE_CURRENT_BINARY_DIR})
endif()
-find_path(RESVG_INCLUDE_DIRS
+find_path(Resvg_INCLUDE_DIRS
ResvgQt.h
PATHS
${RESVGDIR}
@@ -62,7 +62,7 @@ find_path(RESVG_INCLUDE_DIRS
resvg/capi/include
)
-find_library(RESVG_LIBRARIES
+find_library(Resvg_LIBRARIES
NAMES resvg
PATHS
${RESVGDIR}
@@ -77,39 +77,39 @@ find_library(RESVG_LIBRARIES
resvg/target/release
)
-if (RESVG_INCLUDE_DIRS AND RESVG_LIBRARIES)
- set(RESVG_FOUND TRUE)
+if (Resvg_INCLUDE_DIRS AND Resvg_LIBRARIES)
+ set(Resvg_FOUND TRUE)
endif()
-set(RESVG_LIBRARIES ${RESVG_LIBRARIES} CACHE STRING "The Resvg library link path")
-set(RESVG_INCLUDE_DIRS ${RESVG_INCLUDE_DIRS} CACHE STRING "The Resvg include directories")
-set(RESVG_DEFINITIONS "" CACHE STRING "The Resvg CFLAGS")
+set(Resvg_LIBRARIES ${Resvg_LIBRARIES} CACHE STRING "The Resvg library link path")
+set(Resvg_INCLUDE_DIRS ${Resvg_INCLUDE_DIRS} CACHE STRING "The Resvg include directories")
+set(Resvg_DEFINITIONS "" CACHE STRING "The Resvg CFLAGS")
-mark_as_advanced(RESVG_LIBRARIES RESVG_INCLUDE_DIRS RESVG_DEFINITIONS)
+mark_as_advanced(Resvg_LIBRARIES Resvg_INCLUDE_DIRS Resvg_DEFINITIONS)
# Give a nice error message if some of the required vars are missing.
-find_package_handle_standard_args(RESVG
- "Could NOT find RESVG, using Qt SVG parsing instead"
- RESVG_LIBRARIES RESVG_INCLUDE_DIRS )
+find_package_handle_standard_args(Resvg
+ "Could NOT find Resvg, using Qt SVG parsing instead"
+ Resvg_LIBRARIES Resvg_INCLUDE_DIRS )
# Export target
-if(RESVG_FOUND AND NOT TARGET RESVG::resvg)
- message(STATUS "Creating IMPORTED target RESVG::resvg")
+if(Resvg_FOUND AND NOT TARGET Resvg::Resvg)
+ message(STATUS "Creating IMPORTED target Resvg::Resvg")
if (WIN32)
# Windows mis-links SHARED library targets
- add_library(RESVG::resvg UNKNOWN IMPORTED)
+ add_library(Resvg::Resvg UNKNOWN IMPORTED)
else()
# Linux needs SHARED to link because libresvg has no SONAME
- add_library(RESVG::resvg SHARED IMPORTED)
- set_property(TARGET RESVG::resvg APPEND PROPERTY
+ add_library(Resvg::Resvg SHARED IMPORTED)
+ set_property(TARGET Resvg::Resvg APPEND PROPERTY
IMPORTED_NO_SONAME TRUE)
endif()
- set_property(TARGET RESVG::resvg APPEND PROPERTY
- INTERFACE_INCLUDE_DIRECTORIES "${RESVG_INCLUDE_DIRS}")
+ set_property(TARGET Resvg::Resvg APPEND PROPERTY
+ INTERFACE_INCLUDE_DIRECTORIES "${Resvg_INCLUDE_DIRS}")
- set_property(TARGET RESVG::resvg APPEND PROPERTY
- INTERFACE_COMPILE_DEFINITIONS "${RESVG_DEFINITIONS}")
+ set_property(TARGET Resvg::Resvg APPEND PROPERTY
+ INTERFACE_COMPILE_DEFINITIONS "${Resvg_DEFINITIONS}")
- set_property(TARGET RESVG::resvg APPEND PROPERTY
- IMPORTED_LOCATION "${RESVG_LIBRARIES}")
+ set_property(TARGET Resvg::Resvg APPEND PROPERTY
+ IMPORTED_LOCATION "${Resvg_LIBRARIES}")
endif()
diff --git a/codecov.yml b/codecov.yml
index ee151daaf..e00103e78 100644
--- a/codecov.yml
+++ b/codecov.yml
@@ -7,10 +7,11 @@ coverage:
base: pr # Only post a status to pull requests
informational: true # Don't block PRs based on coverage stats (yet?)
ignore:
- - "/src/examples"
- - "/src/Qt/demo"
- - "/thirdparty/jsoncpp/*.cpp"
- - "/thirdparty/jsoncpp/json/*.h"
+ - "/examples"
+ - "/bindings"
+ - "/thirdparty/jsoncpp"
- "/doc"
- "/cmake"
- "/*.md"
+ - "bindings"
+ - "src/openshot_autogen"
diff --git a/examples/CMakeLists.txt b/examples/CMakeLists.txt
new file mode 100644
index 000000000..874751288
--- /dev/null
+++ b/examples/CMakeLists.txt
@@ -0,0 +1,65 @@
+####################### CMakeLists.txt (libopenshot) #########################
+# @brief CMake build file for libopenshot (used to generate makefiles)
+# @author Jonathan Thomas
+# @author FeRD (Frank Dana)
+#
+# @section LICENSE
+#
+# Copyright (c) 2008-2020 OpenShot Studios, LLC
+# . This file is part of
+# OpenShot Library (libopenshot), an open-source project dedicated to
+# delivering high quality video editing and animation solutions to the
+# world. For more information visit .
+#
+# OpenShot Library (libopenshot) is free software: you can redistribute it
+# and/or modify it under the terms of the GNU Lesser General Public License
+# as published by the Free Software Foundation, either version 3 of the
+# License, or (at your option) any later version.
+#
+# OpenShot Library (libopenshot) 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 Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with OpenShot Library. If not, see .
+################################################################################
+
+include(GNUInstallDirs)
+
+# Dependencies
+find_package(Qt5 COMPONENTS Gui REQUIRED)
+
+############### CLI EXECUTABLES ################
+# Create test executable
+add_executable(openshot-example Example.cpp)
+
+# Define path to test input files
+file(TO_NATIVE_PATH "${PROJECT_SOURCE_DIR}/examples/" TEST_MEDIA_PATH)
+target_compile_definitions(openshot-example PRIVATE
+ -DTEST_MEDIA_PATH="${TEST_MEDIA_PATH}" )
+
+# Link test executable to the new library
+target_link_libraries(openshot-example openshot)
+
+add_executable(openshot-html-test ExampleHtml.cpp)
+target_link_libraries(openshot-html-test openshot Qt5::Gui)
+
+############### PLAYER EXECUTABLE ################
+# Create test executable
+add_executable(openshot-player qt-demo/main.cpp)
+
+set_target_properties(openshot-player PROPERTIES AUTOMOC ON)
+
+# Link test executable to the new library
+target_link_libraries(openshot-player openshot)
+
+############### TEST BLACKMAGIC CAPTURE APP ################
+if (BLACKMAGIC_FOUND)
+ # Create test executable
+ add_executable(openshot-blackmagic
+ examples/ExampleBlackmagic.cpp)
+
+ # Link test executable to the new library
+ target_link_libraries(openshot-blackmagic openshot)
+endif()
diff --git a/src/examples/Example.cpp b/examples/Example.cpp
similarity index 97%
rename from src/examples/Example.cpp
rename to examples/Example.cpp
index c9e616288..2cd770712 100644
--- a/src/examples/Example.cpp
+++ b/examples/Example.cpp
@@ -31,8 +31,8 @@
#include
#include
#include
-#include "../../include/OpenShot.h"
-#include "../../include/CrashHandler.h"
+#include "OpenShot.h"
+#include "CrashHandler.h"
using namespace openshot;
diff --git a/src/examples/Example.py b/examples/Example.py
similarity index 100%
rename from src/examples/Example.py
rename to examples/Example.py
diff --git a/src/examples/Example.rb b/examples/Example.rb
similarity index 66%
rename from src/examples/Example.rb
rename to examples/Example.rb
index 7d2e4e1aa..5e4c79409 100644
--- a/src/examples/Example.rb
+++ b/examples/Example.rb
@@ -1,13 +1,13 @@
# Find and load the ruby libopenshot wrapper library
-require "./openshot"
+require "openshot"
# Create a new FFmpegReader and Open it
-r = OpenShot::FFmpegReader.new("myfile.mp4")
+r = Openshot::FFmpegReader.new("test.mp4")
r.Open()
# Get frame 1
f = r.GetFrame(1)
# Display the frame
-r.Display()
+f.Display()
diff --git a/src/examples/ExampleBlackmagic.cpp b/examples/ExampleBlackmagic.cpp
similarity index 100%
rename from src/examples/ExampleBlackmagic.cpp
rename to examples/ExampleBlackmagic.cpp
diff --git a/src/examples/ExampleHtml.cpp b/examples/ExampleHtml.cpp
similarity index 97%
rename from src/examples/ExampleHtml.cpp
rename to examples/ExampleHtml.cpp
index 576961bc5..928a05fe8 100644
--- a/src/examples/ExampleHtml.cpp
+++ b/examples/ExampleHtml.cpp
@@ -35,8 +35,8 @@
#include
#include
-#include "../../include/OpenShot.h"
-#include "../../include/CrashHandler.h"
+#include "OpenShot.h"
+#include "CrashHandler.h"
using namespace openshot;
diff --git a/src/examples/ExampleHtml.py b/examples/ExampleHtml.py
similarity index 100%
rename from src/examples/ExampleHtml.py
rename to examples/ExampleHtml.py
diff --git a/src/examples/OpenShot Wipe Tests.py b/examples/OpenShot Wipe Tests.py
similarity index 100%
rename from src/examples/OpenShot Wipe Tests.py
rename to examples/OpenShot Wipe Tests.py
diff --git a/src/examples/back.png b/examples/back.png
similarity index 100%
rename from src/examples/back.png
rename to examples/back.png
diff --git a/src/examples/final-composite.png b/examples/final-composite.png
similarity index 100%
rename from src/examples/final-composite.png
rename to examples/final-composite.png
diff --git a/src/examples/front.png b/examples/front.png
similarity index 100%
rename from src/examples/front.png
rename to examples/front.png
diff --git a/src/examples/front3.png b/examples/front3.png
similarity index 100%
rename from src/examples/front3.png
rename to examples/front3.png
diff --git a/src/examples/interlaced.png b/examples/interlaced.png
similarity index 100%
rename from src/examples/interlaced.png
rename to examples/interlaced.png
diff --git a/src/examples/mask.png b/examples/mask.png
similarity index 100%
rename from src/examples/mask.png
rename to examples/mask.png
diff --git a/src/examples/mask2.png b/examples/mask2.png
similarity index 100%
rename from src/examples/mask2.png
rename to examples/mask2.png
diff --git a/src/examples/output-final.png b/examples/output-final.png
similarity index 100%
rename from src/examples/output-final.png
rename to examples/output-final.png
diff --git a/src/examples/piano-mono.wav b/examples/piano-mono.wav
similarity index 100%
rename from src/examples/piano-mono.wav
rename to examples/piano-mono.wav
diff --git a/src/examples/piano.wav b/examples/piano.wav
similarity index 100%
rename from src/examples/piano.wav
rename to examples/piano.wav
diff --git a/src/Qt/demo/main.cpp b/examples/qt-demo/main.cpp
similarity index 96%
rename from src/Qt/demo/main.cpp
rename to examples/qt-demo/main.cpp
index 3e5f00bab..8c02795ab 100644
--- a/src/Qt/demo/main.cpp
+++ b/examples/qt-demo/main.cpp
@@ -28,7 +28,9 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../../include/Qt/PlayerDemo.h"
+#include "Qt/PlayerDemo.h"
+
+#include
int main(int argc, char *argv[])
{
diff --git a/src/examples/sintel_trailer-720p.mp4 b/examples/sintel_trailer-720p.mp4
similarity index 100%
rename from src/examples/sintel_trailer-720p.mp4
rename to examples/sintel_trailer-720p.mp4
diff --git a/src/examples/test.mp4 b/examples/test.mp4
similarity index 100%
rename from src/examples/test.mp4
rename to examples/test.mp4
diff --git a/src/examples/test.wav b/examples/test.wav
similarity index 100%
rename from src/examples/test.wav
rename to examples/test.wav
diff --git a/src/examples/test1.mp4 b/examples/test1.mp4
similarity index 100%
rename from src/examples/test1.mp4
rename to examples/test1.mp4
diff --git a/src/AudioBufferSource.cpp b/src/AudioBufferSource.cpp
index 69e5713ad..6b2bc59e2 100644
--- a/src/AudioBufferSource.cpp
+++ b/src/AudioBufferSource.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/AudioBufferSource.h"
+#include "AudioBufferSource.h"
using namespace std;
using namespace openshot;
diff --git a/include/AudioBufferSource.h b/src/AudioBufferSource.h
similarity index 100%
rename from include/AudioBufferSource.h
rename to src/AudioBufferSource.h
diff --git a/include/AudioDeviceInfo.h b/src/AudioDeviceInfo.h
similarity index 100%
rename from include/AudioDeviceInfo.h
rename to src/AudioDeviceInfo.h
diff --git a/src/AudioReaderSource.cpp b/src/AudioReaderSource.cpp
index 999d109d2..b6a01a890 100644
--- a/src/AudioReaderSource.cpp
+++ b/src/AudioReaderSource.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/AudioReaderSource.h"
+#include "AudioReaderSource.h"
using namespace std;
using namespace openshot;
diff --git a/include/AudioReaderSource.h b/src/AudioReaderSource.h
similarity index 100%
rename from include/AudioReaderSource.h
rename to src/AudioReaderSource.h
diff --git a/src/AudioResampler.cpp b/src/AudioResampler.cpp
index 145f5d91f..8c27043e5 100644
--- a/src/AudioResampler.cpp
+++ b/src/AudioResampler.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/AudioResampler.h"
+#include "AudioResampler.h"
using namespace std;
using namespace openshot;
diff --git a/include/AudioResampler.h b/src/AudioResampler.h
similarity index 100%
rename from include/AudioResampler.h
rename to src/AudioResampler.h
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 04121c225..f8bd44363 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -34,88 +34,6 @@ if (POLICY CMP0057)
cmake_policy(SET CMP0057 NEW)
endif()
-# Juce requires either DEBUG or NDEBUG to be defined on MacOS.
-# -DNDEBUG is set by cmake for all release configs, so add
-# -DDEBUG for debug builds. We'll do this for all OSes, even
-# though only MacOS requires it.
-set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DDEBUG")
-# Make sure we've picked some build type, default to debug
-if(NOT DEFINED CMAKE_BUILD_TYPE OR CMAKE_BUILD_TYPE STREQUAL "")
- set(CMAKE_BUILD_TYPE "Debug")
-endif()
-
-################ WINDOWS ##################
-# Set some compiler options for Windows
-# required for libopenshot-audio headers
-if (WIN32)
- add_definitions( -DIGNORE_JUCE_HYPOT=1 )
- set(CMAKE_CXX_FLAGS " ${CMAKE_CXX_FLAGS} -include cmath")
-endif()
-
-if (APPLE)
- # If you still get errors compiling with GCC 4.8, mac headers need to be patched: http://hamelot.co.uk/programming/osx-gcc-dispatch_block_t-has-not-been-declared-invalid-typedef/
- set_property(GLOBAL PROPERTY JUCE_MAC "JUCE_MAC")
- set(EXTENSION "mm")
- set(JUCE_PLATFORM_SPECIFIC_DIR build/macosx/platform_specific_code)
- set(JUCE_PLATFORM_SPECIFIC_LIBRARIES "-framework Carbon -framework Cocoa -framework CoreFoundation -framework CoreAudio -framework CoreMidi -framework IOKit -framework AGL -framework AudioToolbox -framework QuartzCore -lobjc -framework Accelerate")
-
- # Prevent compiling with __cxx11
- add_definitions(-D_GLIBCXX_USE_CXX11_ABI=0)
-endif()
-
-################ IMAGE MAGICK ##################
-# Set the Quantum Depth that ImageMagick was built with (default to 16 bits)
-if(ENABLE_MAGICK)
- IF (MAGICKCORE_QUANTUM_DEPTH)
- add_definitions( -DMAGICKCORE_QUANTUM_DEPTH=${MAGICKCORE_QUANTUM_DEPTH} )
- ELSE (MAGICKCORE_QUANTUM_DEPTH)
- add_definitions( -DMAGICKCORE_QUANTUM_DEPTH=16 )
- ENDIF (MAGICKCORE_QUANTUM_DEPTH)
- IF (MAGICKCORE_HDRI_ENABLE)
- add_definitions( -DMAGICKCORE_HDRI_ENABLE=${MAGICKCORE_HDRI_ENABLE} )
- ELSE (MAGICKCORE_HDRI_ENABLE)
- add_definitions( -DMAGICKCORE_HDRI_ENABLE=0 )
- ENDIF (MAGICKCORE_HDRI_ENABLE)
-
- # Find the ImageMagick++ library
- find_package(ImageMagick COMPONENTS Magick++ MagickWand MagickCore)
- if (ImageMagick_FOUND)
- # Include ImageMagick++ headers (needed for compile)
- include_directories(${ImageMagick_INCLUDE_DIRS})
-
- # define a global var (used in the C++)
- add_definitions( -DUSE_IMAGEMAGICK=1 )
- list(APPEND CMAKE_SWIG_FLAGS "-DUSE_IMAGEMAGICK=1")
-
- set(HAVE_IMAGEMAGICK TRUE CACHE BOOL "Building with ImageMagick support" FORCE)
- mark_as_advanced(HAVE_IMAGEMAGICK)
- endif()
-endif()
-
-################# LIBOPENSHOT-AUDIO ###################
-# Find JUCE-based openshot Audio libraries
-find_package(OpenShotAudio 0.2.0 REQUIRED)
-
-# Include Juce headers (needed for compile)
-include_directories(${LIBOPENSHOT_AUDIO_INCLUDE_DIRS})
-
-################# BLACKMAGIC DECKLINK ###################
-# Find BlackMagic DeckLinkAPI libraries
-if (ENABLE_BLACKMAGIC)
-
- find_package(BlackMagic)
-
- if (BLACKMAGIC_FOUND)
- # Include Blackmagic headers (needed for compile)
- include_directories(${BLACKMAGIC_INCLUDE_DIR})
-
- # define a global var (used in the C++)
- add_definitions( -DUSE_BLACKMAGIC=1 )
- list(APPEND CMAKE_SWIG_FLAGS "-DUSE_BLACKMAGIC=1")
- endif()
-
-endif()
-
############### PROFILING #################
#set(PROFILER "/usr/lib/libprofiler.so.0.3.2")
#set(PROFILER "/usr/lib/libtcmalloc.so.4")
@@ -207,9 +125,6 @@ set(QT_PLAYER_SOURCES
Qt/VideoRenderer.cpp
Qt/VideoRenderWidget.cpp)
-# Get list of MOC'able headers
-file(GLOB_RECURSE OPENSHOT_QT_HEADERS ${CMAKE_SOURCE_DIR}/include/Qt/*.h)
-
# Disable RPATH
set(CMAKE_MACOSX_RPATH 0)
@@ -221,7 +136,6 @@ target_sources(openshot PRIVATE
${OPENSHOT_SOURCES}
${EFFECTS_SOURCES}
${QT_PLAYER_SOURCES}
- ${OPENSHOT_QT_HEADERS}
)
# Set SONAME and other library properties
@@ -230,34 +144,77 @@ set_target_properties(openshot PROPERTIES
VERSION ${PROJECT_VERSION}
SOVERSION ${PROJECT_SO_VERSION}
INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib"
- )
+)
+
+# Location of our includes, both internally and when installed
+target_include_directories(openshot
+ PRIVATE
+ ${CMAKE_CURRENT_SOURCE_DIR}
+ ${CMAKE_CURRENT_BINARY_DIR}
+ PUBLIC
+ $
+ $
+ $)
+
+################# LIBOPENSHOT-AUDIO ###################
+# Find JUCE-based openshot Audio libraries
+find_package(OpenShotAudio 0.2.0 REQUIRED)
+target_link_libraries(openshot PUBLIC OpenShot::Audio)
+
+###
+### ImageMagick
+###
+
+# Find the ImageMagick++ library
+find_package(ImageMagick COMPONENTS Magick++ MagickWand MagickCore)
-# Add optional ImageMagic-dependent sources
if(ImageMagick_FOUND)
+ if(NOT TARGET ImageMagick::Magick++ AND NOT TARGET Magick++_TARGET)
+ add_library(Magick++_TARGET INTERFACE)
+
+ # Include ImageMagick++ headers (needed for compile)
+ set_property(TARGET Magick++_TARGET APPEND PROPERTY
+ INTERFACE_INCLUDE_DIRECTORIES ${ImageMagick_INCLUDE_DIRS})
+
+ # Set the Quantum Depth that ImageMagick was built with (default to 16 bits)
+ if(NOT DEFINED MAGICKCORE_QUANTUM_DEPTH)
+ set(MAGICKCORE_QUANTUM_DEPTH 16)
+ endif()
+ if(NOT DEFINED MAGICKCORE_HDRI_ENABLE)
+ set(MAGICKCORE_HDRI_ENABLE 0)
+ endif()
+
+ set_property(TARGET Magick++_TARGET APPEND PROPERTY
+ INTERFACE_COMPILE_DEFINITIONS
+ MAGICKCORE_QUANTUM_DEPTH=${MAGICKCORE_QUANTUM_DEPTH})
+ set_property(TARGET Magick++_TARGET APPEND PROPERTY
+ INTERFACE_COMPILE_DEFINITIONS
+ MAGICKCORE_HDRI_ENABLE=${MAGICKCORE_HDRI_ENABLE})
+
+ target_link_libraries(Magick++_TARGET INTERFACE
+ ${ImageMagick_LIBRARIES})
+
+ # Alias to our namespaced name
+ add_library(ImageMagick::Magick++ ALIAS Magick++_TARGET)
+
+ endif()
+
+ # Add optional ImageMagic-dependent sources
target_sources(openshot PRIVATE
ImageReader.cpp
ImageWriter.cpp
TextReader.cpp)
-endif()
-# BlackMagic related files
-if(BLACKMAGIC_FOUND)
- target_sources(openshot PRIVATE
- DecklinkInput.cpp
- DecklinkReader.cpp
- DecklinkOutput.cpp
- DecklinkWriter.cpp)
-endif()
+ # define a preprocessor macro (used in the C++ source)
+ target_compile_definitions(openshot PUBLIC USE_IMAGEMAGICK=1)
+ list(APPEND CMAKE_SWIG_FLAGS -DUSE_IMAGEMAGICK=1)
-# Location of our includes, both internally and when installed
-target_include_directories(openshot
- PRIVATE
- ${CMAKE_SOURCE_DIR}/include
- ${CMAKE_BINARY_DIR}/include
- PUBLIC
- $
- $
- $)
+ # Link with ImageMagick library
+ target_link_libraries(openshot PUBLIC ImageMagick::Magick++)
+
+ set(HAVE_IMAGEMAGICK TRUE CACHE BOOL "Building with ImageMagick support" FORCE)
+ mark_as_advanced(HAVE_IMAGEMAGICK)
+endif()
################### JSONCPP #####################
@@ -344,7 +301,10 @@ endif()
target_link_libraries(openshot PUBLIC OpenMP::OpenMP_CXX)
-################### ZEROMQ #####################
+###
+### ZeroMQ
+###
+
# Find ZeroMQ library (used for socket communication & logging)
find_package(ZeroMQ REQUIRED) # Creates libzmq target
@@ -361,43 +321,62 @@ if (TARGET cppzmq)
target_link_libraries(openshot PUBLIC cppzmq)
endif()
-################### RESVG #####################
+###
+### Resvg, the Rust SVG library
+###
+
# Migrate some legacy variable names
-if(DEFINED RESVGDIR AND NOT DEFINED RESVG_ROOT)
- set(RESVG_ROOT ${RESVGDIR})
+if(DEFINED RESVGDIR AND NOT DEFINED Resvg_ROOT)
+ set(Resvg_ROOT ${RESVGDIR})
endif()
-if(DEFINED ENV{RESVGDIR} AND NOT DEFINED RESVG_ROOT)
- set(RESVG_ROOT $ENV{RESVGDIR})
+if(DEFINED ENV{RESVGDIR} AND NOT DEFINED Resvg_ROOT)
+ set(Resvg_ROOT $ENV{RESVGDIR})
endif()
# Find resvg library (used for rendering svg files)
-find_package(RESVG)
+find_package(Resvg)
# Include resvg headers (optional SVG library)
-if (TARGET RESVG::resvg)
- #include_directories(${RESVG_INCLUDE_DIRS})
- target_link_libraries(openshot PUBLIC RESVG::resvg)
+if (TARGET Resvg::Resvg)
+ #include_directories(${Resvg_INCLUDE_DIRS})
+ target_link_libraries(openshot PUBLIC Resvg::Resvg)
- target_compile_definitions(openshot PUBLIC "-DUSE_RESVG=1")
- list(APPEND CMAKE_SWIG_FLAGS "-DUSE_RESVG=1")
+ target_compile_definitions(openshot PUBLIC -DUSE_RESVG=1)
+ list(APPEND CMAKE_SWIG_FLAGS -DUSE_RESVG=1)
set(HAVE_RESVG TRUE CACHE BOOL "Building with Resvg support" FORCE)
mark_as_advanced(HAVE_RESVG)
-
endif()
-############### LINK LIBRARY #################
-# Link remaining dependency libraries
-target_link_libraries(openshot PUBLIC
- ${LIBOPENSHOT_AUDIO_LIBRARIES}
- ${PROFILER})
+################# BLACKMAGIC DECKLINK ###################
+# Find BlackMagic DeckLinkAPI libraries
+if (ENABLE_BLACKMAGIC)
+ find_package(BlackMagic)
-if(ImageMagick_FOUND)
- target_link_libraries(openshot PUBLIC ${ImageMagick_LIBRARIES})
+ if (BLACKMAGIC_FOUND)
+ # BlackMagic related files
+ target_sources(openshot PRIVATE
+ DecklinkInput.cpp
+ DecklinkReader.cpp
+ DecklinkOutput.cpp
+ DecklinkWriter.cpp)
+
+ # Include Blackmagic headers (needed for compile)
+ target_include_directories(openshot PRIVATE ${BLACKMAGIC_INCLUDE_DIR})
+
+ # Link libopenshot with BlackMagic libs
+ target_link_libraries(openshot PUBLIC ${BLACKMAGIC_LIBRARY_DIR})
+
+ # define a preprocessor macro (used in the C++)
+ target_compile_definitions(openshot PUBLIC -DUSE_BLACKMAGIC=1)
+ list(APPEND CMAKE_SWIG_FLAGS -DUSE_BLACKMAGIC=1)
+ endif()
endif()
-if(BLACKMAGIC_FOUND)
- target_link_libraries(openshot PUBLIC ${BLACKMAGIC_LIBRARY_DIR})
+############### LINK LIBRARY #################
+# Link remaining dependency libraries
+if(DEFINED PROFILER)
+ target_link_libraries(openshot PUBLIC ${PROFILER})
endif()
if(WIN32)
@@ -405,56 +384,22 @@ if(WIN32)
target_link_libraries(openshot PUBLIC "imagehlp" "dbghelp" )
endif()
-
-############### CLI EXECUTABLES ################
-# Create test executable
-add_executable(openshot-example examples/Example.cpp)
-
-# Define path to test input files
-set(TEST_MEDIA_PATH "${PROJECT_SOURCE_DIR}/src/examples/")
-if (WIN32)
- string(REPLACE "/" "\\\\" TEST_MEDIA_PATH TEST_MEDIA_PATH)
-endif()
-target_compile_definitions(openshot-example PRIVATE
- -DTEST_MEDIA_PATH="${TEST_MEDIA_PATH}" )
-
-# Link test executable to the new library
-target_link_libraries(openshot-example openshot)
-
-add_executable(openshot-html-test examples/ExampleHtml.cpp)
-target_link_libraries(openshot-html-test openshot Qt5::Gui)
-
-############### PLAYER EXECUTABLE ################
-# Create test executable
-add_executable(openshot-player Qt/demo/main.cpp)
-
-# Link test executable to the new library
-target_link_libraries(openshot-player openshot)
-
-############### TEST BLACKMAGIC CAPTURE APP ################
-if (BLACKMAGIC_FOUND)
- # Create test executable
- add_executable(openshot-blackmagic
- examples/ExampleBlackmagic.cpp)
-
- # Link test executable to the new library
- target_link_libraries(openshot-blackmagic openshot)
-endif()
-
-############### INCLUDE SWIG BINDINGS ################
-add_subdirectory(bindings)
-
-############### INSTALL HEADERS & LIBRARY ################
+###
+### INSTALL HEADERS & LIBRARY
+###
# Install primary library
install(TARGETS openshot
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
- RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR})
+ RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
+ INCLUDES DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/libopenshot)
-install(DIRECTORY ${CMAKE_SOURCE_DIR}/include/
+install(
+ DIRECTORY .
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/libopenshot
- FILES_MATCHING PATTERN "*.h")
+ FILES_MATCHING PATTERN "*.h"
+)
############### CPACK PACKAGING ##############
if(MINGW)
diff --git a/src/CacheBase.cpp b/src/CacheBase.cpp
index bc57f3f45..72381792c 100644
--- a/src/CacheBase.cpp
+++ b/src/CacheBase.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/CacheBase.h"
+#include "CacheBase.h"
using namespace std;
using namespace openshot;
diff --git a/include/CacheBase.h b/src/CacheBase.h
similarity index 100%
rename from include/CacheBase.h
rename to src/CacheBase.h
diff --git a/src/CacheDisk.cpp b/src/CacheDisk.cpp
index b3fd119fd..c252d0b25 100644
--- a/src/CacheDisk.cpp
+++ b/src/CacheDisk.cpp
@@ -28,8 +28,8 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/CacheDisk.h"
-#include "../include/QtUtilities.h"
+#include "CacheDisk.h"
+#include "QtUtilities.h"
#include
#include
#include
diff --git a/include/CacheDisk.h b/src/CacheDisk.h
similarity index 100%
rename from include/CacheDisk.h
rename to src/CacheDisk.h
diff --git a/src/CacheMemory.cpp b/src/CacheMemory.cpp
index 70feef03d..685c86ecf 100644
--- a/src/CacheMemory.cpp
+++ b/src/CacheMemory.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/CacheMemory.h"
+#include "CacheMemory.h"
using namespace std;
using namespace openshot;
diff --git a/include/CacheMemory.h b/src/CacheMemory.h
similarity index 100%
rename from include/CacheMemory.h
rename to src/CacheMemory.h
diff --git a/include/ChannelLayouts.h b/src/ChannelLayouts.h
similarity index 100%
rename from include/ChannelLayouts.h
rename to src/ChannelLayouts.h
diff --git a/src/ChunkReader.cpp b/src/ChunkReader.cpp
index c194ce33a..5301c6874 100644
--- a/src/ChunkReader.cpp
+++ b/src/ChunkReader.cpp
@@ -28,8 +28,10 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/ChunkReader.h"
-#include "../include/FFmpegReader.h"
+#include "ChunkReader.h"
+#include "FFmpegReader.h"
+
+#include
using namespace openshot;
diff --git a/include/ChunkReader.h b/src/ChunkReader.h
similarity index 97%
rename from include/ChunkReader.h
rename to src/ChunkReader.h
index 50b260838..7a041f714 100644
--- a/include/ChunkReader.h
+++ b/src/ChunkReader.h
@@ -32,18 +32,12 @@
#define OPENSHOT_CHUNK_READER_H
#include "ReaderBase.h"
-#include
-#include
-#include
-#include
-#include
-#include
-#include
+#include
#include
-#include
+
+#include "Frame.h"
#include "Json.h"
#include "CacheMemory.h"
-#include "Exceptions.h"
namespace openshot
{
diff --git a/src/ChunkWriter.cpp b/src/ChunkWriter.cpp
index c7752cd57..bbb10be91 100644
--- a/src/ChunkWriter.cpp
+++ b/src/ChunkWriter.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/ChunkWriter.h"
+#include "ChunkWriter.h"
using namespace openshot;
diff --git a/include/ChunkWriter.h b/src/ChunkWriter.h
similarity index 100%
rename from include/ChunkWriter.h
rename to src/ChunkWriter.h
diff --git a/src/Clip.cpp b/src/Clip.cpp
index 1f7382828..f3660f0a8 100644
--- a/src/Clip.cpp
+++ b/src/Clip.cpp
@@ -28,17 +28,17 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/Clip.h"
-#include "../include/FFmpegReader.h"
-#include "../include/FrameMapper.h"
+#include "Clip.h"
+#include "FFmpegReader.h"
+#include "FrameMapper.h"
#ifdef USE_IMAGEMAGICK
- #include "../include/ImageReader.h"
- #include "../include/TextReader.h"
+ #include "ImageReader.h"
+ #include "TextReader.h"
#endif
-#include "../include/QtImageReader.h"
-#include "../include/ChunkReader.h"
-#include "../include/DummyReader.h"
-#include "../include/Timeline.h"
+#include "QtImageReader.h"
+#include "ChunkReader.h"
+#include "DummyReader.h"
+#include "Timeline.h"
using namespace openshot;
diff --git a/include/Clip.h b/src/Clip.h
similarity index 100%
rename from include/Clip.h
rename to src/Clip.h
diff --git a/src/ClipBase.cpp b/src/ClipBase.cpp
index a51c65735..f76959046 100644
--- a/src/ClipBase.cpp
+++ b/src/ClipBase.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/ClipBase.h"
+#include "ClipBase.h"
using namespace openshot;
diff --git a/include/ClipBase.h b/src/ClipBase.h
similarity index 100%
rename from include/ClipBase.h
rename to src/ClipBase.h
diff --git a/src/Color.cpp b/src/Color.cpp
index 705ece4a1..622a912ca 100644
--- a/src/Color.cpp
+++ b/src/Color.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/Color.h"
+#include "Color.h"
using namespace openshot;
diff --git a/include/Color.h b/src/Color.h
similarity index 100%
rename from include/Color.h
rename to src/Color.h
diff --git a/src/Coordinate.cpp b/src/Coordinate.cpp
index f87fb7a0e..0d4f577a6 100644
--- a/src/Coordinate.cpp
+++ b/src/Coordinate.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/Coordinate.h"
+#include "Coordinate.h"
using namespace std;
using namespace openshot;
diff --git a/include/Coordinate.h b/src/Coordinate.h
similarity index 100%
rename from include/Coordinate.h
rename to src/Coordinate.h
diff --git a/src/CrashHandler.cpp b/src/CrashHandler.cpp
index 1782f5bab..7b6c4e7e6 100644
--- a/src/CrashHandler.cpp
+++ b/src/CrashHandler.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/CrashHandler.h"
+#include "CrashHandler.h"
using namespace std;
using namespace openshot;
diff --git a/include/CrashHandler.h b/src/CrashHandler.h
similarity index 100%
rename from include/CrashHandler.h
rename to src/CrashHandler.h
diff --git a/src/DecklinkInput.cpp b/src/DecklinkInput.cpp
index b03ad8e4a..21c4f7bb6 100644
--- a/src/DecklinkInput.cpp
+++ b/src/DecklinkInput.cpp
@@ -53,7 +53,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/DecklinkInput.h"
+#include "DecklinkInput.h"
using namespace std;
diff --git a/include/DecklinkInput.h b/src/DecklinkInput.h
similarity index 100%
rename from include/DecklinkInput.h
rename to src/DecklinkInput.h
diff --git a/src/DecklinkOutput.cpp b/src/DecklinkOutput.cpp
index 2dee7e9e3..13da185f4 100644
--- a/src/DecklinkOutput.cpp
+++ b/src/DecklinkOutput.cpp
@@ -53,7 +53,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/DecklinkOutput.h"
+#include "DecklinkOutput.h"
using namespace std;
diff --git a/include/DecklinkOutput.h b/src/DecklinkOutput.h
similarity index 100%
rename from include/DecklinkOutput.h
rename to src/DecklinkOutput.h
diff --git a/src/DecklinkReader.cpp b/src/DecklinkReader.cpp
index 14c2f87ca..bb31f316d 100644
--- a/src/DecklinkReader.cpp
+++ b/src/DecklinkReader.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/DecklinkReader.h"
+#include "DecklinkReader.h"
using namespace openshot;
diff --git a/include/DecklinkReader.h b/src/DecklinkReader.h
similarity index 100%
rename from include/DecklinkReader.h
rename to src/DecklinkReader.h
diff --git a/src/DecklinkWriter.cpp b/src/DecklinkWriter.cpp
index 3eafda1cf..1bfb59a8d 100644
--- a/src/DecklinkWriter.cpp
+++ b/src/DecklinkWriter.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/DecklinkWriter.h"
+#include "DecklinkWriter.h"
using namespace openshot;
diff --git a/include/DecklinkWriter.h b/src/DecklinkWriter.h
similarity index 100%
rename from include/DecklinkWriter.h
rename to src/DecklinkWriter.h
diff --git a/src/DummyReader.cpp b/src/DummyReader.cpp
index 8b6f752f7..c295c2985 100644
--- a/src/DummyReader.cpp
+++ b/src/DummyReader.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/DummyReader.h"
+#include "DummyReader.h"
using namespace openshot;
diff --git a/include/DummyReader.h b/src/DummyReader.h
similarity index 100%
rename from include/DummyReader.h
rename to src/DummyReader.h
diff --git a/src/EffectBase.cpp b/src/EffectBase.cpp
index 05ed97c2a..f1d7d0301 100644
--- a/src/EffectBase.cpp
+++ b/src/EffectBase.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/EffectBase.h"
+#include "EffectBase.h"
using namespace openshot;
diff --git a/include/EffectBase.h b/src/EffectBase.h
similarity index 100%
rename from include/EffectBase.h
rename to src/EffectBase.h
diff --git a/src/EffectInfo.cpp b/src/EffectInfo.cpp
index 6829f4eb5..1359238d5 100644
--- a/src/EffectInfo.cpp
+++ b/src/EffectInfo.cpp
@@ -28,8 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/EffectInfo.h"
-
+#include "EffectInfo.h"
using namespace openshot;
diff --git a/include/EffectInfo.h b/src/EffectInfo.h
similarity index 100%
rename from include/EffectInfo.h
rename to src/EffectInfo.h
diff --git a/include/Effects.h b/src/Effects.h
similarity index 100%
rename from include/Effects.h
rename to src/Effects.h
diff --git a/include/Enums.h b/src/Enums.h
similarity index 100%
rename from include/Enums.h
rename to src/Enums.h
diff --git a/include/Exceptions.h b/src/Exceptions.h
similarity index 100%
rename from include/Exceptions.h
rename to src/Exceptions.h
diff --git a/src/FFmpegReader.cpp b/src/FFmpegReader.cpp
index 5b7b7ddd4..f17e03591 100644
--- a/src/FFmpegReader.cpp
+++ b/src/FFmpegReader.cpp
@@ -31,7 +31,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/FFmpegReader.h"
+#include "FFmpegReader.h"
#include // for std::this_thread::sleep_for
#include // for std::chrono::milliseconds
diff --git a/include/FFmpegReader.h b/src/FFmpegReader.h
similarity index 100%
rename from include/FFmpegReader.h
rename to src/FFmpegReader.h
diff --git a/include/FFmpegUtilities.h b/src/FFmpegUtilities.h
similarity index 100%
rename from include/FFmpegUtilities.h
rename to src/FFmpegUtilities.h
diff --git a/src/FFmpegWriter.cpp b/src/FFmpegWriter.cpp
index 76bc98905..e5e92fd4f 100644
--- a/src/FFmpegWriter.cpp
+++ b/src/FFmpegWriter.cpp
@@ -31,7 +31,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/FFmpegWriter.h"
+#include "FFmpegWriter.h"
#include
diff --git a/include/FFmpegWriter.h b/src/FFmpegWriter.h
similarity index 100%
rename from include/FFmpegWriter.h
rename to src/FFmpegWriter.h
diff --git a/src/Fraction.cpp b/src/Fraction.cpp
index c9cdad55d..869ef35ff 100644
--- a/src/Fraction.cpp
+++ b/src/Fraction.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/Fraction.h"
+#include "Fraction.h"
using namespace openshot;
diff --git a/include/Fraction.h b/src/Fraction.h
similarity index 100%
rename from include/Fraction.h
rename to src/Fraction.h
diff --git a/src/Frame.cpp b/src/Frame.cpp
index 8be002466..3bae8854b 100644
--- a/src/Frame.cpp
+++ b/src/Frame.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/Frame.h"
+#include "Frame.h"
#include "JuceHeader.h"
#include
diff --git a/include/Frame.h b/src/Frame.h
similarity index 100%
rename from include/Frame.h
rename to src/Frame.h
diff --git a/src/FrameMapper.cpp b/src/FrameMapper.cpp
index 8eff6e702..85c6bfdfc 100644
--- a/src/FrameMapper.cpp
+++ b/src/FrameMapper.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/FrameMapper.h"
+#include "FrameMapper.h"
using namespace std;
using namespace openshot;
diff --git a/include/FrameMapper.h b/src/FrameMapper.h
similarity index 100%
rename from include/FrameMapper.h
rename to src/FrameMapper.h
diff --git a/src/ImageReader.cpp b/src/ImageReader.cpp
index 2a4d411ed..ad21be157 100644
--- a/src/ImageReader.cpp
+++ b/src/ImageReader.cpp
@@ -31,7 +31,7 @@
// Require ImageMagick support
#ifdef USE_IMAGEMAGICK
-#include "../include/ImageReader.h"
+#include "ImageReader.h"
using namespace openshot;
diff --git a/include/ImageReader.h b/src/ImageReader.h
similarity index 100%
rename from include/ImageReader.h
rename to src/ImageReader.h
diff --git a/src/ImageWriter.cpp b/src/ImageWriter.cpp
index 1b7a01e9b..275ea2703 100644
--- a/src/ImageWriter.cpp
+++ b/src/ImageWriter.cpp
@@ -34,7 +34,7 @@
//Require ImageMagick support
#ifdef USE_IMAGEMAGICK
-#include "../include/ImageWriter.h"
+#include "ImageWriter.h"
using namespace openshot;
diff --git a/include/ImageWriter.h b/src/ImageWriter.h
similarity index 100%
rename from include/ImageWriter.h
rename to src/ImageWriter.h
diff --git a/src/Json.cpp b/src/Json.cpp
index 0c83d9d62..9d6d9ba4d 100644
--- a/src/Json.cpp
+++ b/src/Json.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/Json.h"
+#include "Json.h"
const Json::Value openshot::stringToJson(const std::string value) {
diff --git a/include/Json.h b/src/Json.h
similarity index 100%
rename from include/Json.h
rename to src/Json.h
diff --git a/src/KeyFrame.cpp b/src/KeyFrame.cpp
index 57e424cf7..b113e6325 100644
--- a/src/KeyFrame.cpp
+++ b/src/KeyFrame.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/KeyFrame.h"
+#include "KeyFrame.h"
#include
#include
#include
diff --git a/include/KeyFrame.h b/src/KeyFrame.h
similarity index 100%
rename from include/KeyFrame.h
rename to src/KeyFrame.h
diff --git a/include/MagickUtilities.h b/src/MagickUtilities.h
similarity index 100%
rename from include/MagickUtilities.h
rename to src/MagickUtilities.h
diff --git a/include/OpenMPUtilities.h b/src/OpenMPUtilities.h
similarity index 100%
rename from include/OpenMPUtilities.h
rename to src/OpenMPUtilities.h
diff --git a/include/OpenShot.h b/src/OpenShot.h
similarity index 100%
rename from include/OpenShot.h
rename to src/OpenShot.h
diff --git a/include/OpenShotVersion.h.in b/src/OpenShotVersion.h.in
similarity index 100%
rename from include/OpenShotVersion.h.in
rename to src/OpenShotVersion.h.in
diff --git a/src/PlayerBase.cpp b/src/PlayerBase.cpp
index f152fbbb9..844b8d605 100644
--- a/src/PlayerBase.cpp
+++ b/src/PlayerBase.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/PlayerBase.h"
+#include "PlayerBase.h"
using namespace openshot;
diff --git a/include/PlayerBase.h b/src/PlayerBase.h
similarity index 100%
rename from include/PlayerBase.h
rename to src/PlayerBase.h
diff --git a/src/Point.cpp b/src/Point.cpp
index 136799778..4636b437d 100644
--- a/src/Point.cpp
+++ b/src/Point.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/Point.h"
+#include "Point.h"
using namespace std;
using namespace openshot;
diff --git a/include/Point.h b/src/Point.h
similarity index 100%
rename from include/Point.h
rename to src/Point.h
diff --git a/src/Profiles.cpp b/src/Profiles.cpp
index 5351520e9..167affe2c 100644
--- a/src/Profiles.cpp
+++ b/src/Profiles.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/Profiles.h"
+#include "Profiles.h"
using namespace openshot;
diff --git a/include/Profiles.h b/src/Profiles.h
similarity index 100%
rename from include/Profiles.h
rename to src/Profiles.h
diff --git a/src/Qt/AudioPlaybackThread.cpp b/src/Qt/AudioPlaybackThread.cpp
index 2ee1009c5..178642f6d 100644
--- a/src/Qt/AudioPlaybackThread.cpp
+++ b/src/Qt/AudioPlaybackThread.cpp
@@ -29,7 +29,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/Qt/AudioPlaybackThread.h"
+#include "AudioPlaybackThread.h"
#include // for std::this_thread::sleep_for
#include // for std::chrono::milliseconds
diff --git a/include/Qt/AudioPlaybackThread.h b/src/Qt/AudioPlaybackThread.h
similarity index 100%
rename from include/Qt/AudioPlaybackThread.h
rename to src/Qt/AudioPlaybackThread.h
diff --git a/src/Qt/PlayerDemo.cpp b/src/Qt/PlayerDemo.cpp
index e5f0e11d0..e8751a629 100644
--- a/src/Qt/PlayerDemo.cpp
+++ b/src/Qt/PlayerDemo.cpp
@@ -28,9 +28,11 @@
* along with OpenShot Library. If not, see .
*/
-#include
-#include "../../include/QtPlayer.h"
-#include "../../include/Qt/PlayerDemo.h"
+#include
+
+#include "PlayerDemo.h"
+#include "../QtPlayer.h"
+
#include
#include
#include
diff --git a/include/Qt/PlayerDemo.h b/src/Qt/PlayerDemo.h
similarity index 100%
rename from include/Qt/PlayerDemo.h
rename to src/Qt/PlayerDemo.h
diff --git a/src/Qt/PlayerPrivate.cpp b/src/Qt/PlayerPrivate.cpp
index db6f2ff10..75052fc31 100644
--- a/src/Qt/PlayerPrivate.cpp
+++ b/src/Qt/PlayerPrivate.cpp
@@ -29,7 +29,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/Qt/PlayerPrivate.h"
+#include "PlayerPrivate.h"
#include // for std::this_thread::sleep_for
#include // for std::chrono milliseconds, high_resolution_clock
diff --git a/include/Qt/PlayerPrivate.h b/src/Qt/PlayerPrivate.h
similarity index 100%
rename from include/Qt/PlayerPrivate.h
rename to src/Qt/PlayerPrivate.h
diff --git a/src/Qt/VideoCacheThread.cpp b/src/Qt/VideoCacheThread.cpp
index 4279e2381..f817c93f3 100644
--- a/src/Qt/VideoCacheThread.cpp
+++ b/src/Qt/VideoCacheThread.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/Qt/VideoCacheThread.h"
+#include "VideoCacheThread.h"
#include
#include // for std::this_thread::sleep_for
diff --git a/include/Qt/VideoCacheThread.h b/src/Qt/VideoCacheThread.h
similarity index 100%
rename from include/Qt/VideoCacheThread.h
rename to src/Qt/VideoCacheThread.h
diff --git a/src/Qt/VideoPlaybackThread.cpp b/src/Qt/VideoPlaybackThread.cpp
index f1cff7565..01e2871bd 100644
--- a/src/Qt/VideoPlaybackThread.cpp
+++ b/src/Qt/VideoPlaybackThread.cpp
@@ -29,7 +29,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/Qt/VideoPlaybackThread.h"
+#include "VideoPlaybackThread.h"
namespace openshot
{
diff --git a/include/Qt/VideoPlaybackThread.h b/src/Qt/VideoPlaybackThread.h
similarity index 100%
rename from include/Qt/VideoPlaybackThread.h
rename to src/Qt/VideoPlaybackThread.h
diff --git a/src/Qt/VideoRenderWidget.cpp b/src/Qt/VideoRenderWidget.cpp
index 4af1ac6ab..528983720 100644
--- a/src/Qt/VideoRenderWidget.cpp
+++ b/src/Qt/VideoRenderWidget.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/Qt/VideoRenderWidget.h"
+#include "VideoRenderWidget.h"
#include
#include
#include
diff --git a/include/Qt/VideoRenderWidget.h b/src/Qt/VideoRenderWidget.h
similarity index 100%
rename from include/Qt/VideoRenderWidget.h
rename to src/Qt/VideoRenderWidget.h
diff --git a/src/Qt/VideoRenderer.cpp b/src/Qt/VideoRenderer.cpp
index 8d0e3a1d3..e70e85451 100644
--- a/src/Qt/VideoRenderer.cpp
+++ b/src/Qt/VideoRenderer.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/Qt/VideoRenderer.h"
+#include "VideoRenderer.h"
VideoRenderer::VideoRenderer(QObject *parent)
diff --git a/include/Qt/VideoRenderer.h b/src/Qt/VideoRenderer.h
similarity index 100%
rename from include/Qt/VideoRenderer.h
rename to src/Qt/VideoRenderer.h
diff --git a/src/QtHtmlReader.cpp b/src/QtHtmlReader.cpp
index 4925d3a88..b40041ac4 100644
--- a/src/QtHtmlReader.cpp
+++ b/src/QtHtmlReader.cpp
@@ -30,7 +30,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/QtHtmlReader.h"
+#include "QtHtmlReader.h"
#include
#include
#include
diff --git a/include/QtHtmlReader.h b/src/QtHtmlReader.h
similarity index 100%
rename from include/QtHtmlReader.h
rename to src/QtHtmlReader.h
diff --git a/src/QtImageReader.cpp b/src/QtImageReader.cpp
index 78c2b009a..f24c7ef4b 100644
--- a/src/QtImageReader.cpp
+++ b/src/QtImageReader.cpp
@@ -28,10 +28,10 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/QtImageReader.h"
-#include "../include/Settings.h"
-#include "../include/Clip.h"
-#include "../include/CacheMemory.h"
+#include "QtImageReader.h"
+#include "Settings.h"
+#include "Clip.h"
+#include "CacheMemory.h"
#include
#include
#include
diff --git a/include/QtImageReader.h b/src/QtImageReader.h
similarity index 100%
rename from include/QtImageReader.h
rename to src/QtImageReader.h
diff --git a/src/QtPlayer.cpp b/src/QtPlayer.cpp
index e4d862d19..345bc24f0 100644
--- a/src/QtPlayer.cpp
+++ b/src/QtPlayer.cpp
@@ -29,12 +29,12 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/Clip.h"
-#include "../include/FFmpegReader.h"
-#include "../include/Timeline.h"
-#include "../include/QtPlayer.h"
-#include "../include/Qt/PlayerPrivate.h"
-#include "../include/Qt/VideoRenderer.h"
+#include "Clip.h"
+#include "FFmpegReader.h"
+#include "Timeline.h"
+#include "QtPlayer.h"
+#include "Qt/PlayerPrivate.h"
+#include "Qt/VideoRenderer.h"
namespace openshot
{
diff --git a/include/QtPlayer.h b/src/QtPlayer.h
similarity index 100%
rename from include/QtPlayer.h
rename to src/QtPlayer.h
diff --git a/src/QtTextReader.cpp b/src/QtTextReader.cpp
index bd157ebd2..2c3d1c3ac 100644
--- a/src/QtTextReader.cpp
+++ b/src/QtTextReader.cpp
@@ -30,7 +30,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/QtTextReader.h"
+#include "QtTextReader.h"
#include
#include
diff --git a/include/QtTextReader.h b/src/QtTextReader.h
similarity index 100%
rename from include/QtTextReader.h
rename to src/QtTextReader.h
diff --git a/include/QtUtilities.h b/src/QtUtilities.h
similarity index 100%
rename from include/QtUtilities.h
rename to src/QtUtilities.h
diff --git a/src/ReaderBase.cpp b/src/ReaderBase.cpp
index 6799d95ec..220925d7a 100644
--- a/src/ReaderBase.cpp
+++ b/src/ReaderBase.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/ReaderBase.h"
+#include "ReaderBase.h"
using namespace openshot;
diff --git a/include/ReaderBase.h b/src/ReaderBase.h
similarity index 100%
rename from include/ReaderBase.h
rename to src/ReaderBase.h
diff --git a/src/RendererBase.cpp b/src/RendererBase.cpp
index b2bea40e5..ca9ad26ec 100644
--- a/src/RendererBase.cpp
+++ b/src/RendererBase.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/RendererBase.h"
+#include "RendererBase.h"
using namespace openshot;
RendererBase::RendererBase()
diff --git a/include/RendererBase.h b/src/RendererBase.h
similarity index 100%
rename from include/RendererBase.h
rename to src/RendererBase.h
diff --git a/src/Settings.cpp b/src/Settings.cpp
index e48fd981c..e3f44aed8 100644
--- a/src/Settings.cpp
+++ b/src/Settings.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/Settings.h"
+#include "Settings.h"
using namespace std;
using namespace openshot;
diff --git a/include/Settings.h b/src/Settings.h
similarity index 100%
rename from include/Settings.h
rename to src/Settings.h
diff --git a/src/TextReader.cpp b/src/TextReader.cpp
index be8c7375f..0407460a2 100644
--- a/src/TextReader.cpp
+++ b/src/TextReader.cpp
@@ -31,7 +31,7 @@
// Require ImageMagick support
#ifdef USE_IMAGEMAGICK
-#include "../include/TextReader.h"
+#include "TextReader.h"
using namespace openshot;
diff --git a/include/TextReader.h b/src/TextReader.h
similarity index 100%
rename from include/TextReader.h
rename to src/TextReader.h
diff --git a/src/Timeline.cpp b/src/Timeline.cpp
index 9ccf9a84e..71ab8efa2 100644
--- a/src/Timeline.cpp
+++ b/src/Timeline.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/Timeline.h"
+#include "Timeline.h"
using namespace openshot;
diff --git a/include/Timeline.h b/src/Timeline.h
similarity index 100%
rename from include/Timeline.h
rename to src/Timeline.h
diff --git a/src/WriterBase.cpp b/src/WriterBase.cpp
index 388219179..9755c61d5 100644
--- a/src/WriterBase.cpp
+++ b/src/WriterBase.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/WriterBase.h"
+#include "WriterBase.h"
using namespace openshot;
diff --git a/include/WriterBase.h b/src/WriterBase.h
similarity index 100%
rename from include/WriterBase.h
rename to src/WriterBase.h
diff --git a/src/ZmqLogger.cpp b/src/ZmqLogger.cpp
index b72992308..8d72f352e 100644
--- a/src/ZmqLogger.cpp
+++ b/src/ZmqLogger.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../include/ZmqLogger.h"
+#include "ZmqLogger.h"
#if USE_RESVG == 1
#include "ResvgQt.h"
diff --git a/include/ZmqLogger.h b/src/ZmqLogger.h
similarity index 100%
rename from include/ZmqLogger.h
rename to src/ZmqLogger.h
diff --git a/src/effects/Bars.cpp b/src/effects/Bars.cpp
index e653b7dda..6b3195691 100644
--- a/src/effects/Bars.cpp
+++ b/src/effects/Bars.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/effects/Bars.h"
+#include "Bars.h"
using namespace openshot;
diff --git a/include/effects/Bars.h b/src/effects/Bars.h
similarity index 98%
rename from include/effects/Bars.h
rename to src/effects/Bars.h
index 7c92255aa..c2e24f738 100644
--- a/include/effects/Bars.h
+++ b/src/effects/Bars.h
@@ -33,13 +33,13 @@
#include "../EffectBase.h"
-#include
-#include
-#include
#include "../Color.h"
+#include "../Frame.h"
#include "../Json.h"
#include "../KeyFrame.h"
+#include
+#include
namespace openshot
{
diff --git a/src/effects/Blur.cpp b/src/effects/Blur.cpp
index 6ddba88e6..c7e36b7bc 100644
--- a/src/effects/Blur.cpp
+++ b/src/effects/Blur.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/effects/Blur.h"
+#include "Blur.h"
using namespace openshot;
diff --git a/include/effects/Blur.h b/src/effects/Blur.h
similarity index 94%
rename from include/effects/Blur.h
rename to src/effects/Blur.h
index 60a0cd085..59b75fff7 100644
--- a/include/effects/Blur.h
+++ b/src/effects/Blur.h
@@ -33,21 +33,12 @@
#include "../EffectBase.h"
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include "../Color.h"
-#include "../Exceptions.h"
+#include "../Frame.h"
#include "../Json.h"
#include "../KeyFrame.h"
-#include "../ReaderBase.h"
-#include "../FFmpegReader.h"
-#include "../QtImageReader.h"
-#include "../ChunkReader.h"
+
+#include
+#include
namespace openshot
{
diff --git a/src/effects/Brightness.cpp b/src/effects/Brightness.cpp
index 321a19a78..d73de8993 100644
--- a/src/effects/Brightness.cpp
+++ b/src/effects/Brightness.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/effects/Brightness.h"
+#include "Brightness.h"
using namespace openshot;
diff --git a/include/effects/Brightness.h b/src/effects/Brightness.h
similarity index 93%
rename from include/effects/Brightness.h
rename to src/effects/Brightness.h
index 5f25b94a0..228600685 100644
--- a/include/effects/Brightness.h
+++ b/src/effects/Brightness.h
@@ -33,20 +33,12 @@
#include "../EffectBase.h"
-#include
-#include
-#include
-#include
-#include
-#include
-#include "../Color.h"
-#include "../Exceptions.h"
+#include "../Frame.h"
#include "../Json.h"
#include "../KeyFrame.h"
-#include "../ReaderBase.h"
-#include "../FFmpegReader.h"
-#include "../QtImageReader.h"
-#include "../ChunkReader.h"
+
+#include
+#include
namespace openshot
{
diff --git a/src/effects/ChromaKey.cpp b/src/effects/ChromaKey.cpp
index dbb56a693..0f4d626e5 100644
--- a/src/effects/ChromaKey.cpp
+++ b/src/effects/ChromaKey.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/effects/ChromaKey.h"
+#include "ChromaKey.h"
using namespace openshot;
diff --git a/include/effects/ChromaKey.h b/src/effects/ChromaKey.h
similarity index 97%
rename from include/effects/ChromaKey.h
rename to src/effects/ChromaKey.h
index fcc8c3b1f..7c2676425 100644
--- a/include/effects/ChromaKey.h
+++ b/src/effects/ChromaKey.h
@@ -33,16 +33,14 @@
#include "../EffectBase.h"
-#include
-#include
-#include
-#include
-#include
-#include
#include "../Color.h"
+#include "../Frame.h"
#include "../Exceptions.h"
#include "../KeyFrame.h"
+#include
+#include
+
namespace openshot
{
diff --git a/src/effects/ColorShift.cpp b/src/effects/ColorShift.cpp
index 7ec62e14c..361f852d8 100644
--- a/src/effects/ColorShift.cpp
+++ b/src/effects/ColorShift.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/effects/ColorShift.h"
+#include "ColorShift.h"
using namespace openshot;
diff --git a/include/effects/ColorShift.h b/src/effects/ColorShift.h
similarity index 100%
rename from include/effects/ColorShift.h
rename to src/effects/ColorShift.h
diff --git a/src/effects/Crop.cpp b/src/effects/Crop.cpp
index f0e0aa953..02e3f17c1 100644
--- a/src/effects/Crop.cpp
+++ b/src/effects/Crop.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/effects/Crop.h"
+#include "Crop.h"
using namespace openshot;
diff --git a/include/effects/Crop.h b/src/effects/Crop.h
similarity index 98%
rename from include/effects/Crop.h
rename to src/effects/Crop.h
index f5ba07f24..2b746a016 100644
--- a/include/effects/Crop.h
+++ b/src/effects/Crop.h
@@ -33,13 +33,14 @@
#include "../EffectBase.h"
-#include
-#include
-#include
#include "../Color.h"
+#include "../Frame.h"
#include "../Json.h"
#include "../KeyFrame.h"
+#include
+#include
+
namespace openshot
{
diff --git a/src/effects/Deinterlace.cpp b/src/effects/Deinterlace.cpp
index 984336aa0..36014349f 100644
--- a/src/effects/Deinterlace.cpp
+++ b/src/effects/Deinterlace.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/effects/Deinterlace.h"
+#include "Deinterlace.h"
using namespace openshot;
diff --git a/include/effects/Deinterlace.h b/src/effects/Deinterlace.h
similarity index 95%
rename from include/effects/Deinterlace.h
rename to src/effects/Deinterlace.h
index 97c778538..84212d676 100644
--- a/include/effects/Deinterlace.h
+++ b/src/effects/Deinterlace.h
@@ -33,14 +33,9 @@
#include "../EffectBase.h"
-#include
-#include
-#include
-#include
-#include
+#include
#include
-#include "../Color.h"
-#include "../Exceptions.h"
+#include "../Frame.h"
#include "../Json.h"
#include "../KeyFrame.h"
diff --git a/src/effects/Hue.cpp b/src/effects/Hue.cpp
index eb4808e31..35ee37098 100644
--- a/src/effects/Hue.cpp
+++ b/src/effects/Hue.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/effects/Hue.h"
+#include "Hue.h"
using namespace openshot;
diff --git a/include/effects/Hue.h b/src/effects/Hue.h
similarity index 98%
rename from include/effects/Hue.h
rename to src/effects/Hue.h
index 833bf087b..039aa3a84 100644
--- a/include/effects/Hue.h
+++ b/src/effects/Hue.h
@@ -33,12 +33,13 @@
#include "../EffectBase.h"
-#include
-#include
-#include
+#include "../Frame.h"
#include "../Json.h"
#include "../KeyFrame.h"
+#include
+#include
+
namespace openshot
{
diff --git a/src/effects/Mask.cpp b/src/effects/Mask.cpp
index f270e4109..9fbc18245 100644
--- a/src/effects/Mask.cpp
+++ b/src/effects/Mask.cpp
@@ -28,7 +28,12 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/effects/Mask.h"
+#include "Mask.h"
+#include "FFmpegReader.h"
+#ifdef USE_IMAGEMAGICK
+ #include "ImageReader.h"
+#endif
+#include "ReaderBase.h"
using namespace openshot;
diff --git a/include/effects/Mask.h b/src/effects/Mask.h
similarity index 92%
rename from include/effects/Mask.h
rename to src/effects/Mask.h
index 8156b8436..1a76ea473 100644
--- a/include/effects/Mask.h
+++ b/src/effects/Mask.h
@@ -33,27 +33,16 @@
#include "../EffectBase.h"
-#include
-#include
-#include
-#include
-#include
-#include
-#include "../Color.h"
-#include "../Exceptions.h"
#include "../Json.h"
#include "../KeyFrame.h"
-#include "../ReaderBase.h"
-#include "../FFmpegReader.h"
-#include "../QtImageReader.h"
-#include "../ChunkReader.h"
-#ifdef USE_IMAGEMAGICK
- #include "../MagickUtilities.h"
- #include "../ImageReader.h"
-#endif
+
+#include
+#include
namespace openshot
{
+ // Forward declaration
+ class ReaderBase;
/**
* @brief This class uses the image libraries to apply alpha (or transparency) masks
diff --git a/src/effects/Negate.cpp b/src/effects/Negate.cpp
index 18a5d194c..9cffd613b 100644
--- a/src/effects/Negate.cpp
+++ b/src/effects/Negate.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/effects/Negate.h"
+#include "Negate.h"
using namespace openshot;
diff --git a/include/effects/Negate.h b/src/effects/Negate.h
similarity index 95%
rename from include/effects/Negate.h
rename to src/effects/Negate.h
index c691a86c1..c3a67efd5 100644
--- a/include/effects/Negate.h
+++ b/src/effects/Negate.h
@@ -33,16 +33,14 @@
#include "../EffectBase.h"
-#include
-#include
-#include
-#include
-#include
-#include
-#include "../Color.h"
-#include "../Exceptions.h"
+#include "../Frame.h"
#include "../KeyFrame.h"
+#include
+#include
+
+#include
+
namespace openshot
{
diff --git a/src/effects/Pixelate.cpp b/src/effects/Pixelate.cpp
index 057b28e29..15c416fbb 100644
--- a/src/effects/Pixelate.cpp
+++ b/src/effects/Pixelate.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/effects/Pixelate.h"
+#include "Pixelate.h"
#include "Json.h"
#include
diff --git a/include/effects/Pixelate.h b/src/effects/Pixelate.h
similarity index 98%
rename from include/effects/Pixelate.h
rename to src/effects/Pixelate.h
index 793f4d46f..112231502 100644
--- a/include/effects/Pixelate.h
+++ b/src/effects/Pixelate.h
@@ -33,12 +33,12 @@
#include "../EffectBase.h"
-#include
-#include
-#include
+#include "../Frame.h"
#include "../Json.h"
#include "../KeyFrame.h"
+#include
+#include
namespace openshot
{
diff --git a/src/effects/Saturation.cpp b/src/effects/Saturation.cpp
index cad9c08d7..df2ddad3b 100644
--- a/src/effects/Saturation.cpp
+++ b/src/effects/Saturation.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/effects/Saturation.h"
+#include "Saturation.h"
using namespace openshot;
diff --git a/include/effects/Saturation.h b/src/effects/Saturation.h
similarity index 100%
rename from include/effects/Saturation.h
rename to src/effects/Saturation.h
diff --git a/src/effects/Shift.cpp b/src/effects/Shift.cpp
index ee5815912..e591a1715 100644
--- a/src/effects/Shift.cpp
+++ b/src/effects/Shift.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/effects/Shift.h"
+#include "Shift.h"
using namespace openshot;
diff --git a/include/effects/Shift.h b/src/effects/Shift.h
similarity index 98%
rename from include/effects/Shift.h
rename to src/effects/Shift.h
index 7a7efbea4..86e4ad37c 100644
--- a/include/effects/Shift.h
+++ b/src/effects/Shift.h
@@ -33,12 +33,13 @@
#include "../EffectBase.h"
-#include
-#include
-#include
+#include "../Frame.h"
#include "../Json.h"
#include "../KeyFrame.h"
+#include
+#include
+
namespace openshot
{
diff --git a/src/effects/Wave.cpp b/src/effects/Wave.cpp
index 499fc9588..1e796d4c0 100644
--- a/src/effects/Wave.cpp
+++ b/src/effects/Wave.cpp
@@ -28,7 +28,7 @@
* along with OpenShot Library. If not, see .
*/
-#include "../../include/effects/Wave.h"
+#include "Wave.h"
using namespace openshot;
diff --git a/include/effects/Wave.h b/src/effects/Wave.h
similarity index 98%
rename from include/effects/Wave.h
rename to src/effects/Wave.h
index d4759c24e..7f6e37b70 100644
--- a/include/effects/Wave.h
+++ b/src/effects/Wave.h
@@ -33,12 +33,13 @@
#include "../EffectBase.h"
-#include
-#include
-#include
+#include "../Frame.h"
#include "../Json.h"
#include "../KeyFrame.h"
+#include
+#include
+
namespace openshot
{
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt
index 78d4ae972..73a812b5c 100644
--- a/tests/CMakeLists.txt
+++ b/tests/CMakeLists.txt
@@ -25,22 +25,9 @@
################################################################################
# Test media path, used by unit tests for input data
-file(TO_NATIVE_PATH "${PROJECT_SOURCE_DIR}/src/examples/" TEST_MEDIA_PATH)
+file(TO_NATIVE_PATH "${PROJECT_SOURCE_DIR}/examples/" TEST_MEDIA_PATH)
add_definitions( -DTEST_MEDIA_PATH="${TEST_MEDIA_PATH}" )
-################ WINDOWS ##################
-# Set some compiler options for Windows
-# required for libopenshot-audio headers
-if(WIN32)
- add_definitions( -DIGNORE_JUCE_HYPOT=1 )
- set(CMAKE_CXX_FLAGS " ${CMAKE_CXX_FLAGS} -include cmath")
-endif()
-
-if (APPLE)
- # Prevent compiling with __cxx11
- add_definitions(-D_GLIBCXX_USE_CXX11_ABI=0)
-endif()
-
################### UNITTEST++ #####################
# Find UnitTest++ libraries (used for unit testing)
find_package(UnitTest++)
@@ -57,44 +44,6 @@ set_package_properties(UnitTest++ PROPERTIES
TYPE RECOMMENDED
PURPOSE "Unit testing framework")
-################ IMAGE MAGICK ##################
-if(ENABLE_MAGICK)
- # Set the Quantum Depth that ImageMagick was built with (default to 16 bits)
- if(MAGICKCORE_QUANTUM_DEPTH)
- add_definitions( -DMAGICKCORE_QUANTUM_DEPTH=${MAGICKCORE_QUANTUM_DEPTH} )
- else()
- add_definitions( -DMAGICKCORE_QUANTUM_DEPTH=16 )
- endif()
-
- if(MAGICKCORE_HDRI_ENABLE)
- add_definitions( -DMAGICKCORE_HDRI_ENABLE=${MAGICKCORE_HDRI_ENABLE} )
- else()
- add_definitions( -DMAGICKCORE_HDRI_ENABLE=0 )
- endif()
-
- if(OPENSHOT_IMAGEMAGICK_COMPATIBILITY)
- add_definitions( -DOPENSHOT_IMAGEMAGICK_COMPATIBILITY=${OPENSHOT_IMAGEMAGICK_COMPATIBILITY} )
- else()
- add_definitions( -DOPENSHOT_IMAGEMAGICK_COMPATIBILITY=0 )
- endif()
-
- # Find the ImageMagick++ library
- find_package(ImageMagick COMPONENTS Magick++ MagickWand MagickCore)
- if(ImageMagick_FOUND)
- # Include ImageMagick++ headers (needed for compile)
- include_directories(${ImageMagick_INCLUDE_DIRS})
-
- # define a global var (used in the C++)
- add_definitions( -DUSE_IMAGEMAGICK=1 )
- endif()
-endif()
-################# LIBOPENSHOT-AUDIO ###################
-# Find JUCE-based openshot Audio libraries
-find_package(OpenShotAudio 0.2.0 REQUIRED)
-
-# Include Juce headers (needed for compile)
-include_directories(${LIBOPENSHOT_AUDIO_INCLUDE_DIRS})
-
################# BLACKMAGIC DECKLINK ###################
if(ENABLE_BLACKMAGIC)
diff --git a/tests/Cache_Tests.cpp b/tests/Cache_Tests.cpp
index ddf698f54..d834a0031 100644
--- a/tests/Cache_Tests.cpp
+++ b/tests/Cache_Tests.cpp
@@ -31,8 +31,8 @@
#include "UnitTest++.h"
// Prevent name clashes with juce::UnitTest
#define DONT_SET_USING_JUCE_NAMESPACE 1
-#include "../include/OpenShot.h"
-#include "../include/Json.h"
+#include "OpenShot.h"
+#include "Json.h"
using namespace openshot;
diff --git a/tests/Clip_Tests.cpp b/tests/Clip_Tests.cpp
index f72d8b05e..2f2e850c3 100644
--- a/tests/Clip_Tests.cpp
+++ b/tests/Clip_Tests.cpp
@@ -37,7 +37,7 @@
// Prevent name clashes with juce::UnitTest
#define DONT_SET_USING_JUCE_NAMESPACE 1
-#include "../include/OpenShot.h"
+#include "OpenShot.h"
using namespace openshot;
diff --git a/tests/Color_Tests.cpp b/tests/Color_Tests.cpp
index 82c7d1803..81d6070eb 100644
--- a/tests/Color_Tests.cpp
+++ b/tests/Color_Tests.cpp
@@ -31,7 +31,7 @@
#include "UnitTest++.h"
// Prevent name clashes with juce::UnitTest
#define DONT_SET_USING_JUCE_NAMESPACE 1
-#include "../include/OpenShot.h"
+#include "OpenShot.h"
using namespace std;
using namespace openshot;
diff --git a/tests/Coordinate_Tests.cpp b/tests/Coordinate_Tests.cpp
index a666ce8c0..b57af38fc 100644
--- a/tests/Coordinate_Tests.cpp
+++ b/tests/Coordinate_Tests.cpp
@@ -31,7 +31,7 @@
#include "UnitTest++.h"
// Prevent name clashes with juce::UnitTest
#define DONT_SET_USING_JUCE_NAMESPACE 1
-#include "../include/OpenShot.h"
+#include "OpenShot.h"
using namespace std;
using namespace openshot;
diff --git a/tests/DummyReader_Tests.cpp b/tests/DummyReader_Tests.cpp
index c72be2d9f..b889391fd 100644
--- a/tests/DummyReader_Tests.cpp
+++ b/tests/DummyReader_Tests.cpp
@@ -32,7 +32,7 @@
// Prevent name clashes with juce::UnitTest
#define DONT_SET_USING_JUCE_NAMESPACE 1
-#include "../include/OpenShot.h"
+#include "OpenShot.h"
using namespace std;
using namespace openshot;
diff --git a/tests/FFmpegReader_Tests.cpp b/tests/FFmpegReader_Tests.cpp
index b79820ade..d6a2d6e71 100644
--- a/tests/FFmpegReader_Tests.cpp
+++ b/tests/FFmpegReader_Tests.cpp
@@ -31,7 +31,7 @@
#include "UnitTest++.h"
// Prevent name clashes with juce::UnitTest
#define DONT_SET_USING_JUCE_NAMESPACE 1
-#include "../include/OpenShot.h"
+#include "OpenShot.h"
using namespace std;
using namespace openshot;
diff --git a/tests/FFmpegWriter_Tests.cpp b/tests/FFmpegWriter_Tests.cpp
index cb75a118a..83764b619 100644
--- a/tests/FFmpegWriter_Tests.cpp
+++ b/tests/FFmpegWriter_Tests.cpp
@@ -31,7 +31,7 @@
#include "UnitTest++.h"
// Prevent name clashes with juce::UnitTest
#define DONT_SET_USING_JUCE_NAMESPACE 1
-#include "../include/OpenShot.h"
+#include "OpenShot.h"
using namespace std;
using namespace openshot;
diff --git a/tests/Fraction_Tests.cpp b/tests/Fraction_Tests.cpp
index 8f4f5f839..b061ba482 100644
--- a/tests/Fraction_Tests.cpp
+++ b/tests/Fraction_Tests.cpp
@@ -31,7 +31,7 @@
#include "UnitTest++.h"
// Prevent name clashes with juce::UnitTest
#define DONT_SET_USING_JUCE_NAMESPACE 1
-#include "../include/OpenShot.h"
+#include "OpenShot.h"
using namespace std;
using namespace openshot;
diff --git a/tests/FrameMapper_Tests.cpp b/tests/FrameMapper_Tests.cpp
index 921f3a155..777bdd7bf 100644
--- a/tests/FrameMapper_Tests.cpp
+++ b/tests/FrameMapper_Tests.cpp
@@ -31,7 +31,7 @@
#include "UnitTest++.h"
// Prevent name clashes with juce::UnitTest
#define DONT_SET_USING_JUCE_NAMESPACE 1
-#include "../include/OpenShot.h"
+#include "OpenShot.h"
using namespace std;
using namespace openshot;
diff --git a/tests/Frame_Tests.cpp b/tests/Frame_Tests.cpp
index a92906a3d..8c2ebc407 100644
--- a/tests/Frame_Tests.cpp
+++ b/tests/Frame_Tests.cpp
@@ -32,7 +32,7 @@
#include "UnitTest++.h"
// Prevent name clashes with juce::UnitTest
#define DONT_SET_USING_JUCE_NAMESPACE 1
-#include "../include/OpenShot.h"
+#include "OpenShot.h"
#include
diff --git a/tests/ImageWriter_Tests.cpp b/tests/ImageWriter_Tests.cpp
index eb7b31e98..d74907bf3 100644
--- a/tests/ImageWriter_Tests.cpp
+++ b/tests/ImageWriter_Tests.cpp
@@ -31,7 +31,7 @@
#include "UnitTest++.h"
// Prevent name clashes with juce::UnitTest
#define DONT_SET_USING_JUCE_NAMESPACE 1
-#include "../include/OpenShot.h"
+#include "OpenShot.h"
using namespace std;
using namespace openshot;
diff --git a/tests/KeyFrame_Tests.cpp b/tests/KeyFrame_Tests.cpp
index dbd81500e..840251654 100644
--- a/tests/KeyFrame_Tests.cpp
+++ b/tests/KeyFrame_Tests.cpp
@@ -31,7 +31,7 @@
#include "UnitTest++.h"
// Prevent name clashes with juce::UnitTest
#define DONT_SET_USING_JUCE_NAMESPACE 1
-#include "../include/OpenShot.h"
+#include "OpenShot.h"
using namespace std;
using namespace openshot;
diff --git a/tests/Point_Tests.cpp b/tests/Point_Tests.cpp
index dfe35d2a0..3e63778d8 100644
--- a/tests/Point_Tests.cpp
+++ b/tests/Point_Tests.cpp
@@ -31,7 +31,7 @@
#include "UnitTest++.h"
// Prevent name clashes with juce::UnitTest
#define DONT_SET_USING_JUCE_NAMESPACE 1
-#include "../include/OpenShot.h"
+#include "OpenShot.h"
using namespace std;
using namespace openshot;
diff --git a/tests/ReaderBase_Tests.cpp b/tests/ReaderBase_Tests.cpp
index 776529d3c..3e68b40dc 100644
--- a/tests/ReaderBase_Tests.cpp
+++ b/tests/ReaderBase_Tests.cpp
@@ -31,7 +31,7 @@
#include "UnitTest++.h"
// Prevent name clashes with juce::UnitTest
#define DONT_SET_USING_JUCE_NAMESPACE 1
-#include "../include/OpenShot.h"
+#include "OpenShot.h"
using namespace std;
using namespace openshot;
diff --git a/tests/Settings_Tests.cpp b/tests/Settings_Tests.cpp
index 65bd66a66..cc7b86d2e 100644
--- a/tests/Settings_Tests.cpp
+++ b/tests/Settings_Tests.cpp
@@ -31,7 +31,7 @@
#include "UnitTest++.h"
// Prevent name clashes with juce::UnitTest
#define DONT_SET_USING_JUCE_NAMESPACE 1
-#include "../include/OpenShot.h"
+#include "OpenShot.h"
using namespace std;
using namespace openshot;
diff --git a/tests/Timeline_Tests.cpp b/tests/Timeline_Tests.cpp
index 47683b792..536b21334 100644
--- a/tests/Timeline_Tests.cpp
+++ b/tests/Timeline_Tests.cpp
@@ -31,7 +31,7 @@
#include "UnitTest++.h"
// Prevent name clashes with juce::UnitTest
#define DONT_SET_USING_JUCE_NAMESPACE 1
-#include "../include/OpenShot.h"
+#include "OpenShot.h"
using namespace std;
using namespace openshot;