Add GLFFT sources

This commit is contained in:
Jarcode
2019-09-11 23:04:22 -07:00
parent 6f1680b335
commit 580e296e86
3 changed files with 31 additions and 17 deletions

View File

@@ -133,7 +133,19 @@ The below copyright notice applies for the original versions of these files:
`Copyright (c) 2015 Karl Stavestrand <karl@stavestrand.no>`
The modified files are relicensed under the terms of the GPLv3. The MIT license is included for your convience and to satisfy the requirements of the original license, although it no longer applies to any code in this repository. You will find the original copyright notice and MIT license in the `LICENSE_ORIGINAL` file.
GLava also contains GLFFT, an excellent FFT implementation using Opengl 4.3 compute shaders. This was also initiallly provided under the MIT license, and applies to the following source files (where `*` refers to both `hpp` and `cpp`):
- `glfft/glfft.*`
- `glfft/glfft_common.hpp`
- `glfft/glfft_gl_interface.*`
- `glfft/glfft_interface.hpp`
- `glfft/glfft_wisdom.*`
The below copyright notice applies for the original versions of these files:
`Copyright (c) 2015 Hans-Kristian Arntzen <maister@archlinux.us>`
**The noted files above are all sublicensed under the terms of the GPLv3**. The MIT license is included for your convience and to satisfy the requirements of the original license, although it no longer applies to any code in this repository. You will find the original copyright notice and MIT license in the `LICENSE_ORIGINAL` file for cava, or `glfft/LICENSE_ORIGINAL` for GLFFT.
The below copyright applies for the modifications to the files listed above, and the remaining sources in the repository:

View File

@@ -1,6 +1,6 @@
project(
'glava',
'c',
['c', 'cpp'],
version: run_command('git', 'describe', '--tags').stdout().strip(),
default_options:['buildtype=release', 'strip=true', 'optimization=2'])
@@ -40,28 +40,28 @@ if glava_version == ''
endif
if host_machine.system() == 'linux' or host_machine.system() == 'bsd'
add_project_arguments('-DGLAVA_UNIX', language: 'c')
add_project_arguments('-DGLAVA_UNIX', language: ['cpp', 'c'])
endif
# Note: the OSX install directives only exist for future platform support
if host_machine.system() == 'darwin'
add_project_arguments('-DGLAVA_OSX', language: 'c')
add_project_arguments('-DGLAVA_OSX', language: ['cpp', 'c'])
error('OSX targets are not supported, see issue #86.')
# shader_dir = '/Library/glava/'
endif
if get_option('enable_glfw')
add_project_arguments('-DGLAVA_GLFW', language: 'c')
add_project_arguments('-DGLAVA_GLFW', language: ['cpp', 'c'])
glava_dependencies += cc.find_library('glfw')
endif
if not get_option('disable_glx')
add_project_arguments('-DGLAVA_GLX', language: 'c')
add_project_arguments('-DGLAVA_GLX', language: ['cpp', 'c'])
glava_dependencies += cc.find_library('Xrender')
endif
if get_option('standalone')
add_project_arguments('-DGLAVA_STANDALONE', language: 'c')
add_project_arguments('-DGLAVA_STANDALONE', language: ['cpp', 'c'])
endif
resource_dir = get_option('resource_install_dir')
@@ -73,9 +73,16 @@ add_project_arguments(
'-DGLAVA_VERSION="' + glava_version + '"',
'-DSHADER_INSTALL_PATH="' + shader_dir + '/glava"',
'-DGLAVA_RESOURCE_PATH="' + resource_dir + '/resources"',
'-I/usr/include/obs',
'-fvisibility=hidden',
language: 'c')
# todo: add back
# '-fvisibility=hidden',
language: ['cpp', 'c'])
glfft = static_library(
'glfft',
sources: run_command('find', 'glfft', '-type', 'f', '-name', '*.cpp', '-print')
.stdout().strip().split('\n'),
c_args: ['-std=c++11'],
dependencies: [ cc.find_library('dl') ])
libglava = shared_library(
'glava',
@@ -88,7 +95,7 @@ executable(
'glava',
sources: 'glava-cli/cli.c',
link_with: libglava,
c_args: '-I' + meson.source_root() + '/glava',
c_args: ['-I' + meson.source_root() + '/glava', '-std=c++11'],
install: true)
if not get_option('disable_config')
@@ -180,6 +187,7 @@ if not get_option('disable_obs')
install_dir: get_option('obs_plugin_install_dir'),
sources: 'glava-obs/entry.c',
link_with: libglava,
c_args: '-I/usr/include/obs',
dependencies: [
dependency('threads'),
cc.find_library('GL'),

View File

@@ -23,9 +23,3 @@
#define JOIN_CHANNELS 0
/* 1 to invert (vertically), 0 otherwise */
#define INVERT 0
/* Gravity step, overrude from `smooth_parameters.glsl` */
#request setgravitystep 2.4
/* Smoothing factor, override from `smooth_parameters.glsl` */
#request setsmoothfactor 0.015