summaryrefslogtreecommitdiff
path: root/src/lib/ector/CMakeLists.txt
blob: 133909192b237065c18bc8cf49a827280be6fd0a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
set(DESCRIPTION "Enlightened retained mode drawing library")

set(LIBRARIES
  eet
  efl
  emile
  m
)

set(PUBLIC_LIBRARIES
  eina
  eo
)

set(PUBLIC_EO_FILES
  ector_buffer.eo
  ector_renderer.eo
  ector_renderer_buffer.eo
  ector_renderer_gradient.eo
  ector_renderer_gradient_linear.eo
  ector_renderer_gradient_radial.eo
  ector_renderer_shape.eo
  ector_surface.eo
  ector_types.eot

  cairo/ector_cairo_software_surface.eo
  cairo/ector_cairo_surface.eo
  cairo/ector_renderer_cairo.eo
  cairo/ector_renderer_cairo_gradient_linear.eo
  cairo/ector_renderer_cairo_gradient_radial.eo
  cairo/ector_renderer_cairo_shape.eo

  gl/ector_gl_buffer.eo
  gl/ector_gl_buffer_base.eo
  gl/ector_gl_surface.eo
  gl/ector_renderer_gl.eo
  gl/ector_renderer_gl_gradient_linear.eo
  gl/ector_renderer_gl_gradient_radial.eo
  gl/ector_renderer_gl_shape.eo

  software/ector_renderer_software.eo
  software/ector_renderer_software_buffer.eo
  software/ector_renderer_software_gradient_linear.eo
  software/ector_renderer_software_gradient_radial.eo
  software/ector_renderer_software_shape.eo
  software/ector_software_buffer.eo
  software/ector_software_buffer_base.eo
  software/ector_software_surface.eo
)

set(PUBLIC_HEADERS
  Ector.h
  ector_buffer.h
  ector_renderer.h
  ector_surface.h
  ector_util.h

  cairo/Ector_Cairo.h

  gl/Ector_GL.h

  software/Ector_Software.h
)

set(SOURCES
  ector_buffer.c
  ector_gl_internal.h
  ector_main.c
  ector_renderer.c
  ector_renderer_buffer.c
  ector_renderer_gradient.c
  ector_renderer_gradient_linear.c
  ector_renderer_gradient_radial.c
  ector_renderer_shape.c

  cairo/ector_cairo_software_surface.c
  cairo/ector_cairo_surface.c
  cairo/ector_renderer_cairo.c
  cairo/ector_renderer_cairo_gradient_linear.c
  cairo/ector_renderer_cairo_gradient_radial.c
  cairo/ector_renderer_cairo_shape.c

  gl/ector_gl_buffer.c
  gl/ector_gl_buffer_base.c
  gl/ector_gl_private.h
  gl/ector_gl_shader.c
  gl/ector_gl_surface.c
  gl/ector_renderer_gl.c
  gl/ector_renderer_gl_gradient_linear.c
  gl/ector_renderer_gl_gradient_radial.c
  gl/ector_renderer_gl_shape.c
  gl/shader/ector_gl_shaders.x

  software/ector_renderer_software_buffer.c
  software/ector_renderer_software_gradient_linear.c
  software/ector_renderer_software_gradient_radial.c
  software/ector_renderer_software_shape.c
  software/ector_software_buffer.c
  software/ector_software_gradient.c
  software/ector_software_rasterizer.c
  software/ector_software_surface.c

  ${CMAKE_SOURCE_DIR}/src/static_libs/draw/draw_main.c
  ${CMAKE_SOURCE_DIR}/src/static_libs/draw/draw_main_neon.c
  ${CMAKE_SOURCE_DIR}/src/static_libs/draw/draw_main_sse2.c

  ${CMAKE_SOURCE_DIR}/src/static_libs/freetype/sw_ft_math.c
  ${CMAKE_SOURCE_DIR}/src/static_libs/freetype/sw_ft_raster.c
  ${CMAKE_SOURCE_DIR}/src/static_libs/freetype/sw_ft_stroker.c

  ${CMAKE_SOURCE_DIR}/src/static_libs/rg_etc/etc2_encoder.c
  ${CMAKE_SOURCE_DIR}/src/static_libs/rg_etc/rg_etc1.c
  ${CMAKE_SOURCE_DIR}/src/static_libs/rg_etc/rg_etc1.h
  ${CMAKE_SOURCE_DIR}/src/static_libs/rg_etc/rg_etc2.c

  ${CMAKE_SOURCE_DIR}/src/static_libs/triangulator/triangulator_simple.c
  ${CMAKE_SOURCE_DIR}/src/static_libs/triangulator/triangulator_simple.h
  ${CMAKE_SOURCE_DIR}/src/static_libs/triangulator/triangulator_stroker.c
  ${CMAKE_SOURCE_DIR}/src/static_libs/triangulator/triangulator_stroker.h
)

set(INCLUDE_DIRECTORIES
  ${CMAKE_SOURCE_DIR}/src/static_libs/draw
  ${CMAKE_SOURCE_DIR}/src/static_libs/freetype
  ${CMAKE_SOURCE_DIR}/src/static_libs/rg_etc
  ${CMAKE_SOURCE_DIR}/src/static_libs/triangulator
)

add_custom_command(
  OUTPUT ${EFL_LIB_SOURCE_DIR}/gl/shader/ector_gl_shaders.x
  COMMAND /bin/sh ${EFL_LIB_SOURCE_DIR}/gl/shader/gen_shaders.sh
  DEPENDS
  ${EFL_LIB_SOURCE_DIR}/gl/shader/gen_shaders.sh
  ${EFL_LIB_SOURCE_DIR}/gl/shader/fragment.glsl
  ${EFL_LIB_SOURCE_DIR}/gl/shader/vertex.glsl
  ${EFL_LIB_SOURCE_DIR}/gl/shader/include.glsl
  WORKING_DIRECTORY "${EFL_LIB_SOURCE_DIR}"
  COMMENT "SHADERS ${EFL_LIB_SOURCE_DIR}/gl/shader/ector_gl_shaders.x"
)