Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 9 additions & 12 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,23 +6,24 @@ option(MV_UNITY_BUILD "Combine target source files into batches for faster compi
# SpectralView Plugin
# -----------------------------------------------------------------------------
set(SVPLUGIN "SpectralViewPlugin")

PROJECT(${SVPLUGIN})
PROJECT(${SVPLUGIN}
DESCRIPTION "View plugin for ManiVault for spectral data"
LANGUAGES CXX
)

# -----------------------------------------------------------------------------
# CMake Options
# -----------------------------------------------------------------------------
set(CMAKE_INCLUDE_CURRENT_DIR ON)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTORCC ON)
set(CMAKE_AUTOUIC ON)

if(MSVC)
if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /DWIN32 /EHsc /MP /permissive- /Zc:__cplusplus /W3")
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /MDd")
set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "${CMAKE_CXX_FLAGS_RELWITHDEBINFO} /MD")
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /MD")
endif(MSVC)
endif()

# -----------------------------------------------------------------------------
# Dependencies
Expand Down Expand Up @@ -87,7 +88,7 @@ set(WEB

set(AUX
res/lineplot_resources.qrc
src/SpectralViewPlugin.json
PluginInfo.json
)

qt6_add_resources(RESOURCE_FILES res/lineplot_resources.qrc)
Expand All @@ -113,7 +114,6 @@ target_include_directories(${SVPLUGIN} PRIVATE "${ManiVault_INCLUDE_DIR}")
# -----------------------------------------------------------------------------
# Target properties
# -----------------------------------------------------------------------------
# Request C++17
target_compile_features(${SVPLUGIN} PRIVATE cxx_std_20)

if(MV_UNITY_BUILD)
Expand Down Expand Up @@ -147,16 +147,13 @@ add_custom_command(TARGET ${SVPLUGIN} POST_BUILD
--prefix ${ManiVault_INSTALL_DIR}/$<CONFIGURATION>
)

set_target_properties(${SVPLUGIN}
PROPERTIES
FOLDER ViewPlugins
)
mv_handle_plugin_config(${SVPLUGIN})

# -----------------------------------------------------------------------------
# Miscellaneous
# -----------------------------------------------------------------------------
# Automatically set the debug environment (command + working directory) for MSVC in debug mode
if(MSVC)
if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC")
set_property(TARGET ${SVPLUGIN} PROPERTY VS_DEBUGGER_WORKING_DIRECTORY $<IF:$<CONFIG:DEBUG>,${ManiVault_INSTALL_DIR}/Debug,$<IF:$<CONFIG:RELWITHDEBINFO>,${ManiVault_INSTALL_DIR}/RelWithDebInfo,${ManiVault_INSTALL_DIR}/Release>>)
set_property(TARGET ${SVPLUGIN} PROPERTY VS_DEBUGGER_COMMAND $<IF:$<CONFIG:DEBUG>,"${ManiVault_INSTALL_DIR}/Debug/ManiVault Studio.exe",$<IF:$<CONFIG:RELWITHDEBINFO>,"${ManiVault_INSTALL_DIR}/RelWithDebInfo/ManiVault Studio.exe","${ManiVault_INSTALL_DIR}/Release/ManiVault Studio.exe">>)
endif()
9 changes: 9 additions & 0 deletions PluginInfo.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"name" : "Spectral View",
"version" : {
"plugin" : "1.0.0",
"core" : ["1.3"]
},
"type" : "View",
"dependencies" : ["Points", "Cluster", "Images"]
}
2 changes: 1 addition & 1 deletion src/SpectralViewPlugin.h
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ class SpectralViewPluginFactory : public ViewPluginFactory
Q_INTERFACES(mv::plugin::ViewPluginFactory mv::plugin::PluginFactory)
Q_OBJECT
Q_PLUGIN_METADATA(IID "nl.tudelft.SpectralViewPlugin"
FILE "SpectralViewPlugin.json")
FILE "PluginInfo.json")

public:
SpectralViewPluginFactory();
Expand Down
5 changes: 0 additions & 5 deletions src/SpectralViewPlugin.json

This file was deleted.