blob: 7c29ce1a5e98dcebc9b7944268a37294b83c8623 [file] [log] [blame]
John Stilesf96cb712021-05-05 22:17:04 -04001/*
2 * Copyright 2021 Google LLC
3 *
4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file.
6 */
7
8#ifndef SKSL_INTRINSIC_LIST_DEFINED
9#define SKSL_INTRINSIC_LIST_DEFINED
10
11// A list of every intrinsic supported by SkSL.
12// Using an X-Macro (https://en.wikipedia.org/wiki/X_Macro) to manage the list.
13#define SKSL_INTRINSIC_LIST \
14 SKSL_INTRINSIC(abs) \
15 SKSL_INTRINSIC(acosh) \
16 SKSL_INTRINSIC(acos) \
17 SKSL_INTRINSIC(all) \
18 SKSL_INTRINSIC(any) \
19 SKSL_INTRINSIC(asinh) \
20 SKSL_INTRINSIC(asin) \
21 SKSL_INTRINSIC(atanh) \
22 SKSL_INTRINSIC(atan) \
23 SKSL_INTRINSIC(bitCount) \
24 SKSL_INTRINSIC(ceil) \
25 SKSL_INTRINSIC(clamp) \
26 SKSL_INTRINSIC(cosh) \
27 SKSL_INTRINSIC(cos) \
28 SKSL_INTRINSIC(cross) \
29 SKSL_INTRINSIC(degrees) \
30 SKSL_INTRINSIC(determinant) \
31 SKSL_INTRINSIC(dFdx) \
32 SKSL_INTRINSIC(dFdy) \
33 SKSL_INTRINSIC(distance) \
34 SKSL_INTRINSIC(dot) \
John Stilesf96cb712021-05-05 22:17:04 -040035 SKSL_INTRINSIC(equal) \
Brian Osman3099f792021-09-01 13:12:16 -040036 SKSL_INTRINSIC(eval) \
John Stilesf96cb712021-05-05 22:17:04 -040037 SKSL_INTRINSIC(exp2) \
38 SKSL_INTRINSIC(exp) \
39 SKSL_INTRINSIC(faceforward) \
40 SKSL_INTRINSIC(findLSB) \
41 SKSL_INTRINSIC(findMSB) \
42 SKSL_INTRINSIC(floatBitsToInt) \
43 SKSL_INTRINSIC(floatBitsToUint) \
44 SKSL_INTRINSIC(floor) \
45 SKSL_INTRINSIC(fma) \
46 SKSL_INTRINSIC(fract) \
47 SKSL_INTRINSIC(frexp) \
48 SKSL_INTRINSIC(fwidth) \
49 SKSL_INTRINSIC(greaterThanEqual) \
50 SKSL_INTRINSIC(greaterThan) \
51 SKSL_INTRINSIC(intBitsToFloat) \
52 SKSL_INTRINSIC(inversesqrt) \
53 SKSL_INTRINSIC(inverse) \
54 SKSL_INTRINSIC(isinf) \
55 SKSL_INTRINSIC(isnan) \
56 SKSL_INTRINSIC(ldexp) \
57 SKSL_INTRINSIC(length) \
58 SKSL_INTRINSIC(lessThanEqual) \
59 SKSL_INTRINSIC(lessThan) \
60 SKSL_INTRINSIC(log2) \
61 SKSL_INTRINSIC(log) \
62 SKSL_INTRINSIC(makeSampler2D) \
63 SKSL_INTRINSIC(matrixCompMult) \
64 SKSL_INTRINSIC(matrixInverse) \
65 SKSL_INTRINSIC(max) \
66 SKSL_INTRINSIC(min) \
67 SKSL_INTRINSIC(mix) \
68 SKSL_INTRINSIC(modf) \
69 SKSL_INTRINSIC(mod) \
70 SKSL_INTRINSIC(normalize) \
71 SKSL_INTRINSIC(notEqual) \
72 SKSL_INTRINSIC(not ) \
73 SKSL_INTRINSIC(outerProduct) \
74 SKSL_INTRINSIC(packDouble2x32) \
75 SKSL_INTRINSIC(packHalf2x16) \
76 SKSL_INTRINSIC(packSnorm2x16) \
77 SKSL_INTRINSIC(packSnorm4x8) \
78 SKSL_INTRINSIC(packUnorm2x16) \
79 SKSL_INTRINSIC(packUnorm4x8) \
80 SKSL_INTRINSIC(pow) \
81 SKSL_INTRINSIC(radians) \
82 SKSL_INTRINSIC(reflect) \
83 SKSL_INTRINSIC(refract) \
84 SKSL_INTRINSIC(roundEven) \
85 SKSL_INTRINSIC(round) \
86 SKSL_INTRINSIC(sample) \
87 SKSL_INTRINSIC(saturate) \
88 SKSL_INTRINSIC(sign) \
89 SKSL_INTRINSIC(sinh) \
90 SKSL_INTRINSIC(sin) \
91 SKSL_INTRINSIC(smoothstep) \
92 SKSL_INTRINSIC(sqrt) \
93 SKSL_INTRINSIC(step) \
94 SKSL_INTRINSIC(subpassLoad) \
95 SKSL_INTRINSIC(tanh) \
96 SKSL_INTRINSIC(tan) \
97 SKSL_INTRINSIC(transpose) \
98 SKSL_INTRINSIC(trunc) \
John Stiles1d1e66e2021-05-06 10:26:23 -040099 SKSL_INTRINSIC(uintBitsToFloat) \
John Stilesaaac4e42021-05-06 14:08:28 -0400100 SKSL_INTRINSIC(unpackDouble2x32) \
101 SKSL_INTRINSIC(unpackHalf2x16) \
102 SKSL_INTRINSIC(unpackSnorm2x16) \
103 SKSL_INTRINSIC(unpackSnorm4x8) \
104 SKSL_INTRINSIC(unpackUnorm2x16) \
105 SKSL_INTRINSIC(unpackUnorm4x8) \
John Stiles1d1e66e2021-05-06 10:26:23 -0400106 SKSL_INTRINSIC(unpremul)
John Stilesf96cb712021-05-05 22:17:04 -0400107
108#endif