faeb0f721f44e7de3ee1273f0b4fcd02bd48fff5
[blender.git] / source / blender / gpu / CMakeLists.txt
1 # ***** BEGIN GPL LICENSE BLOCK *****
2 #
3 # This program is free software; you can redistribute it and/or
4 # modify it under the terms of the GNU General Public License
5 # as published by the Free Software Foundation; either version 2
6 # of the License, or (at your option) any later version.
7 #
8 # This program is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
11 # GNU General Public License for more details.
12 #
13 # You should have received a copy of the GNU General Public License
14 # along with this program; if not, write to the Free Software Foundation,
15 # Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
16 #
17 # The Original Code is Copyright (C) 2006, Blender Foundation
18 # All rights reserved.
19 #
20 # The Original Code is: all of this file.
21 #
22 # Contributor(s): Jacques Beaurain.
23 #
24 # ***** END GPL LICENSE BLOCK *****
25
26 set(INC
27         .
28         ../blenkernel
29         ../blenlib
30         ../blenloader
31         ../bmesh
32         ../imbuf
33         ../makesdna
34         ../makesrna
35
36         # For node muting stuff...
37         ../nodes
38         ../nodes/intern
39
40         ../../../intern/guardedalloc
41         ../../../intern/smoke/extern
42 )
43
44 set(INC_SYS
45         ${GLEW_INCLUDE_PATH}
46 )
47
48 set(SRC
49         intern/gpu_buffers.c
50         intern/gpu_codegen.c
51         intern/gpu_draw.c
52         intern/gpu_extensions.c
53         intern/gpu_fixed_material.c
54         intern/gpu_material.c
55
56         GPU_buffers.h
57         GPU_draw.h
58         GPU_extensions.h
59         GPU_material.h
60         intern/gpu_codegen.h
61 )
62
63 data_to_c_simple(shaders/gpu_shader_fixed_fragment.glsl SRC)
64 data_to_c_simple(shaders/gpu_shader_fixed_vertex.glsl SRC)
65 data_to_c_simple(shaders/gpu_shader_material.glsl SRC)
66 data_to_c_simple(shaders/gpu_shader_sep_gaussian_blur_frag.glsl SRC)
67 data_to_c_simple(shaders/gpu_shader_sep_gaussian_blur_vert.glsl SRC)
68 data_to_c_simple(shaders/gpu_shader_vertex.glsl SRC)
69 data_to_c_simple(shaders/gpu_shader_vsm_store_frag.glsl SRC)
70 data_to_c_simple(shaders/gpu_shader_vsm_store_vert.glsl SRC)
71
72 if(WITH_MOD_SMOKE)
73         add_definitions(-DWITH_SMOKE)
74 endif()
75
76 add_definitions(-DGLEW_STATIC)
77
78 if(WITH_IMAGE_DDS)
79         add_definitions(-DWITH_DDS)
80 endif()
81
82
83 blender_add_lib(bf_gpu "${SRC}" "${INC}" "${INC_SYS}")
84