option( CASTOR_BUILD_PLUGINS "Build Castor3D plugins" TRUE ) option( CASTOR_BUILDGRP_GENERATOR "Build Castor3D Generator plugins" TRUE ) option( CASTOR_BUILDGRP_GENERIC "Build Castor3D Generic plugins" ON ) option( CASTOR_BUILDGRP_IMPORTER "Build Castor3D Importer plugins" TRUE ) option( CASTOR_BUILDGRP_PARTICLES "Build Castor3D Particles plugins" TRUE ) option( CASTOR_BUILDGRP_POSTFX "Build Castor3D PostEffect plugins" TRUE ) option( CASTOR_BUILDGRP_TONEMAPS "Build Castor3D Tone mapping plug-ins" TRUE ) if ( ${CASTOR_BUILD_PLUGINS} ) if ( CASTOR_BUILDGRP_GENERATOR ) add_subdirectory( Generators ) endif () if ( CASTOR_BUILDGRP_GENERIC ) add_subdirectory( Generic ) endif () if ( CASTOR_BUILDGRP_IMPORTER ) add_subdirectory( Importers ) endif () if ( CASTOR_BUILDGRP_PARTICLES ) add_subdirectory( Particles ) endif () if ( CASTOR_BUILDGRP_POSTFX ) add_subdirectory( PostEffects ) endif () if ( CASTOR_BUILDGRP_TONEMAPS ) add_subdirectory( ToneMappings ) endif () endif () macro( PluginsInit ) if ( ${CASTOR_BUILD_PLUGINS} ) if ( CASTOR_BUILDGRP_GENERATOR ) GeneratorInit() endif () if ( CASTOR_BUILDGRP_GENERIC ) GenericInit() endif () if ( CASTOR_BUILDGRP_IMPORTER ) ImportersInit() endif () if ( CASTOR_BUILDGRP_PARTICLES ) ParticlesInit() endif () if ( CASTOR_BUILDGRP_POSTFX ) PostEffectsInit() endif () if ( CASTOR_BUILDGRP_TONEMAPS ) ToneMappingsInit() endif () endif () endmacro() macro( PluginsBuild ) if ( ${CASTOR_BUILD_PLUGINS} ) if ( CASTOR_BUILDGRP_GENERATOR ) GeneratorBuild() endif () if ( CASTOR_BUILDGRP_GENERIC ) GenericBuild() endif () if ( CASTOR_BUILDGRP_IMPORTER ) ImportersBuild() endif () if ( CASTOR_BUILDGRP_PARTICLES ) ParticlesBuild() endif () if ( CASTOR_BUILDGRP_POSTFX ) PostEffectsBuild() endif () if ( CASTOR_BUILDGRP_TONEMAPS ) ToneMappingsBuild() endif () set( CASTOR_INSTEXP_PLUGINS ${CASTOR_INSTEXP_PLUGINS} PARENT_SCOPE ) set( ADDITIONAL_DEPS_REL ${ADDITIONAL_DEPS_REL} PARENT_SCOPE ) set( ADDITIONAL_DEPS_DBG ${ADDITIONAL_DEPS_DBG} PARENT_SCOPE ) endif () endmacro() macro( PluginsSummary ) if ( ${CASTOR_BUILD_PLUGINS} ) if ( CASTOR_BUILDGRP_GENERATOR ) GeneratorSummary( ${msg} ) endif () if ( CASTOR_BUILDGRP_GENERIC ) GenericSummary( ${msg} ) endif () if ( CASTOR_BUILDGRP_IMPORTER ) ImportersSummary( ${msg} ) endif () if ( CASTOR_BUILDGRP_PARTICLES ) ParticlesSummary( ${msg} ) endif () if ( CASTOR_BUILDGRP_POSTFX ) PostEffectsSummary( ${msg} ) endif () if ( CASTOR_BUILDGRP_TONEMAPS ) ToneMappingsSummary( ${msg} ) endif () endif () endmacro() macro( PluginsSetup ) if ( ${CASTOR_BUILD_PLUGINS} ) if ( CASTOR_BUILDGRP_GENERATOR ) GeneratorSetup() endif () if ( CASTOR_BUILDGRP_GENERIC ) GenericSetup() endif () if ( CASTOR_BUILDGRP_IMPORTER ) ImportersSetup() endif () if ( CASTOR_BUILDGRP_PARTICLES ) ParticlesSetup() endif () if ( CASTOR_BUILDGRP_POSTFX ) PostEffectsSetup() endif () if ( CASTOR_BUILDGRP_TONEMAPS ) ToneMappingsSetup() endif () endif () endmacro()