Add option for CMake to build libredcode, also use CODEC prefix for ffmpeg, quicktime...
[blender-staging.git] / source / blender / imbuf / CMakeLists.txt
1 # $Id$
2 # ***** BEGIN GPL LICENSE BLOCK *****
3 #
4 # This program is free software; you can redistribute it and/or
5 # modify it under the terms of the GNU General Public License
6 # as published by the Free Software Foundation; either version 2
7 # of the License, or (at your option) any later version.
8 #
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12 # GNU General Public License for more details.
13 #
14 # You should have received a copy of the GNU General Public License
15 # along with this program; if not, write to the Free Software Foundation,
16 # Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
17 #
18 # The Original Code is Copyright (C) 2006, Blender Foundation
19 # All rights reserved.
20 #
21 # The Original Code is: all of this file.
22 #
23 # Contributor(s): Jacques Beaurain.
24 #
25 # ***** END GPL LICENSE BLOCK *****
26
27 SET(INC 
28         .
29         ../avi
30         ../blenlib
31         ../blenkernel
32         ../makesdna
33         ../../../intern/memutil
34         ../../../intern/guardedalloc
35         ${JPEG_INC}
36         ${PNG_INC}
37         ${ZLIB_INC}
38 )
39
40 SET(SRC
41         intern/allocimbuf.c
42         intern/anim_movie.c
43         intern/bmp.c
44         intern/cache.c
45         intern/divers.c
46         intern/filetype.c
47         intern/filter.c
48         intern/imageprocess.c
49         intern/iris.c
50         intern/jp2.c
51         intern/jpeg.c
52         intern/md5.c
53         intern/metadata.c
54         intern/module.c
55         intern/png.c
56         intern/radiance_hdr.c
57         intern/readimage.c
58         intern/rectop.c
59         intern/rotate.c
60         intern/scaling.c
61         intern/targa.c
62         intern/thumbs.c
63         intern/thumbs_blend.c
64         intern/tiff.c
65         intern/util.c
66         intern/writeimage.c
67
68         IMB_imbuf.h
69         IMB_imbuf_types.h
70         IMB_thumbs.h
71         intern/IMB_allocimbuf.h
72         intern/IMB_anim.h
73         intern/IMB_filetype.h
74         intern/IMB_filter.h
75         intern/IMB_metadata.h
76         intern/cineon/cin_debug_stuff.h
77         intern/cineon/cineonfile.h
78         intern/cineon/cineonlib.h
79         intern/cineon/dpxfile.h
80         intern/cineon/dpxlib.h
81         intern/cineon/logImageCore.h
82         intern/cineon/logImageLib.h
83         intern/cineon/logmemfile.h
84         intern/dds/BlockDXT.h
85         intern/dds/Color.h
86         intern/dds/ColorBlock.h
87         intern/dds/Common.h
88         intern/dds/DirectDrawSurface.h
89         intern/dds/Image.h
90         intern/dds/PixelFormat.h
91         intern/dds/Stream.h
92         intern/dds/dds_api.h
93         intern/imbuf.h
94         intern/md5.h
95         intern/openexr/openexr_api.h
96         intern/openexr/openexr_multi.h
97 )
98
99 IF(WITH_IMAGE_OPENEXR)
100         ADD_DEFINITIONS(-DWITH_OPENEXR)
101 ENDIF(WITH_IMAGE_OPENEXR)
102
103 IF(WITH_IMAGE_TIFF)
104         LIST(APPEND INC ${TIFF_INCLUDE_DIR})
105         ADD_DEFINITIONS(-DWITH_TIFF)
106 ENDIF(WITH_IMAGE_TIFF)
107
108 IF(WITH_IMAGE_OPENJPEG)
109         LIST(APPEND INC ${OPENJPEG_INC})
110         ADD_DEFINITIONS(-DWITH_OPENJPEG)
111 ENDIF(WITH_IMAGE_OPENJPEG)
112
113 IF(WITH_IMAGE_REDCODE)
114         LIST(APPEND INC ${REDCODE_INC})
115         ADD_DEFINITIONS(-DWITH_REDCODE)
116 ENDIF(WITH_IMAGE_REDCODE)
117
118 IF(WITH_CODEC_QUICKTIME)
119         LIST(APPEND INC
120                 ../quicktime
121                 ${QUICKTIME_INC}
122         )
123         ADD_DEFINITIONS(-DWITH_QUICKTIME)
124 ENDIF(WITH_CODEC_QUICKTIME)
125
126 IF(WITH_CODEC_FFMPEG)
127         LIST(APPEND INC ${FFMPEG_INC})
128         ADD_DEFINITIONS(-DWITH_FFMPEG)
129 ENDIF(WITH_CODEC_FFMPEG)
130
131 IF(WITH_IMAGE_DDS)
132         ADD_DEFINITIONS(-DWITH_DDS)
133 ENDIF(WITH_IMAGE_DDS)
134
135 IF(WITH_IMAGE_CINEON)
136         ADD_DEFINITIONS(-DWITH_CINEON)
137 ENDIF(WITH_IMAGE_CINEON)
138
139 IF(WITH_IMAGE_HDR)
140         ADD_DEFINITIONS(-DWITH_HDR)
141 ENDIF(WITH_IMAGE_HDR)
142
143 BLENDERLIB(bf_imbuf "${SRC}" "${INC}")