Zen API

- Home
- Topics
- Types
- Files

All Classes Files Functions Variables Typedefs Friends Macros Modules Pages
kApiDef.h
Go to the documentation of this file.
1
10 #ifndef K_API_API_DEF_H
11 #define K_API_API_DEF_H
12
13 #include <kApi/kApiCfg.h>
14
15 #define kCall xkCall
16 #define kDlCall xkDlCall
17
18 #if defined(K_EMIT)
19 # define kFx(TYPE) kExportFx(TYPE)
20 # define kDx(TYPE) kExportDx(TYPE)
21 #else
22 # define kFx(TYPE) kImportFx(TYPE)
23 # define kDx(TYPE) kImportDx(TYPE)
24 #endif
25
26 #define kInlineFx(TYPE) xkInlineFx(TYPE)
27
28 typedef void (kCall* kFunction)();
29
38 typedef xk8u k8u;
39
41 #define k8U_MIN (0)
42 #define k8U_MAX (255U)
43 #define k8U_NULL (k8U_MAX)
44
54 typedef xk16u k16u;
55
57 #define k16U_MIN (0)
58 #define k16U_MAX (65535U)
59 #define k16U_NULL (k16U_MAX)
60
70 typedef xk32u k32u;
71
73 #define k32U_MIN (0)
74 #define k32U_MAX (4294967295U)
75 #define k32U_NULL (k32U_MAX)
76
86 typedef xk64u k64u;
87
89 #define k64U(CONST) xk64U(CONST)
90 #define k64U_MIN k64U(0)
91 #define k64U_MAX k64U(18446744073709551615)
92 #define k64U_NULL (k64U_MAX)
93
95 #define kINFINITE k64U_MAX
96
97
105 typedef xk8s k8s;
106
108 #define k8S_MAX (127)
109 #define k8S_MIN (-k8S_MAX -1)
110 #define k8S_NULL (k8S_MIN)
111
121 typedef xk16s k16s;
122
124 #define k16S_MAX (32767)
125 #define k16S_MIN (-k16S_MAX -1)
126 #define k16S_NULL (k16S_MIN)
127
137 typedef xk32s k32s;
138
140 #define k32S_MAX (2147483647)
141 #define k32S_MIN (-k32S_MAX -1)
142 #define k32S_NULL (k32S_MIN)
143
153 typedef xk64s k64s;
154
156 #define k64S(CONST) xk64S(CONST)
157 #define k64S_MAX k64S(9223372036854775807)
158 #define k64S_MIN (-k64S_MAX -1)
159 #define k64S_NULL (k64S_MIN)
160
170 typedef xk32f k32f;
171
173 #define k32F_MIN (1.175494351e-38F)
174 #define k32F_MAX (3.402823466e+38F)
175 #define k32F_NULL (-k32F_MAX)
176
186 typedef xk64f k64f;
187
189 #define k64F_MIN (2.2250738585072014e-308)
190 #define k64F_MAX (1.7976931348623157e+308)
191 #define k64F_NULL (-k64F_MAX)
192
202 kFx(k32s) k64f_IsNanOrInf(k64f value);
203
212 typedef xkByte kByte;
213
222 typedef xkSize kSize;
223
225 #define kSIZE_MAX xkSIZE_MAX
226 #define kSIZE_NULL kSIZE_MAX
227
239 kInlineFx(kSize) kSize_Align(kSize value, kSize to)
240 {
241 return ((value >> to) + !!(value & ((1 << to) - 1))) << to;
242 }
243
250 typedef xkSSize kSSize;
251
253 #define kSSIZE_MIN xkSSIZE_MIN
254 #define kSSIZE_MAX xkSSIZE_MAX
255 #define kSSIZE_NULL kSSIZE_MIN
256
265 typedef void* kPointer;
266
267 #define kNULL (0)
268
269
278 kInlineFx(void*) kPointer_ByteOffset(const void* pointer, kSSize offset)
279 {
280 return (kByte*)pointer + offset;
281 }
282
292 kInlineFx(void*) kPointer_ItemOffset(const void* pointer, kSSize itemIndex, kSize itemSize)
293 {
294 return kPointer_ByteOffset(pointer, itemIndex*itemSize);
295 }
296
305 kInlineFx(kSSize) kPointer_Diff(void* a, void* b)
306 {
307 return (kSSize)a - (kSSize)b;
308 }
309
318 #define kPointer_ReadAs(POINTER, TYPE) \
319 (*(TYPE*)(POINTER))
320
329 #define kPointer_WriteAs(POINTER, VALUE, TYPE) \
330 (*(TYPE*)(POINTER) = (TYPE)(VALUE))
331
339 #define kIsNull(POINTER) \
340 ((POINTER) == kNULL)
341
350 typedef k32s kBool;
351
353 #define kFALSE (0)
354 #define kTRUE (1)
355
365 typedef xkChar kChar;
366
374 kInlineFx(kChar) kChar_ToLower(kChar ch)
375 {
376 return (ch >= 'A' && ch <= 'Z') ? (ch - 'A' + 'a') : ch;
377 }
378
386 kInlineFx(kChar) kChar_ToUpper(kChar ch)
387 {
388 return (ch >= 'a' && ch <= 'z') ? (ch - 'a' + 'A') : ch;
389 }
390
398 kInlineFx(kBool) kChar_IsSpace(kChar ch)
399 {
400 return ch == ' ';
401 }
402
410 kInlineFx(kBool) kChar_IsLetter(kChar ch)
411 {
412 return ((ch >= 'a') && (ch <= 'z') ) || ((ch >= 'A') && (ch <= 'Z'));
413 }
414
422 kInlineFx(kBool) kChar_IsDigit(kChar ch)
423 {
424 return ch >= '0' && ch <= '9';
425 }
426
435 typedef kChar kText16[16];
436
445 typedef kChar kText32[32];
446
455 typedef kChar kText64[64];
456
465 typedef kChar kText128[128];
466
475 typedef kChar kText256[256];
476
485 typedef k32s kStatus;
486
488 #define kERROR_STATE (-1000)
489 #define kERROR_NOT_FOUND (-999)
490 #define kERROR_COMMAND (-998)
491 #define kERROR_PARAMETER (-997)
492 #define kERROR_UNIMPLEMENTED (-996)
493 #define kERROR_MEMORY (-994)
494 #define kERROR_TIMEOUT (-993)
495 #define kERROR_INCOMPLETE (-992)
496 #define kERROR_STREAM (-991)
497 #define kERROR_CLOSED (-990)
498 #define kERROR_VERSION (-989)
499 #define kERROR_ABORT (-988)
500 #define kERROR_ALREADY_EXISTS (-987)
501 #define kERROR_NETWORK (-986)
502 #define kERROR_HEAP (-985)
503 #define kERROR_FORMAT (-984)
504 #define kERROR_READ_ONLY (-983)
505 #define kERROR_WRITE_ONLY (-982)
506 #define kERROR_BUSY (-981)
507 #define kERROR_CONFLICT (-980)
508 #define kERROR_OS (-979)
509 #define kERROR_DEVICE (-978)
510 #define kERROR_FULL (-977)
511 #define kERROR_IN_PROGRESS (-976)
512 #define kERROR (0)
513 #define kOK (1)
514
525 kFx(const kChar*) kStatus_Name(kStatus status);
526
534 kInlineFx(kBool) kIsError(kStatus status)
535 {
536 return status != kOK;
537 }
538
546 kInlineFx(kBool) kSuccess(kStatus status)
547 {
548 return status == kOK;
549 }
550
559 #define kCheck(EXPRESSION) \
560 xkCheck(EXPRESSION)
561
571 #define kCheckTrue(EXPRESSION, STATUS) \
572 xkCheckTrue(EXPRESSION, STATUS)
573
582 #define kCheckArgs(EXPRESSION) \
583 xkCheckArgs(EXPRESSION)
584
593 #define kCheckState(EXPRESSION) \
594 xkCheckState(EXPRESSION)
595
601 #define kTry \
602 xkTry
603
610 #define kThrow(EXPRESSION) \
611 xkThrow(EXPRESSION)
612
622 #define kTest(EXPRESSION) \
623 xkTest(EXPRESSION)
624
635 #define kTestTrue(EXPRESSION, STATUS) \
636 xkTestTrue(EXPRESSION, STATUS)
637
647 #define kTestArgs(EXPRESSION) \
648 xkTestArgs(EXPRESSION)
649
659 #define kTestState(EXPRESSION) \
660 xkTestState(EXPRESSION)
661
668 #define kCatch(STATUS_POINTER) \
669 xkCatch(STATUS_POINTER)
670
679 #define kEndCatch(STATUS) \
680 xkEndCatch(STATUS)
681
687 #define kFinally \
688 xkFinally
689
698 #define kEndFinally() \
699 xkEndFinally()
700
707 #define kCatchEx(STATUS_POINTER) \
708 xkCatchEx(STATUS_POINTER)
709
720 #define kEndCatchEx(STATUS) \
721 xkEndCatchEx(STATUS)
722
728 #define kFinallyEx \
729 xkFinallyEx
730
739 #define kEndFinallyEx() \
740 xkEndFinallyEx()
741
749 #define kAssert(EXPRESSION) \
750 xkAssert(EXPRESSION)
751
762 #define kAssertType(OBJECT, SYMBOL) \
763 xkAssertType(OBJECT, SYMBOL)
764
772 #define kTrace(TAG) \
773 xkTrace(TAG)
774
783 typedef k32u kVersion;
784
785 #define kVERSION_NULL (k32U_NULL) // kVersion invalid value.
786
797 kInlineFx(kVersion) kVersion_Create(k32u major, k32u minor, k32u release, k32u build)
798 {
799 return (major & 0xFF) << 24 |
800 (minor & 0xFF) << 16 |
801 (release & 0xFF) << 8 |
802 (build & 0xFF);
803 }
804
815 #define kVersion_Stringify_(MAJOR, MINOR, RELEASE, BUILD) \
816 xkStringize(MAJOR) "." xkStringize(MINOR) "." xkStringize(RELEASE) "." xkStringize(BUILD)
817
826 kFx(kStatus) kVersion_Parse(kVersion* version, const kChar* buffer);
827
837 kFx(kStatus) kVersion_Format(kVersion version, kChar* buffer, kSize capacity);
838
850 kInlineFx(k32s) kVersion_Compare(kVersion version1, kVersion version2)
851 {
852 return version1 - version2;
853 }
854
862 kInlineFx(k8u) kVersion_Major(kVersion version)
863 {
864 return (version >> 24) & 0xFF;
865 }
866
874 kInlineFx(k8u) kVersion_Minor(kVersion version)
875 {
876 return (version >> 16) & 0xFF;
877 }
878
886 kInlineFx(k8u) kVersion_Release(kVersion version)
887 {
888 return (version >> 8) & 0xFF;
889 }
890
898 kInlineFx(k8u) kVersion_Build(kVersion version)
899 {
900 return (version) & 0xFF;
901 }
902
909 typedef k32s kEndianness;
910
912 #define kENDIANNESS_LITTLE (1)
913 #define kENDIANNESS_BIG (2)
914
921 kInlineFx(kEndianness) kEndianness_Host()
922 {
923 return K_ENDIANNESS;
924 }
925
932 kInlineFx(kBool) kEndianness_ShouldReverse(kEndianness endianness)
933 {
934 return endianness != kEndianness_Host();
935 }
936
951 kFx(kStatus) k8u_Format(k8u value, kChar* buffer, kSize capacity);
952
961 kFx(kStatus) k8u_Parse(k8u* value, const kChar* str);
962
977 kFx(kStatus) k8s_Format(k8s value, kChar* buffer, kSize capacity);
978
987 kFx(kStatus) k8s_Parse(k8s* value, const kChar* str);
988
1003 kFx(kStatus) k16u_Format(k16u value, kChar* buffer, kSize capacity);
1004
1013 kFx(kStatus) k16u_Parse(k16u* value, const kChar* str);
1014
1029 kFx(kStatus) k16s_Format(k16s value, kChar* buffer, kSize capacity);
1030
1039 kFx(kStatus) k16s_Parse(k16s* value, const kChar* str);
1040
1055 kFx(kStatus) k32u_Format(k32u value, kChar* buffer, kSize capacity);
1056
1065 kFx(kStatus) k32u_Parse(k32u* value, const kChar* str);
1066
1081 kFx(kStatus) k32s_Format(k32s value, kChar* buffer, kSize capacity);
1082
1091 kFx(kStatus) k32s_Parse(k32s* value, const kChar* str);
1092
1107 kFx(kStatus) k64u_Format(k64u value, kChar* buffer, kSize capacity);
1108
1117 kFx(kStatus) k64u_Parse(k64u* value, const kChar* str);
1118
1133 kFx(kStatus) k64s_Format(k64s value, kChar* buffer, kSize capacity);
1134
1143 kFx(kStatus) k64s_Parse(k64s* value, const kChar* str);
1144
1159 kFx(kStatus) kBool_Format(kBool value, kChar* buffer, kSize capacity);
1160
1169 kFx(kStatus) kBool_Parse(kBool* value, const kChar* str);
1170
1185 kFx(kStatus) kSize_Format(kSize value, kChar* buffer, kSize capacity);
1186
1195 kFx(kStatus) kSize_Parse(kSize* value, const kChar* str);
1196
1211 kFx(kStatus) kSSize_Format(kSSize value, kChar* buffer, kSize capacity);
1212
1221 kFx(kStatus) kSSize_Parse(kSSize* value, const kChar* str);
1222
1237 kFx(kStatus) k32f_Format(k32f value, kChar* buffer, kSize capacity);
1238
1247 kFx(kStatus) k32f_Parse(k32f* value, const kChar* str);
1248
1263 kFx(kStatus) k64f_Format(k64f value, kChar* buffer, kSize capacity);
1264
1273 kFx(kStatus) k64f_Parse(k64f* value, const kChar* str);
1274
1283 typedef struct kPoint16s
1284 {
1285 k16s x;
1286 k16s y;
1287 } kPoint16s;
1288
1297 typedef struct kPoint32s
1298 {
1299 k32s x;
1300 k32s y;
1301 } kPoint32s;
1302
1311 typedef struct kPoint32f
1312 {
1313 k32f x;
1314 k32f y;
1315 } kPoint32f;
1316
1325 typedef struct kPoint64f
1326 {
1327 k64f x;
1328 k64f y;
1329 } kPoint64f;
1330
1340 #define kPoint_Init_(POINT, X, Y) xkPoint_Init_(POINT, X, Y)
1341
1350 typedef struct kPoint3d16s
1351 {
1352 k16s x;
1353 k16s y;
1354 k16s z;
1355 } kPoint3d16s;
1356
1365 typedef struct kPoint3d32s
1366 {
1367 k32s x;
1368 k32s y;
1369 k32s z;
1370 } kPoint3d32s;
1371
1380 typedef struct kPoint3d32f
1381 {
1382 k32f x;
1383 k32f y;
1384 k32f z;
1385 } kPoint3d32f;
1386
1395 typedef struct kPoint3d64f
1396 {
1397 k64f x;
1398 k64f y;
1399 k64f z;
1400 } kPoint3d64f;
1401
1412 #define kPoint3d_Init_(POINT, X, Y, Z) xkPoint3d_Init_(POINT, X, Y, Z)
1413
1422 typedef struct kRect16s
1423 {
1424 k16s x;
1425 k16s y;
1426 k16s width;
1427 k16s height;
1428 } kRect16s;
1429
1438 typedef struct kRect32s
1439 {
1440 k32s x;
1441 k32s y;
1442 k32s width;
1443 k32s height;
1444 } kRect32s;
1445
1454 typedef struct kRect32f
1455 {
1456 k32f x;
1457 k32f y;
1458 k32f width;
1459 k32f height;
1460 } kRect32f;
1461
1470 typedef struct kRect64f
1471 {
1472 k64f x;
1473 k64f y;
1474 k64f width;
1475 k64f height;
1476 } kRect64f;
1477
1489 #define kRect_Init_(RECT, X, Y, W, H) \
1490 xkRect_Init_(RECT, X, Y, W, H)
1491
1500 typedef struct kRect3d64f
1501 {
1502 k64f x;
1503 k64f y;
1504 k64f z;
1505 k64f width;
1506 k64f height;
1507 k64f depth;
1508 } kRect3d64f;
1509
1521 #define kRect3d_Init_(RECT, X, Y, Z, W, H, D) \
1522 xkRect3d_Init_(RECT, X, Y, Z, W, H, D)
1523
1532 typedef struct kRotatedRect32s
1533 {
1534 k32s xc;
1535 k32s yc;
1536 k32s width;
1537 k32s height;
1538 k32s angle;
1539 } kRotatedRect32s;
1540
1549 typedef struct kRotatedRect32f
1550 {
1551 k32f xc;
1552 k32f yc;
1553 k32f width;
1554 k32f height;
1555 k32f angle;
1556 } kRotatedRect32f;
1557
1570 #define kRotatedRect_Init_(RECT, XC, YC, W, H, A) \
1571 xkRotatedRect_Init_(RECT, XC, YC, W, H, A)
1572
1581 typedef k32s kPixelFormat;
1582
1584 #define kPIXEL_FORMAT_NULL (0)
1585 #define kPIXEL_FORMAT_8BPP_GREYSCALE (1)
1586 #define kPIXEL_FORMAT_8BPP_CFA (2)
1587 #define kPIXEL_FORMAT_8BPC_BGRX (3)
1588 #define kPIXEL_FORMAT_1BPP_GREYSCALE (4)
1589
1599 typedef k32s kCfa;
1600
1602 #define kCFA_NONE (0)
1603 #define kCFA_BAYER_BGGR (1)
1604 #define kCFA_BAYER_GBRG (2)
1605 #define kCFA_BAYER_RGGB (3)
1606 #define kCFA_BAYER_GRBG (4)
1607
1617 typedef struct kRgb
1618 {
1619 k8u b;
1620 k8u g;
1621 k8u r;
1622 k8u x;
1623 } kRgb;
1624
1634 #define kRgb_Init_(RGB, R, G, B) \
1635 xkRgb_Init_(RGB, R, G, B)
1636
1645 typedef struct kArgb
1646 {
1647 k8u b;
1648 k8u g;
1649 k8u r;
1650 k8u a;
1651 } kArgb;
1652
1663 #define kArgb_Init_(ARGB, A, R, G, B) \
1664 xkArgb_Init_(ARGB, A, R, G, B)
1665
1672 typedef k32s kComparison;
1673
1674 #define kCOMPARISON_EQ (0)
1675 #define kCOMPARISON_NEQ (1)
1676 #define kCOMPARISON_LT (2)
1677 #define kCOMPARISON_LTE (3)
1678 #define kCOMPARISON_GT (4)
1679 #define kCOMPARISON_GTE (5)
1680
1681
1688 typedef kBool (kCall* kEqualsFx)(const void* item1, const void* item2);
1689
1696 typedef kSize (kCall* kHashFx)(const void* item);
1697
1706 typedef kStatus (kCall* kCallbackFx)(kPointer receiver, kPointer sender, void* args);
1707
1714 typedef struct kCallback
1715 {
1716 kCallbackFx function;
1717 kPointer receiver;
1718 } kCallback;
1719
1726 typedef k32s kFileMode;
1727
1729 #define kFILE_MODE_READ (0x1)
1730 #define kFILE_MODE_WRITE (0x2)
1731 #define kFILE_MODE_UPDATE (0x4)
1732
1740 typedef k32s kSeekOrigin;
1741
1742 #define kSEEK_ORIGIN_BEGIN (0)
1743 #define kSEEK_ORIGIN_CURRENT (1)
1744 #define kSEEK_ORIGIN_END (2)
1745
1746
1754 #define kCountOf(CARRAY) \
1755 (sizeof(CARRAY)/sizeof(CARRAY[0]))
1756
1757
1767 #define kCast(TYPE, ITEM) \
1768 ((TYPE)(ITEM))
1769
1779 #define kMin_(A, B) \
1780 (((A) < (B)) ? (A) : (B))
1781
1782
1792 #define kMax_(A, B) \
1793 (((A) > (B)) ? (A) : (B))
1794
1805 #define kClamp_(V, VMIN, VMAX) \
1806 (kMin_(kMax_((V), (VMIN)), (VMAX)))
1807
1816 #define kAbs_(A) \
1817 (((A) >= 0) ? (A) : -(A))
1818
1819
1829 #define kDivideFloorInt_(A, B) \
1830 (((A) >= 0) ? (A) / (B) : ((A) - (B) + 1) / (B))
1831
1841 #define kDivideCeilInt_(A, B) \
1842 (((A) >= 0) ? ((A) + (B) - 1) / (B) : (A) / (B))
1843
1851 #define kDivideFloorUInt_(A, B) \
1852 ((A) / (B))
1853
1863 #define kDivideCeilUInt_(A, B) \
1864 (((A) + (B) - 1) / (B))
1865
1871 #define kZero(VALUE) \
1872 memset(&VALUE, 0, sizeof(VALUE))
1873
1888 kInlineFx(void) kItemCopy(void* dest, const void* src, kSize size)
1889 {
1890 memcpy(dest, src, size);
1891 }
1892
1906 kInlineFx(void) kItemZero(void* dest, kSize size)
1907 {
1908 memset(dest, 0, size);
1909 }
1910
1911 /*
1912 * Forward declarations
1913 */
1914
1915 typedef void* kObject;
1916 typedef kObject kType;
1917
1919 #define kTypeName kText64
1920
1928 typedef k32u kTypeFlags;
1929
1931 #define kTYPE_FLAGS_CLASS (0x01)
1932 #define kTYPE_FLAGS_INTERFACE (0x02)
1933 #define kTYPE_FLAGS_VALUE (0x04)
1934 #define kTYPE_FLAGS_ENUM (0x08)
1935 #define kTYPE_FLAGS_ABSTRACT (0x20)
1936 #define kTYPE_FLAGS_ARRAY_VALUE (0x40)
1937 #define kTYPE_FLAGS_PRIMITIVE (0x80)
1938
1946 typedef kPointer kTypeVersion;
1947
1953 typedef struct kMethodInfo
1954 {
1955 kTypeName methodName;
1956 kTypeName functionName;
1957 kFunction function;
1958 } kMethodInfo;
1959
1965 typedef struct kFieldInfo
1966 {
1967 kTypeName name;
1968 kType type;
1969 kSize offset;
1970 kSize count;
1971 } kFieldInfo;
1972
1978 typedef struct kEnumeratorInfo
1979 {
1980 k32s value;
1981 kTypeName name;
1982 kTypeName displayName;
1983 } kEnumeratorInfo;
1984
1985
2011 #define kTypeOf(SYMBOL) \
2012 xkTypeOf(SYMBOL)
2013
2039 #define kAssemblyOf(SYMBOL) \
2040 xkAssemblyOf(SYMBOL)
2041
2050 #define kStaticOf(SYMBOL) \
2051 xkStaticOf(SYMBOL)
2052
2059 #define kStaticInitialized(SYMBOL) \
2060 xkStaticInitialized(SYMBOL)
2061
2069 #define kDeprecate(SYMBOL) \
2070 xkDeprecate(#SYMBOL)
2071
2080 #define kWarn(MESSAGE) \
2081 xkWarn(MESSAGE)
2082
2083 /*
2084 *
2085 * Type Declaration/Definition Macros, Generation 1.
2086 *
2087 * These type declaration/definition macros continue to be supported. However, consider using the Generation 2
2088 * macros (defined below) in new code.
2089 *
2090 */
2091
2099 #define kDeclareAssembly(PREFIX, SYMBOL) \
2100 xkDeclareAssembly(PREFIX, SYMBOL)
2101
2111 #define kBeginAssembly(PREFIX, SYMBOL, VERSION, PLATFORM_VERSION) \
2112 xkBeginAssembly(PREFIX, SYMBOL, VERSION, PLATFORM_VERSION)
2113
2119 #define kEndAssembly() \
2120 xkEndAssembly()
2121
2130 #define kDeclareValue(PREFIX, SYMBOL, BASE) \
2131 xkDeclareValue(PREFIX, SYMBOL, BASE)
2132
2141 #define kBeginValue(PREFIX, SYMBOL, BASE) \
2142 xkBeginValue(PREFIX, SYMBOL, BASE)
2143
2149 #define kEndValue() \
2150 xkEndValue()
2151
2160 #define kDeclareEnum(PREFIX, SYMBOL, BASE) \
2161 xkDeclareEnum(PREFIX, SYMBOL, BASE)
2162
2171 #define kBeginEnum(PREFIX, SYMBOL, BASE) \
2172 xkBeginEnum(PREFIX, SYMBOL, BASE)
2173
2179 #define kEndEnum() \
2180 xkEndEnum()
2181
2190 #define kDeclareArrayValue(PREFIX, SYMBOL, BASE) \
2191 xkDeclareArrayValue(PREFIX, SYMBOL, BASE)
2192
2202 #define kBeginArrayValue(PREFIX, SYMBOL, TYPE, BASE) \
2203 xkBeginArrayValue(PREFIX, SYMBOL, TYPE, BASE)
2204
2210 #define kEndArrayValue() \
2211 xkEndArrayValue()
2212
2221 #define kDeclareInterface(PREFIX, SYMBOL, BASE) \
2222 xkDeclareInterface(PREFIX, SYMBOL, BASE)
2223
2232 #define kBeginInterface(PREFIX, SYMBOL, BASE) \
2233 xkBeginInterface(PREFIX, SYMBOL, BASE)
2234
2240 #define kEndInterface() \
2241 xkEndInterface()
2242
2251 #define kDeclareFullClass(PREFIX, SYMBOL, BASE) \
2252 xkDeclareFullClass(PREFIX, SYMBOL, BASE)
2253
2262 #define kBeginFullClass(PREFIX, SYMBOL, BASE) \
2263 xkBeginFullClass(PREFIX, SYMBOL, BASE)
2264
2270 #define kEndFullClass() \
2271 xkEndFullClass()
2272
2281 #define kDeclareVirtualClass(PREFIX, SYMBOL, BASE) \
2282 xkDeclareVirtualClass(PREFIX, SYMBOL, BASE)
2283
2292 #define kBeginVirtualClass(PREFIX, SYMBOL, BASE) \
2293 xkBeginVirtualClass(PREFIX, SYMBOL, BASE)
2294
2300 #define kEndVirtualClass() \
2301 xkEndVirtualClass()
2302
2310 #define kDeclareStaticClass(PREFIX, SYMBOL) \
2311 xkDeclareStaticClass(PREFIX, SYMBOL)
2312
2320 #define kBeginStaticClass(PREFIX, SYMBOL) \
2321 xkBeginStaticClass(PREFIX, SYMBOL)
2322
2328 #define kEndStaticClass() \
2329 xkEndStaticClass()
2330
2339 #define kDeclareClass(PREFIX, SYMBOL, BASE) \
2340 xkDeclareClass(PREFIX, SYMBOL, BASE)
2341
2350 #define kBeginClass(PREFIX, SYMBOL, BASE) \
2351 xkBeginClass(PREFIX, SYMBOL, BASE)
2352
2358 #define kEndClass() \
2359 xkEndClass()
2360
2361 /*
2362 *
2363 * Type Declaration/Definition Macros, Generation 2.
2364 *
2365 * These macros are used to declare and define elements of the type system, such
2366 * as assemblies, classes and values. These macros supersede the Generation 1 macros,
2367 * defined above.
2368 *
2369 */
2370
2378 #define kDeclareAssemblyEx(PREFIX, SYMBOL) \
2379 xkDeclareAssemblyEx(PREFIX, SYMBOL)
2380
2390 #define kBeginAssemblyEx(PREFIX, SYMBOL, VERSION, PLATFORM_VERSION) \
2391 xkBeginAssemblyEx(PREFIX, SYMBOL, VERSION, PLATFORM_VERSION)
2392
2398 #define kEndAssemblyEx() \
2399 xkEndAssemblyEx()
2400
2409 #define kDeclareValueEx(PREFIX, SYMBOL, BASE) \
2410 xkDeclareValueEx(PREFIX, SYMBOL, BASE)
2411
2419 #define kBeginValueEx(PREFIX, SYMBOL) \
2420 xkBeginValueEx(PREFIX, SYMBOL)
2421
2427 #define kEndValueEx() \
2428 xkEndValueEx()
2429
2438 #define kDeclareEnumEx(PREFIX, SYMBOL, BASE) \
2439 xkDeclareEnumEx(PREFIX, SYMBOL, BASE)
2440
2448 #define kBeginEnumEx(PREFIX, SYMBOL) \
2449 xkBeginEnumEx(PREFIX, SYMBOL)
2450
2456 #define kEndEnumEx() \
2457 xkEndEnumEx()
2458
2467 #define kDeclareArrayValueEx(PREFIX, SYMBOL, BASE) \
2468 xkDeclareArrayValueEx(PREFIX, SYMBOL, BASE)
2469
2478 #define kBeginArrayValueEx(PREFIX, SYMBOL, TYPE) \
2479 xkBeginArrayValueEx(PREFIX, SYMBOL, TYPE)
2480
2486 #define kEndArrayValueEx() \
2487 xkEndArrayValueEx()
2488
2497 #define kDeclareInterfaceEx(PREFIX, SYMBOL, BASE) \
2498 xkDeclareInterfaceEx(PREFIX, SYMBOL, BASE)
2499
2507 #define kBeginInterfaceEx(PREFIX, SYMBOL) \
2508 xkBeginInterfaceEx(PREFIX, SYMBOL)
2509
2515 #define kEndInterfaceEx() \
2516 xkEndInterfaceEx()
2517
2526 #define kDeclareFullClassEx(PREFIX, SYMBOL, BASE) \
2527 xkDeclareFullClassEx(PREFIX, SYMBOL, BASE)
2528
2536 #define kBeginFullClassEx(PREFIX, SYMBOL) \
2537 xkBeginFullClassEx(PREFIX, SYMBOL)
2538
2544 #define kEndFullClassEx() \
2545 xkEndFullClassEx()
2546
2555 #define kDeclareVirtualClassEx(PREFIX, SYMBOL, BASE) \
2556 xkDeclareVirtualClassEx(PREFIX, SYMBOL, BASE)
2557
2565 #define kBeginVirtualClassEx(PREFIX, SYMBOL) \
2566 xkBeginVirtualClassEx(PREFIX, SYMBOL)
2567
2573 #define kEndVirtualClassEx() \
2574 xkEndVirtualClassEx()
2575
2583 #define kDeclareStaticClassEx(PREFIX, SYMBOL) \
2584 xkDeclareStaticClassEx(PREFIX, SYMBOL)
2585
2593 #define kBeginStaticClassEx(PREFIX, SYMBOL) \
2594 xkBeginStaticClassEx(PREFIX, SYMBOL)
2595
2601 #define kEndStaticClassEx() \
2602 xkEndStaticClassEx()
2603
2612 #define kDeclareClassEx(PREFIX, SYMBOL, BASE) \
2613 xkDeclareClassEx(PREFIX, SYMBOL, BASE)
2614
2622 #define kBeginClassEx(PREFIX, SYMBOL) \
2623 xkBeginClassEx(PREFIX, SYMBOL)
2624
2630 #define kEndClassEx() \
2631 xkEndClassEx()
2632
2633 /*
2634 *
2635 * Type Implementation Macros
2636 *
2637 * These macros are used to provide type-specific details. They are typically used between
2638 * type definition begin/end macros (e.g., kBeginClass/kEndClass).
2639 *
2640 */
2641
2648 #define kAddDependency(SYMBOL) \
2649 xkAddDependency(SYMBOL)
2650
2657 #define kAddType(SYMBOL) \
2658 xkAddType(SYMBOL)
2659
2670 #define kAddPriority(SYMBOL) \
2671 xkAddPriority(SYMBOL)
2672
2680 #define kAddInterface(SYMBOL, IFACE) \
2681 xkAddInterface(SYMBOL, IFACE)
2682
2690 #define kAddMethod(SYMBOL, METHOD) \
2691 xkAddMethod(SYMBOL, METHOD)
2692
2701 #define kAddVMethod(IN_TYPE, FROM_TYPE, METHOD) \
2702 xkAddVMethod(IN_TYPE, FROM_TYPE, METHOD)
2703
2714 #define kAddPrivateVMethod(IN_TYPE, FROM_TYPE, METHOD) \
2715 xkAddPrivateVMethod(IN_TYPE, FROM_TYPE, METHOD)
2716
2726 #define kAddIVMethod(IN_TYPE, FROM_IFACE, IMETHOD, CMETHOD) \
2727 xkAddIVMethod(IN_TYPE, FROM_IFACE, IMETHOD, CMETHOD)
2728
2740 #define kAddPrivateIVMethod(IN_TYPE, FROM_IFACE, IMETHOD, CMETHOD) \
2741 xkAddPrivateIVMethod(IN_TYPE, FROM_IFACE, IMETHOD, CMETHOD)
2742
2751 #define kAddField(VALUE, FIELD_TYPE, FIELD) \
2752 xkAddField(VALUE, FIELD_TYPE, FIELD)
2753
2761 #define kAddEnumerator \
2762 xkAddEnumerator
2763
2775 #define kAddVersion(TYPE, FORMAT, FORMAT_VER, GUID, WRITE_METHOD, READ_METHOD) \
2776 xkAddVersion(TYPE, FORMAT, FORMAT_VER, GUID, WRITE_METHOD, READ_METHOD)
2777
2791 #define kAddPrivateVersion(TYPE, FORMAT, FORMAT_VER, GUID, WRITE_METHOD, READ_METHOD) \
2792 xkAddPrivateVersion(TYPE, FORMAT, FORMAT_VER, GUID, WRITE_METHOD, READ_METHOD)
2793
2807 #define kAddAbstractVersion(TYPE, FORMAT, FORMAT_VER, GUID) \
2808 xkAddAbstractVersion(TYPE, FORMAT, FORMAT_VER, GUID)
2809
2817 #define kAddFlags(TYPE, FLAGS) \
2818 xkAddFlags(TYPE, FLAGS)
2819
2841 #define kDefineDebugHints() \
2842 xkDefineDebugHints()
2843
2844 /*
2845 *
2846 * Method Implementation Macros
2847 *
2848 * These macros are used in the implementation of class methods.
2849 *
2850 */
2851
2858 #define kObj(TypeName_T, T_object) \
2859 TypeName_T##Class* obj K_ATTRIBUTE_UNUSED = xx##TypeName_T##_Cast(T_object, __FILE__, __LINE__)
2860
2870 #define kObjR(TypeName_T, T_object) \
2871 TypeName_T##Class* obj K_ATTRIBUTE_UNUSED = x##TypeName_T##_CastRaw(T_object)
2872
2884 #define kObjN(TypeName_T, VarName_obj, T_object) \
2885 TypeName_T##Class* VarName_obj = xx##TypeName_T##_Cast(T_object, __FILE__, __LINE__)
2886
2897 #define kObjNR(TypeName_T, VarName_obj, T_object) \
2898 TypeName_T##Class* VarName_obj = x##TypeName_T##_CastRaw(T_object)
2899
2905 #define kStaticObj(TypeName_T) \
2906 TypeName_T##Static* sobj = kStaticOf(TypeName_T)
2907
2919 #define kInitFields(TYPE, OBJECT) \
2920 xkInitFields(TYPE, OBJECT)
2921
2932 #define kCastClass_(TYPE, OBJECT) \
2933 xkCastClass_(TYPE, OBJECT)
2934
2945 #define kCastVTable_(TYPE, OBJECT) \
2946 xkCastVTable_(TYPE, OBJECT)
2947
2958 #define kCastIVTable_(IFACE, OBJECT) \
2959 xkCastIVTable_(IFACE, OBJECT)
2960
2966 #define kDebugBreak() \
2967 xkDebugBreak()
2968
2969 #include <kApi/kApiDef.x.h>
2970
2971 #endif
kPoint32f::y
k32f y
Y-coordinate value.
Definition: kApiDef.h:1314
k32s::k32s_Parse
kStatus k32s_Parse(k32s *value, const kChar *str)
Converts string to k32s value.
kRect3d64f::height
k64f height
Height of the rectangular cuboid.
Definition: kApiDef.h:1506
kText64
Represents a 64-unit, null-terminated, kChar sequence.
k32u
Represents a 32-bit unsigned integer.
kRect32s::y
k32s y
Y-coordinate of the origin.
Definition: kApiDef.h:1441
kChar::kChar_IsSpace
kBool kChar_IsSpace(kChar ch)
Checks whether ASCII character is a some kind of white space character type.
Definition: kApiDef.h:398
kBool::kBool_Parse
kStatus kBool_Parse(kBool *value, const kChar *str)
Converts string to kBool value.
kRect64f::height
k64f height
Height of the rectangle.
Definition: kApiDef.h:1475
kRect32f::x
k32f x
X-coordinate of the origin.
Definition: kApiDef.h:1456
kRect32s
Rectangle structure with 32-bit signed integer fields.
Definition: kApiDef.h:1438
kPoint3d32f
3D point structure with 32-bit floating-point fields.
Definition: kApiDef.h:1380
kRect64f::x
k64f x
X-coordinate of the origin.
Definition: kApiDef.h:1472
kRotatedRect32s::width
k32s width
Width of the rectangle.
Definition: kApiDef.h:1536
kRgb::b
k8u b
Blue component value.
Definition: kApiDef.h:1619
kPoint3d32s::y
k32s y
Y-coordinate value.
Definition: kApiDef.h:1368
kRect16s::width
k16s width
Width of the rectangle.
Definition: kApiDef.h:1426
kArgb
32-bit color pixel structure (B/G/R/A).
Definition: kApiDef.h:1645
kRect16s::y
k16s y
Y-coordinate of the origin.
Definition: kApiDef.h:1425
kPoint16s
2D point structure with 16-bit signed integer fields.
Definition: kApiDef.h:1283
kChar::kChar_ToLower
kChar kChar_ToLower(kChar ch)
Convert ASCII character to lower case.
Definition: kApiDef.h:374
k64u
Represents a 64-bit unsigned integer.
kApiCfg.h
Architecture/compiler-specific definitions.
kSuccess
kBool kSuccess(kStatus status)
Returns kTRUE if the given expression value is kOK.
Definition: kApiDef.h:546
kText256
Represents a 256-unit, null-terminated, kChar sequence.
kMethodInfo::methodName
kTypeName methodName
Method name (e.g. "Clone").
Definition: kApiDef.h:1955
kCallback::receiver
kPointer receiver
Callback receiver context pointer.
Definition: kApiDef.h:1717
kEnumeratorInfo::name
kTypeName name
Enumerator name (e.g. "kPIXEL_FORMAT_8BPP_GREYSCALE").
Definition: kApiDef.h:1981
kRotatedRect32f
Rotated rectangle structure with 32-bit floating-point fields.
Definition: kApiDef.h:1549
kRect64f::y
k64f y
Y-coordinate of the origin.
Definition: kApiDef.h:1473
kPoint3d32s::z
k32s z
Z-coordinate value.
Definition: kApiDef.h:1369
kPointer
Represents a void pointer.
kRgb
32-bit color pixel structure (B/G/R/X).
Definition: kApiDef.h:1617
kSize::kSize_Parse
kStatus kSize_Parse(kSize *value, const kChar *str)
Converts string to kSize value.
kPoint32f::x
k32f x
X-coordinate value.
Definition: kApiDef.h:1313
kSSize::kSSize_Parse
kStatus kSSize_Parse(kSSize *value, const kChar *str)
Converts string to kSSize value.
kChar::kChar_IsLetter
kBool kChar_IsLetter(kChar ch)
Checks whether ASCII character is a letter.
Definition: kApiDef.h:410
kPoint3d16s::z
k16s z
Z-coordinate value.
Definition: kApiDef.h:1354
k32f::k32f_Format
kStatus k32f_Format(k32f value, kChar *buffer, kSize capacity)
Converts k32f value to string.
k16u
Represents a 16-bit unsigned integer.
k32u::k32u_Format
kStatus k32u_Format(k32u value, kChar *buffer, kSize capacity)
Converts k32u value to string.
kRotatedRect32s::xc
k32s xc
X-coordinate of the rectangle center.
Definition: kApiDef.h:1534
kRotatedRect32s
Rotated rectangle structure with 32-bit signed integer fields.
Definition: kApiDef.h:1532
kRotatedRect32f::yc
k32f yc
Y-coordinate of the rectangle center.
Definition: kApiDef.h:1552
kBool::kBool_Format
kStatus kBool_Format(kBool value, kChar *buffer, kSize capacity)
Converts kBool value to string.
kSize
Represents an unsigned integer that can store a pointer address.
kRotatedRect32s::angle
k32s angle
Rotation angle of the rectangle.
Definition: kApiDef.h:1538
kPointer::kPointer_ItemOffset
void * kPointer_ItemOffset(const void *pointer, kSSize itemIndex, kSize itemSize)
Gets a pointer to the Nth element of an array.
Definition: kApiDef.h:292
kEnumeratorInfo::displayName
kTypeName displayName
Formatted display name (e.g. "8bpp Greyscale");.
Definition: kApiDef.h:1982
kFieldInfo
Represents type field information.
Definition: kApiDef.h:1965
kRect3d64f::width
k64f width
Width of the rectangular cuboid.
Definition: kApiDef.h:1505
k8u
Represents an 8-bit unsigned integer.
kRect3d64f::x
k64f x
X-coordinate of the origin.
Definition: kApiDef.h:1502
kRect3d64f::depth
k64f depth
Depth of the rectangular cuboid.
Definition: kApiDef.h:1507
kInlineFx
#define kInlineFx(TYPE)
Inline method declaration helper.
Definition: kApiDef.h:26
kPoint3d64f::y
k64f y
Y-coordinate value.
Definition: kApiDef.h:1398
kPoint3d64f::x
k64f x
X-coordinate value.
Definition: kApiDef.h:1397
kEnumeratorInfo
Represents enumerator information.
Definition: kApiDef.h:1978
kChar
Represents a single unit (byte) in a UTF-8 character.
kByte
Represents a byte on the current platform.
k64s::k64s_Format
kStatus k64s_Format(k64s value, kChar *buffer, kSize capacity)
Converts k64s value to string.
k16u::k16u_Parse
kStatus k16u_Parse(k16u *value, const kChar *str)
Converts string to k16u value.
kPoint16s::x
k16s x
X-coordinate value.
Definition: kApiDef.h:1285
kPoint3d16s::y
k16s y
Y-coordinate value.
Definition: kApiDef.h:1353
kSSize::kSSize_Format
kStatus kSSize_Format(kSSize value, kChar *buffer, kSize capacity)
Converts kSSize value to string.
kHashFx
kSize(kCall * kHashFx)(const void *item)
Callback signature to determine hash code of an item.
Definition: kApiDef.h:1696
k64f::k64f_Parse
kStatus k64f_Parse(k64f *value, const kChar *str)
Converts string to k64f value.
kRotatedRect32f::angle
k32f angle
Rotation angle of the rectangle.
Definition: kApiDef.h:1555
kSSize
Represents a signed integer that can store a pointer address.
kMsgQueueItemOption::kStatus
typedef kStatus(kCall *kMsgQueueDropFx)(kPointer receiver
Defines the signature of a callback function to handle dropped items.
kRect32s::height
k32s height
Height of the rectangle.
Definition: kApiDef.h:1443
kRect32f
Rectangle structure with 32-bit floating-point fields.
Definition: kApiDef.h:1454
kIsError
kBool kIsError(kStatus status)
Returns kTRUE if the given status value is not kOK.
Definition: kApiDef.h:534
kVersion::kVersion_Compare
k32s kVersion_Compare(kVersion version1, kVersion version2)
Returns an integral value indicating the relationship between the versions.
Definition: kApiDef.h:850
kRect32s::width
k32s width
Width of the rectangle.
Definition: kApiDef.h:1442
k32u::k32u_Parse
kStatus k32u_Parse(k32u *value, const kChar *str)
Converts string to k32u value.
kPoint32s::x
k32s x
X-coordinate value.
Definition: kApiDef.h:1299
kPixelFormat
Pixel format descriptor.
kRotatedRect32s::height
k32s height
Height of the rectangle.
Definition: kApiDef.h:1537
kRect64f
Rectangle structure with 64-bit floating-point fields.
Definition: kApiDef.h:1470
kText128
Represents a 128-unit, null-terminated, kChar sequence.
kPoint3d32f::x
k32f x
X-coordinate value.
Definition: kApiDef.h:1382
kVersion::kVersion_Minor
k8u kVersion_Minor(kVersion version)
Returns the minor part of a version number.
Definition: kApiDef.h:874
kChar::kChar_ToUpper
kChar kChar_ToUpper(kChar ch)
Convert ASCII character to upper case.
Definition: kApiDef.h:386
k16s::k16s_Format
kStatus k16s_Format(k16s value, kChar *buffer, kSize capacity)
Converts k16s value to string.
kEqualsFx
kBool(kCall * kEqualsFx)(const void *item1, const void *item2)
Callback signature to determine equality of two items.
Definition: kApiDef.h:1688
kVersion::kVersion_Major
k8u kVersion_Major(kVersion version)
Returns the major part of a version number.
Definition: kApiDef.h:862
kPoint16s::y
k16s y
Y-coordinate value.
Definition: kApiDef.h:1286
kMethodInfo
Represents type method information.
Definition: kApiDef.h:1953
kPoint3d16s::x
k16s x
X-coordinate value.
Definition: kApiDef.h:1352
kPoint3d32f::z
k32f z
Z-coordinate value.
Definition: kApiDef.h:1384
kFieldInfo::name
kTypeName name
Field name.
Definition: kApiDef.h:1967
k32f::k32f_Parse
kStatus k32f_Parse(k32f *value, const kChar *str)
Converts string to k32f value.
kRect64f::width
k64f width
Width of the rectangle.
Definition: kApiDef.h:1474
kPoint3d64f::z
k64f z
Z-coordinate value.
Definition: kApiDef.h:1399
kCallback
Represents a callback function and context pointer.
Definition: kApiDef.h:1714
kItemCopy
void kItemCopy(void *dest, const void *src, kSize size)
Performs a small copy with minimal overhead.
Definition: kApiDef.h:1888
kVersion::kVersion_Build
k8u kVersion_Build(kVersion version)
Returns the build part of a version number.
Definition: kApiDef.h:898
kArgb::r
k8u r
Red component value.
Definition: kApiDef.h:1649
kPoint32f
2D point structure with 32-bit floating-point fields.
Definition: kApiDef.h:1311
kRect3d64f::y
k64f y
Y-coordinate of the origin.
Definition: kApiDef.h:1503
k32s::k32s_Format
kStatus k32s_Format(k32s value, kChar *buffer, kSize capacity)
Converts k32s value to string.
kRotatedRect32s::yc
k32s yc
Y-coordinate of the rectangle center.
Definition: kApiDef.h:1535
k32s
Represents a 32-bit signed integer.
kPointer::kPointer_ByteOffset
void * kPointer_ByteOffset(const void *pointer, kSSize offset)
Calculates a pointer address from a base address and a byte offset.
Definition: kApiDef.h:278
kFunction
void(kCall * kFunction)()
Generic pointer to function.
Definition: kApiDef.h:28
kRgb::r
k8u r
Red component value.
Definition: kApiDef.h:1621
kRotatedRect32f::height
k32f height
Height of the rectangle.
Definition: kApiDef.h:1554
kChar::kChar_IsDigit
kBool kChar_IsDigit(kChar ch)
Checks whether ASCII character is a digit.
Definition: kApiDef.h:422
kPoint64f::x
k64f x
X-coordinate value.
Definition: kApiDef.h:1327
kItemZero
void kItemZero(void *dest, kSize size)
Zero-initializes a small amount of memory with minimal overhead.
Definition: kApiDef.h:1906
kVersion::kVersion_Create
kVersion kVersion_Create(k32u major, k32u minor, k32u release, k32u build)
Creates a version value from its constituent parts.
Definition: kApiDef.h:797
kFieldInfo::type
kType type
Field type.
Definition: kApiDef.h:1968
kVersion::kVersion_Release
k8u kVersion_Release(kVersion version)
Returns the release part of a version number.
Definition: kApiDef.h:886
kEndianness::kEndianness_Host
kEndianness kEndianness_Host()
Reports the endianness of the current platform.
Definition: kApiDef.h:921
k16s::k16s_Parse
kStatus k16s_Parse(k16s *value, const kChar *str)
Converts string to k16s value.
kPoint64f
2D point structure with 64-bit floating-point fields.
Definition: kApiDef.h:1325
kEndianness_ShouldReverse
kBool kEndianness_ShouldReverse(kEndianness endianness)
Reports whether byte ordering must be reversed to be consistent with the current platform.
Definition: kApiDef.h:932
kCallbackFx
kStatus(kCall * kCallbackFx)(kPointer receiver, kPointer sender, void *args)
Callback signature for a generic event handler.
Definition: kApiDef.h:1706
kRgb::g
k8u g
Green component value.
Definition: kApiDef.h:1620
k64s
Represents a 64-bit signed integer.
kSize::kSize_Format
kStatus kSize_Format(kSize value, kChar *buffer, kSize capacity)
Converts kSize value to string.
kVersion::kVersion_Format
kStatus kVersion_Format(kVersion version, kChar *buffer, kSize capacity)
Formats a version to a string buffer.
kText16
Represents a 16-unit, null-terminated, kChar sequence.
kFileMode
Flags that control how a file is opened.
k8s
Represents an 8-bit signed integer.
kEndianness
Represents the byte-ordering of primitive data types.
kRotatedRect32f::width
k32f width
Width of the rectangle.
Definition: kApiDef.h:1553
kArgb::b
k8u b
Blue component value.
Definition: kApiDef.h:1647
kRect16s::height
k16s height
Height of the rectangle.
Definition: kApiDef.h:1427
k8s::k8s_Format
kStatus k8s_Format(k8s value, kChar *buffer, kSize capacity)
Converts k8s value to string.
kType
Represents metadata about a type (class, interface, or value).
kArgb::g
k8u g
Green component value.
Definition: kApiDef.h:1648
k64s::k64s_Parse
kStatus k64s_Parse(k64s *value, const kChar *str)
Converts string to k64s value.
kPoint3d32s::x
k32s x
X-coordinate value.
Definition: kApiDef.h:1367
kVersion::kVersion_Parse
kStatus kVersion_Parse(kVersion *version, const kChar *buffer)
Parses a version from a formatted string.
kText32
Represents a 32-unit, null-terminated, kChar sequence.
kPoint3d16s
3D point structure with 16-bit signed integer fields.
Definition: kApiDef.h:1350
kEnumeratorInfo::value
k32s value
Enumerator numeric value.
Definition: kApiDef.h:1980
kMethodInfo::functionName
kTypeName functionName
Full function name (e.g. "kObject_Clone").
Definition: kApiDef.h:1956
k16s
Represents a 16-bit signed integer.
kRect32f::y
k32f y
Y-coordinate of the origin.
Definition: kApiDef.h:1457
k32f
Represents a 32-bit floating-point number.
kPoint64f::y
k64f y
Y-coordinate value.
Definition: kApiDef.h:1328
kObject
Root of all Zen classes.
kVersion
Represents a version number.
kArgb::a
k8u a
Alpha component value.
Definition: kApiDef.h:1650
kStatus::kOK
#define kOK
Operation successful.
Definition: kApiDef.h:513
kStatus
Represents an error code.
kRect3d64f::z
k64f z
Z-coordinate of the origin.
Definition: kApiDef.h:1504
k64u::k64u_Format
kStatus k64u_Format(k64u value, kChar *buffer, kSize capacity)
Converts k64u value to string.
kRgb::x
k8u x
Undefined.
Definition: kApiDef.h:1622
kPoint32s::y
k32s y
Y-coordinate value.
Definition: kApiDef.h:1300
kFieldInfo::offset
kSize offset
Offset of field within structure (bytes).
Definition: kApiDef.h:1969
kCall
#define kCall
kApi standard function calling convention.
Definition: kApiDef.h:15
kRect32f::width
k32f width
Width of the rectangle.
Definition: kApiDef.h:1458
k16u::k16u_Format
kStatus k16u_Format(k16u value, kChar *buffer, kSize capacity)
Converts k16u value to string.
kRect3d64f
Rectangular cuboid structure with 64-bit floating-point fields.
Definition: kApiDef.h:1500
k64f::k64f_Format
kStatus k64f_Format(k64f value, kChar *buffer, kSize capacity)
Converts k64f value to string.
kRect16s
Rectangle structure with 16-bit signed integer fields.
Definition: kApiDef.h:1422
k8u::k8u_Format
kStatus k8u_Format(k8u value, kChar *buffer, kSize capacity)
Converts k8u value to string.
k64f
Represents a 64-bit floating-point number.
kComparison
Represents a comparison type.
kPointer::kPointer_Diff
kSSize kPointer_Diff(void *a, void *b)
Calculates the signed difference between two pointers.
Definition: kApiDef.h:305
kRect32s::x
k32s x
X-coordinate of the origin.
Definition: kApiDef.h:1440
kRotatedRect32f::xc
k32f xc
X-coordinate of the rectangle center.
Definition: kApiDef.h:1551
kPoint32s
2D point structure with 32-bit signed integer fields.
Definition: kApiDef.h:1297
kBool
Represents a boolean value.
k64u::k64u_Parse
kStatus k64u_Parse(k64u *value, const kChar *str)
Converts string to k64u value.
kRect16s::x
k16s x
X-coordinate of the origin.
Definition: kApiDef.h:1424
kFieldInfo::count
kSize count
Count of values in this field (typically 1; can be higher for "array value" fields, e.g. kText32).
Definition: kApiDef.h:1970
kRect32f::height
k32f height
Height of the rectangle.
Definition: kApiDef.h:1459
kPoint3d64f
3D point structure with 64-bit floating-point fields.
Definition: kApiDef.h:1395
kPoint3d32s
3D point structure with 32-bit signed integer fields.
Definition: kApiDef.h:1365
k8u::k8u_Parse
kStatus k8u_Parse(k8u *value, const kChar *str)
Converts string to k8u value.
kPoint3d32f::y
k32f y
Y-coordinate value.
Definition: kApiDef.h:1383
k8s::k8s_Parse
kStatus k8s_Parse(k8s *value, const kChar *str)
Converts string to k8s value.