-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix closing of editors on window close
- Loading branch information
1 parent
0418a39
commit 4cae3c0
Showing
14 changed files
with
206 additions
and
188 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,78 +1,51 @@ | ||
cmake_minimum_required(VERSION 3.8 FATAL_ERROR) | ||
project(ffmpeg_node_editor LANGUAGES C CXX) | ||
|
||
set(CMAKE_CXX_STANDARD 17) | ||
set(CMAKE_CXX_STANDARD 20) | ||
set(CMAKE_EXPORT_COMPILE_COMMANDS | ||
ON | ||
CACHE INTERNAL "") | ||
|
||
find_package(Backward CONFIG REQUIRED) | ||
find_package(OpenGL REQUIRED) | ||
find_package(glfw3 REQUIRED) | ||
find_package(nlohmann_json CONFIG REQUIRED) | ||
find_package(reproc CONFIG REQUIRED) | ||
find_package(reproc++ CONFIG REQUIRED) | ||
find_package(spdlog CONFIG REQUIRED) | ||
find_package(nlohmann_json CONFIG REQUIRED) | ||
|
||
# Import non vcpkg stuff | ||
add_subdirectory(./third_party) | ||
|
||
add_executable( | ||
ffmpeg_node_editor | ||
src/backend.cpp | ||
src/backend_opengl.cpp | ||
src/backend_win32_d3d12.cpp | ||
add_library( | ||
core STATIC | ||
src/ffmpeg/filter_graph.cpp | ||
src/ffmpeg/profile.cpp | ||
src/ffmpeg/runner.cpp | ||
src/file_utils.cpp | ||
src/imgui_extras.cpp | ||
src/main.cpp | ||
src/node_editor.cpp | ||
src/pref.cpp | ||
src/string_utils.cpp) | ||
|
||
target_include_directories(ffmpeg_node_editor | ||
PUBLIC "${CMAKE_SOURCE_DIR}/include") | ||
|
||
target_include_directories(core PUBLIC "${CMAKE_SOURCE_DIR}/include") | ||
target_link_libraries( | ||
ffmpeg_node_editor | ||
PRIVATE ${OPENGL_gl_LIBRARY} | ||
Backward::Interface | ||
IconFontCppHeaders | ||
glfw | ||
imgui | ||
nlohmann_json::nlohmann_json | ||
reproc | ||
reproc++ | ||
spdlog::spdlog | ||
tinyfiledialogs) | ||
|
||
if(MSVC AND FALSE) | ||
target_compile_definitions(ffmpeg_node_editor | ||
PUBLIC FFMPEG_NODE_EDITOR_USE_WIN32_D3D12) | ||
target_link_libraries(ffmpeg_node_editor PRIVATE d3d12.lib d3dcompiler.lib | ||
dxgi.lib) | ||
else() | ||
target_compile_definitions(ffmpeg_node_editor | ||
PUBLIC FFMPEG_NODE_EDITOR_USE_GLFW_OPENGL) | ||
endif() | ||
core | ||
PUBLIC imgui | ||
spdlog::spdlog | ||
tinyfiledialogs | ||
nlohmann_json::nlohmann_json | ||
IconFontCppHeaders | ||
reproc | ||
reproc++) | ||
|
||
# Main Executable | ||
add_executable(ffmpeg_node_editor src/backend.cpp src/backend_glfw_opengl.cpp | ||
src/backend_win32_d3d12.cpp src/main.cpp) | ||
target_link_libraries(ffmpeg_node_editor PRIVATE core Backward::Interface) | ||
|
||
# Setup Test, coverage and benchmarks | ||
find_package(GTest CONFIG REQUIRED) | ||
|
||
set(TEST_SRCS | ||
src/ffmpeg/runner_test.cpp src/ffmpeg/runner.cpp src/imgui_extras_test.cpp | ||
src/imgui_extras.cpp src/string_utils.cpp src/util_test.cpp) | ||
add_executable(tests src/ffmpeg/runner_test.cpp src/imgui_extras_test.cpp | ||
src/util_test.cpp) | ||
|
||
add_executable(tests ${TEST_SRCS}) | ||
target_include_directories(tests PUBLIC "${CMAKE_SOURCE_DIR}/include") | ||
target_link_libraries( | ||
tests | ||
PRIVATE GTest::gtest | ||
GTest::gtest_main | ||
imgui | ||
IconFontCppHeaders | ||
reproc | ||
reproc++ | ||
spdlog::spdlog) | ||
target_link_libraries(tests PRIVATE GTest::gtest GTest::gtest_main core) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.