]> git.sesse.net Git - casparcg/blob - core/mixer/image/blend_modes.h
set svn:eol-style native on .h and .cpp files
[casparcg] / core / mixer / image / blend_modes.h
1 /*
2 * Copyright (c) 2011 Sveriges Television AB <info@casparcg.com>
3 *
4 * This file is part of CasparCG (www.casparcg.com).
5 *
6 * CasparCG is free software: you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation, either version 3 of the License, or
9 * (at your option) any later version.
10 *
11 * CasparCG is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with CasparCG. If not, see <http://www.gnu.org/licenses/>.
18 *
19 * Author: Robert Nagy, ronag89@gmail.com
20 */
21
22 #pragma once
23
24 #include <common/enum_class.h>
25
26 namespace caspar { namespace core {
27                 
28 struct blend_mode_def
29 {
30         enum type
31         {
32                 normal = 0,
33                 lighten,
34                 darken,
35                 multiply,
36                 average,
37                 add,
38                 subtract,
39                 difference,
40                 negation,
41                 exclusion,
42                 screen,
43                 overlay,
44                 soft_light,
45                 hard_light,
46                 color_dodge,
47                 color_burn,
48                 linear_dodge,
49                 linear_burn,
50                 linear_light,
51                 vivid_light,
52                 pin_light,
53                 hard_mix,
54                 reflect,
55                 glow,
56                 phoenix,
57                 contrast,
58                 saturation,
59                 color,
60                 luminosity,
61                 mix,
62                 blend_mode_count 
63         };
64 };
65 typedef enum_class<blend_mode_def> blend_mode;
66
67 blend_mode get_blend_mode(const std::wstring& str);
68
69 }}