c1b8eed3dff52c54f610f4fb466e28286825bd21
[blender-staging.git] / intern / cycles / kernel / kernel_textures.h
1 /*
2  * Copyright 2011, Blender Foundation.
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
19 #ifndef KERNEL_TEX
20 #define KERNEL_TEX(type, ttype, name)
21 #endif
22
23 #ifndef KERNEL_IMAGE_TEX
24 #define KERNEL_IMAGE_TEX(type, ttype, name)
25 #endif
26
27 /* bvh */
28 KERNEL_TEX(float4, texture_float4, __bvh_nodes)
29 KERNEL_TEX(float4, texture_float4, __tri_woop)
30 KERNEL_TEX(uint, texture_uint, __prim_visibility)
31 KERNEL_TEX(uint, texture_uint, __prim_index)
32 KERNEL_TEX(uint, texture_uint, __prim_object)
33 KERNEL_TEX(uint, texture_uint, __object_node)
34
35 /* objects */
36 KERNEL_TEX(float4, texture_float4, __objects)
37
38 /* triangles */
39 KERNEL_TEX(float4, texture_float4, __tri_normal)
40 KERNEL_TEX(float4, texture_float4, __tri_vnormal)
41 KERNEL_TEX(float4, texture_float4, __tri_vindex)
42 KERNEL_TEX(float4, texture_float4, __tri_verts)
43
44 /* attributes */
45 KERNEL_TEX(uint4, texture_uint4, __attributes_map)
46 KERNEL_TEX(float, texture_float, __attributes_float)
47 KERNEL_TEX(float4, texture_float4, __attributes_float3)
48
49 /* lights */
50 KERNEL_TEX(float4, texture_float4, __light_distribution)
51 KERNEL_TEX(float4, texture_float4, __light_data)
52 KERNEL_TEX(float2, texture_float2, __light_background_marginal_cdf)
53 KERNEL_TEX(float2, texture_float2, __light_background_conditional_cdf)
54
55 /* particles */
56 KERNEL_TEX(float4, texture_float4, __particles)
57
58 /* shaders */
59 KERNEL_TEX(uint4, texture_uint4, __svm_nodes)
60 KERNEL_TEX(uint, texture_uint, __shader_flag)
61 KERNEL_TEX(uint, texture_uint, __object_flag)
62
63 /* camera/film */
64 KERNEL_TEX(float, texture_float, __filter_table)
65
66 /* sobol */
67 KERNEL_TEX(uint, texture_uint, __sobol_directions)
68
69 /* image */
70 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_000)
71 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_001)
72 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_002)
73 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_003)
74 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_004)
75 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_005)
76 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_006)
77 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_007)
78 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_008)
79 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_009)
80 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_010)
81 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_011)
82 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_012)
83 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_013)
84 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_014)
85 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_015)
86 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_016)
87 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_017)
88 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_018)
89 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_019)
90 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_020)
91 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_021)
92 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_022)
93 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_023)
94 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_024)
95 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_025)
96 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_026)
97 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_027)
98 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_028)
99 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_029)
100 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_030)
101 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_031)
102 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_032)
103 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_033)
104 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_034)
105 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_035)
106 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_036)
107 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_037)
108 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_038)
109 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_039)
110 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_040)
111 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_041)
112 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_042)
113 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_043)
114 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_044)
115 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_045)
116 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_046)
117 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_047)
118 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_048)
119 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_049)
120 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_050)
121 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_051)
122 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_052)
123 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_053)
124 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_054)
125 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_055)
126 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_056)
127 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_057)
128 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_058)
129 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_059)
130 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_060)
131 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_061)
132 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_062)
133 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_063)
134 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_064)
135 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_065)
136 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_066)
137 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_067)
138 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_068)
139 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_069)
140 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_070)
141 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_071)
142 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_072)
143 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_073)
144 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_074)
145 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_075)
146 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_076)
147 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_077)
148 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_078)
149 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_079)
150 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_080)
151 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_081)
152 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_082)
153 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_083)
154 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_084)
155 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_085)
156 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_086)
157 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_087)
158 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_088)
159 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_089)
160 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_090)
161 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_091)
162 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_092)
163 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_093)
164 KERNEL_IMAGE_TEX(uchar4, texture_image_uchar4, __tex_image_094)
165
166 /* full-float image */
167 KERNEL_IMAGE_TEX(float4, texture_image_float4, __tex_image_float_095)
168 KERNEL_IMAGE_TEX(float4, texture_image_float4, __tex_image_float_096)
169 KERNEL_IMAGE_TEX(float4, texture_image_float4, __tex_image_float_097)
170 KERNEL_IMAGE_TEX(float4, texture_image_float4, __tex_image_float_098)
171 KERNEL_IMAGE_TEX(float4, texture_image_float4, __tex_image_float_099)
172
173 /* packed image (opencl) */
174 KERNEL_TEX(uchar4, texture_uchar4, __tex_image_packed)
175 KERNEL_TEX(uint4, texture_uint4, __tex_image_packed_info)
176
177 #undef KERNEL_TEX
178 #undef KERNEL_IMAGE_TEX
179
180