LIBJXL
types.h
Go to the documentation of this file.
1 /* Copyright (c) the JPEG XL Project Authors. All rights reserved.
2  *
3  * Use of this source code is governed by a BSD-style
4  * license that can be found in the LICENSE file.
5  */
6 
13 #ifndef JXL_TYPES_H_
14 #define JXL_TYPES_H_
15 
16 #include <stddef.h>
17 #include <stdint.h>
18 
19 #include "jxl/jxl_export.h"
20 
21 #if defined(__cplusplus) || defined(c_plusplus)
22 extern "C" {
23 #endif
24 
31 #define JXL_BOOL int
32 
33 #define JXL_TRUE 1
34 
35 #define JXL_FALSE 0
36 
39 typedef enum {
45 
49 
53 
56 } JxlDataType;
57 
58 /* DEPRECATED: bit-packed 1-bit data type. Use JXL_TYPE_UINT8 instead.
59  */
60 static const int JXL_DEPRECATED JXL_TYPE_BOOLEAN = 1;
61 
62 /* DEPRECATED: uint32_t data type. Use JXL_TYPE_FLOAT instead.
63  */
64 static const int JXL_DEPRECATED JXL_TYPE_UINT32 = 4;
65 
68 typedef enum {
79 
87 typedef struct {
96  uint32_t num_channels;
97 
101 
107 
111  size_t align;
113 
116 typedef char JxlBoxType[4];
117 
126 typedef enum {
127  // after completed kRegularFrames
128  kFrames = 0,
129  // after completed DC (1:8)
130  kDC = 1,
131  // after completed AC passes that are the last pass for their resolution
132  // target.
133  kLastPasses = 2,
134  // after completed AC passes that are not the last pass for their resolution
135  // target.
136  kPasses = 3,
137  // during DC frame when lower resolution are completed (1:32, 1:16)
138  kDCProgressive = 4,
139  // after completed groups
140  kDCGroups = 5,
141  // after completed groups
142  kGroups = 6,
144 
145 #if defined(__cplusplus) || defined(c_plusplus)
146 }
147 #endif
148 
149 #endif /* JXL_TYPES_H_ */
150 
JxlEndianness endianness
Definition: types.h:106
Definition: types.h:44
Definition: types.h:77
JxlDataType data_type
Definition: types.h:100
JxlProgressiveDetail
Definition: types.h:126
JxlDataType
Definition: types.h:39
Definition: types.h:52
char JxlBoxType[4]
Definition: types.h:116
Definition: types.h:55
Definition: types.h:73
Definition: types.h:87
Definition: types.h:75
Definition: types.h:48
size_t align
Definition: types.h:111
JxlEndianness
Definition: types.h:68
uint32_t num_channels
Definition: types.h:96