2007-04-29 17:35:43 +00:00
# Adds effect plugin with given name. Sources are given after the name
macro(KWIN4_ADD_EFFECT name)
kde4_add_plugin(kwin4_effect_${name} ${ARGN})
target_link_libraries(kwin4_effect_${name} kwineffects ${KDE4_KDEUI_LIBS})
install(TARGETS kwin4_effect_${name} DESTINATION ${PLUGIN_INSTALL_DIR})
endmacro(KWIN4_ADD_EFFECT)
2007-05-28 11:34:12 +00:00
macro(KWIN4_ADD_EFFECT_CONFIG name)
kde4_add_plugin(kcm_kwin4_effect_${name} ${ARGN})
2007-05-29 11:48:10 +00:00
target_link_libraries(kcm_kwin4_effect_${name} kwineffects ${KDE4_KDEUI_LIBS})
2007-05-28 11:34:12 +00:00
install(TARGETS kcm_kwin4_effect_${name} DESTINATION ${PLUGIN_INSTALL_DIR})
endmacro(KWIN4_ADD_EFFECT_CONFIG)
2007-04-29 17:35:43 +00:00
include_directories(
2007-06-25 11:03:18 +00:00
${KDEBASE_WORKSPACE_SOURCE_DIR}/kwin/lib
2007-04-29 17:35:43 +00:00
)
2007-05-28 11:12:20 +00:00
install( FILES kwineffect.desktop DESTINATION ${SERVICETYPES_INSTALL_DIR})
2007-05-22 16:58:10 +00:00
### builtins - most important, ready-to-use effects
# sources
2007-04-29 17:35:43 +00:00
SET(kwin4_effect_builtins_sources
boxswitch.cpp
desktopgrid.cpp
dialogparent.cpp
diminactive.cpp
fade.cpp
fallapart.cpp
flame.cpp
maketransparent.cpp
minimizeanimation.cpp
presentwindows.cpp
scalein.cpp
thumbnailaside.cpp
zoom.cpp
)
2007-05-22 16:58:10 +00:00
# their .desktop files
install( FILES
boxswitch.desktop
desktopgrid.desktop
dialogparent.desktop
diminactive.desktop
fade.desktop
fallapart.desktop
flame.desktop
maketransparent.desktop
minimizeanimation.desktop
presentwindows.desktop
scalein.desktop
thumbnailaside.desktop
zoom.desktop
2007-05-28 11:12:20 +00:00
DESTINATION ${SERVICES_INSTALL_DIR}/kwin )
2007-04-29 17:35:43 +00:00
2007-10-21 13:44:40 +00:00
# config modules
KWIN4_ADD_EFFECT_CONFIG( builtins
presentwindows_config.cpp
shadow_config.cpp
desktopgrid_config.cpp
configs_builtins.cpp)
install( FILES
presentwindows_config.desktop
shadow_config.desktop
desktopgrid_config.desktop
DESTINATION ${SERVICES_INSTALL_DIR}/kwin )
2007-04-29 17:35:43 +00:00
if(OPENGL_FOUND)
2007-05-22 16:58:10 +00:00
# opengl-based effects
2007-04-29 17:35:43 +00:00
SET(kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources}
blur.cpp
explosioneffect.cpp
2007-07-04 09:59:07 +00:00
invert.cpp
2007-07-13 13:22:09 +00:00
lookingglass.cpp
2007-04-29 17:35:43 +00:00
magnifier.cpp
mousemark.cpp
shadow.cpp
2007-07-04 10:01:04 +00:00
sharpen.cpp
2007-04-29 17:35:43 +00:00
trackmouse.cpp
)
install( FILES
blur.desktop
explosion.desktop
2007-07-04 09:59:07 +00:00
invert.desktop
2007-07-13 13:22:09 +00:00
lookingglass.desktop
2007-04-29 17:35:43 +00:00
magnifier.desktop
mousemark.desktop
shadow.desktop
2007-07-04 10:01:04 +00:00
sharpen.desktop
2007-04-29 17:35:43 +00:00
trackmouse.desktop
2007-05-28 11:12:20 +00:00
DESTINATION ${SERVICES_INSTALL_DIR}/kwin )
2007-04-29 17:35:43 +00:00
install( FILES
data/trackmouse.png
data/explosion.frag
data/explosion.vert
data/explosion-start.png
data/explosion-end.png
data/blur.frag
data/blur.vert
data/blur-render.frag
data/blur-render.vert
2007-07-04 09:59:07 +00:00
data/invert.frag
data/invert.vert
2007-07-04 10:01:04 +00:00
data/sharpen.frag
data/sharpen.vert
2007-07-13 13:22:09 +00:00
data/lookingglass.frag
data/lookingglass.vert
2007-07-04 11:46:50 +00:00
data/shadow-texture.png
2007-07-04 20:33:35 +00:00
data/circle.png
2007-08-24 15:44:52 +00:00
data/circle-edgy.png
2007-04-29 17:35:43 +00:00
DESTINATION ${DATA_INSTALL_DIR}/kwin )
endif(OPENGL_FOUND)
2007-05-22 16:58:10 +00:00
# showfps - need both xrender and opengl
2007-04-29 17:35:43 +00:00
if( OPENGL_FOUND AND X11_Xrender_FOUND )
SET(kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources}
showfps.cpp
)
install( FILES
showfps.desktop
2007-05-28 11:12:20 +00:00
DESTINATION ${SERVICES_INSTALL_DIR}/kwin )
2007-04-29 17:35:43 +00:00
endif( OPENGL_FOUND AND X11_Xrender_FOUND )
2007-05-22 16:58:10 +00:00
# add the plugin
2007-04-29 17:35:43 +00:00
KWIN4_ADD_EFFECT(builtins ${kwin4_effect_builtins_sources})
2007-05-22 16:58:10 +00:00
# link to xrender if necessary
# note that libkwineffects already links to opengl, so no need to add this here
2007-04-29 17:35:43 +00:00
if (X11_Xrender_FOUND)
target_link_libraries(kwin4_effect_builtins ${X11_Xrender_LIB})
endif (X11_Xrender_FOUND)
2007-05-22 16:58:10 +00:00
### tests - meant to test/demo certain functionality, not really usable for end-users
SET(kwin4_effect_tests_sources
2007-07-03 14:44:38 +00:00
demo_shakymove.cpp
2007-05-22 16:58:10 +00:00
demo_shiftworkspaceup.cpp
demo_taskbarthumbnail.cpp
drunken.cpp
howto.cpp
test_input.cpp
test_thumbnail.cpp
)
2007-04-29 17:35:43 +00:00
install( FILES
2007-07-03 14:44:38 +00:00
demo_shakymove.desktop
2007-05-22 16:58:10 +00:00
demo_shiftworkspaceup.desktop
demo_taskbarthumbnail.desktop
2007-04-29 17:35:43 +00:00
drunken.desktop
howto.desktop
test_input.desktop
test_thumbnail.desktop
2007-05-28 11:12:20 +00:00
DESTINATION ${SERVICES_INSTALL_DIR}/kwin )
2007-04-29 17:35:43 +00:00
2007-05-22 16:58:10 +00:00
if(OPENGL_FOUND)
# opengl test/demo stuff
SET(kwin4_effect_tests_sources ${kwin4_effect_tests_sources}
demo_liquid.cpp
demo_showpicture.cpp
2007-07-03 14:44:38 +00:00
demo_wavywindows.cpp
2007-05-22 16:58:10 +00:00
test_fbo.cpp
)
install( FILES
demo_liquid.desktop
demo_showpicture.desktop
2007-07-03 14:44:38 +00:00
demo_wavywindows.desktop
2007-05-22 16:58:10 +00:00
test_fbo.desktop
2007-05-28 11:12:20 +00:00
DESTINATION ${SERVICES_INSTALL_DIR}/kwin )
2007-05-22 16:58:10 +00:00
install( FILES
data/liquid.frag
data/liquid.vert
DESTINATION ${DATA_INSTALL_DIR}/kwin )
endif(OPENGL_FOUND)
# add the plugin
KWIN4_ADD_EFFECT(tests ${kwin4_effect_tests_sources})
### videocapture plugin
2007-04-29 17:35:43 +00:00
include(UsePkgConfig)
PKGCONFIG(libcaptury CAPTURY_INCLUDES CAPTURY_LINK_DIR CAPTURY_LDFLAGS CAPTURY_CFLAGS)
if( CAPTURY_LDFLAGS )
SET( CAPTURY_FOUND TRUE )
endif( CAPTURY_LDFLAGS )
2007-08-31 13:10:27 +00:00
macro_log_feature(CAPTURY_FOUND "Capseo framework" "libcaptury is a framework realtime video capturing for e.g. screen casts" "http://rm-rf.in/captury")
2007-04-29 17:35:43 +00:00
macro_bool_to_01( CAPTURY_FOUND HAVE_CAPTURY )
if( HAVE_CAPTURY )
KWIN4_ADD_EFFECT(videorecord videorecord.cpp)
target_link_libraries(kwin4_effect_videorecord ${CAPTURY_LDFLAGS})
2007-05-28 11:12:20 +00:00
install( FILES videorecord.desktop DESTINATION ${SERVICES_INSTALL_DIR}/kwin )
2007-04-29 17:35:43 +00:00
endif( HAVE_CAPTURY )