LIBJXL: jxl/encode.h Source File

LIBJXL

Loading...
Searching...
No Matches
encode.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_ENCODE_H_
14#define JXL_ENCODE_H_
15
16#include <jxl/cms_interface.h>
17#include <jxl/codestream_header.h>
18#include <jxl/jxl_export.h>
19#include <jxl/memory_manager.h>
20#include <jxl/parallel_runner.h>
21#include <jxl/stats.h>
22#include <jxl/version.h>
23#include <stdint.h>
24
25#include "jxl/types.h"
26
27#if defined(__cplusplus) || defined(c_plusplus)
28extern "C" {
29#endif
30
38JXL_EXPORT uint32_t JxlEncoderVersion(void);
39
46 typedef struct JxlEncoderStruct JxlEncoder;
47
56 typedef struct JxlEncoderFrameSettingsStruct JxlEncoderFrameSettings;
57
61 typedef enum {
65 JXL_ENC_SUCCESS = 0,
66
69 JXL_ENC_ERROR = 1,
70
73 JXL_ENC_NEED_MORE_OUTPUT = 2,
74
75} JxlEncoderStatus;
76
82 typedef enum {
85 JXL_ENC_ERR_OK = 0,
86
89 JXL_ENC_ERR_GENERIC = 1,
90
94 JXL_ENC_ERR_OOM = 2,
95
99 JXL_ENC_ERR_JBRD = 3,
100
103 JXL_ENC_ERR_BAD_INPUT = 4,
104
109 JXL_ENC_ERR_NOT_SUPPORTED = 0x80,
110
115 JXL_ENC_ERR_API_USAGE = 0x81,
116
117} JxlEncoderError;
118
125 typedef enum {
131 JXL_ENC_FRAME_SETTING_EFFORT = 0,
132
137 JXL_ENC_FRAME_SETTING_DECODING_SPEED = 1,
138
145 JXL_ENC_FRAME_SETTING_RESAMPLING = 2,
146
152 JXL_ENC_FRAME_SETTING_EXTRA_CHANNEL_RESAMPLING = 3,
153
163 JXL_ENC_FRAME_SETTING_ALREADY_DOWNSAMPLED = 4,
164
170 JXL_ENC_FRAME_SETTING_PHOTON_NOISE = 5,
171
176 JXL_ENC_FRAME_SETTING_NOISE = 6,
177
181 JXL_ENC_FRAME_SETTING_DOTS = 7,
182
186 JXL_ENC_FRAME_SETTING_PATCHES = 8,
187
191 JXL_ENC_FRAME_SETTING_EPF = 9,
192
196 JXL_ENC_FRAME_SETTING_GABORISH = 10,
197
202 JXL_ENC_FRAME_SETTING_MODULAR = 11,
203
207 JXL_ENC_FRAME_SETTING_KEEP_INVISIBLE = 12,
208
213 JXL_ENC_FRAME_SETTING_GROUP_ORDER = 13,
214
219 JXL_ENC_FRAME_SETTING_GROUP_ORDER_CENTER_X = 14,
220
224 JXL_ENC_FRAME_SETTING_GROUP_ORDER_CENTER_Y = 15,
225
229 JXL_ENC_FRAME_SETTING_RESPONSIVE = 16,
230
235 JXL_ENC_FRAME_SETTING_PROGRESSIVE_AC = 17,
236
241 JXL_ENC_FRAME_SETTING_QPROGRESSIVE_AC = 18,
242
247 JXL_ENC_FRAME_SETTING_PROGRESSIVE_DC = 19,
248
253 JXL_ENC_FRAME_SETTING_CHANNEL_COLORS_GLOBAL_PERCENT = 20,
254
259 JXL_ENC_FRAME_SETTING_CHANNEL_COLORS_GROUP_PERCENT = 21,
260
264 JXL_ENC_FRAME_SETTING_PALETTE_COLORS = 22,
265
269 JXL_ENC_FRAME_SETTING_LOSSY_PALETTE = 23,
270
276 JXL_ENC_FRAME_SETTING_COLOR_TRANSFORM = 24,
277
285 JXL_ENC_FRAME_SETTING_MODULAR_COLOR_SPACE = 25,
286
289 JXL_ENC_FRAME_SETTING_MODULAR_GROUP_SIZE = 26,
290
296 JXL_ENC_FRAME_SETTING_MODULAR_PREDICTOR = 27,
297
302 JXL_ENC_FRAME_SETTING_MODULAR_MA_TREE_LEARNING_PERCENT = 28,
303
310 JXL_ENC_FRAME_SETTING_MODULAR_NB_PREV_CHANNELS = 29,
311
315 JXL_ENC_FRAME_SETTING_JPEG_RECON_CFL = 30,
316
326 JXL_ENC_FRAME_INDEX_BOX = 31,
327
333 JXL_ENC_FRAME_SETTING_BROTLI_EFFORT = 32,
334
340 JXL_ENC_FRAME_SETTING_JPEG_COMPRESS_BOXES = 33,
341
353 JXL_ENC_FRAME_SETTING_BUFFERING = 34,
354
362 JXL_ENC_FRAME_SETTING_JPEG_KEEP_EXIF = 35,
363
370 JXL_ENC_FRAME_SETTING_JPEG_KEEP_XMP = 36,
371
377 JXL_ENC_FRAME_SETTING_JPEG_KEEP_JUMBF = 37,
378
382 JXL_ENC_FRAME_SETTING_FILL_ENUM = 65535,
383
384} JxlEncoderFrameSettingId;
385
398JXL_EXPORT JxlEncoder* JxlEncoderCreate(const JxlMemoryManager* memory_manager);
399
407JXL_EXPORT void JxlEncoderReset(JxlEncoder* enc);
408
414JXL_EXPORT void JxlEncoderDestroy(JxlEncoder* enc);
415
425JXL_EXPORT void JxlEncoderSetCms(JxlEncoder* enc, JxlCmsInterface cms);
426
439JXL_EXPORT JxlEncoderStatus
440JxlEncoderSetParallelRunner(JxlEncoder* enc, JxlParallelRunner parallel_runner,
441 void* parallel_runner_opaque);
442
450JXL_EXPORT JxlEncoderError JxlEncoderGetError(JxlEncoder* enc);
451
482JXL_EXPORT JxlEncoderStatus JxlEncoderProcessOutput(JxlEncoder* enc,
483 uint8_t** next_out,
484 size_t* avail_out);
485
519JXL_EXPORT JxlEncoderStatus
520JxlEncoderSetFrameHeader(JxlEncoderFrameSettings* frame_settings,
521 const JxlFrameHeader* frame_header);
522
534JXL_EXPORT JxlEncoderStatus JxlEncoderSetExtraChannelBlendInfo(
535 JxlEncoderFrameSettings* frame_settings, size_t index,
536 const JxlBlendInfo* blend_info);
537
557JXL_EXPORT JxlEncoderStatus JxlEncoderSetFrameName(
558 JxlEncoderFrameSettings* frame_settings, const char* frame_name);
559
573JXL_EXPORT JxlEncoderStatus JxlEncoderSetFrameBitDepth(
574 JxlEncoderFrameSettings* frame_settings, const JxlBitDepth* bit_depth);
575
602JXL_EXPORT JxlEncoderStatus
603JxlEncoderAddJPEGFrame(const JxlEncoderFrameSettings* frame_settings,
604 const uint8_t* buffer, size_t size);
605
670JXL_EXPORT JxlEncoderStatus JxlEncoderAddImageFrame(
671 const JxlEncoderFrameSettings* frame_settings,
672 const JxlPixelFormat* pixel_format, const void* buffer, size_t size);
673
703 struct JxlEncoderOutputProcessor {
709 void* opaque;
710
728 void* (*get_buffer)(void* opaque, size_t* size);
729
739 void (*release_buffer)(void* opaque, size_t written_bytes);
740
751 void (*seek)(void* opaque, uint64_t position);
752
764 void (*set_finalized_position)(void* opaque, uint64_t finalized_position);
765};
766
779JXL_EXPORT JxlEncoderStatus JxlEncoderSetOutputProcessor(
780 JxlEncoder* enc, struct JxlEncoderOutputProcessor output_processor);
781
795JXL_EXPORT JxlEncoderStatus JxlEncoderFlushInput(JxlEncoder* enc);
796
801 struct JxlChunkedFrameInputSource {
806 void* opaque;
807
820 void (*get_color_channels_pixel_format)(void* opaque,
821 JxlPixelFormat* pixel_format);
822
846 const void* (*get_color_channel_data_at)(void* opaque, size_t xpos,
847 size_t ypos, size_t xsize,
848 size_t ysize, size_t* row_offset);
849
863 void (*get_extra_channel_pixel_format)(void* opaque, size_t ec_index,
864 JxlPixelFormat* pixel_format);
865
890 const void* (*get_extra_channel_data_at)(void* opaque, size_t ec_index,
891 size_t xpos, size_t ypos,
892 size_t xsize, size_t ysize,
893 size_t* row_offset);
894
905 void (*release_buffer)(void* opaque, const void* buf);
906};
907
928JXL_EXPORT JxlEncoderStatus JxlEncoderAddChunkedFrame(
929 const JxlEncoderFrameSettings* frame_settings, JXL_BOOL is_last_frame,
930 struct JxlChunkedFrameInputSource chunked_frame_input);
931
955JXL_EXPORT JxlEncoderStatus JxlEncoderSetExtraChannelBuffer(
956 const JxlEncoderFrameSettings* frame_settings,
957 const JxlPixelFormat* pixel_format, const void* buffer, size_t size,
958 uint32_t index);
959
1028JXL_EXPORT JxlEncoderStatus JxlEncoderAddBox(JxlEncoder* enc,
1029 const JxlBoxType type,
1030 const uint8_t* contents,
1031 size_t size,
1032 JXL_BOOL compress_box);
1033
1045JXL_EXPORT JxlEncoderStatus JxlEncoderUseBoxes(JxlEncoder* enc);
1046
1062JXL_EXPORT void JxlEncoderCloseBoxes(JxlEncoder* enc);
1063
1076JXL_EXPORT void JxlEncoderCloseFrames(JxlEncoder* enc);
1077
1092JXL_EXPORT void JxlEncoderCloseInput(JxlEncoder* enc);
1093
1107JXL_EXPORT JxlEncoderStatus
1108JxlEncoderSetColorEncoding(JxlEncoder* enc, const JxlColorEncoding* color);
1109
1123JXL_EXPORT JxlEncoderStatus JxlEncoderSetICCProfile(JxlEncoder* enc,
1124 const uint8_t* icc_profile,
1125 size_t size);
1126
1136JXL_EXPORT void JxlEncoderInitBasicInfo(JxlBasicInfo* info);
1137
1148JXL_EXPORT void JxlEncoderInitFrameHeader(JxlFrameHeader* frame_header);
1149
1157JXL_EXPORT void JxlEncoderInitBlendInfo(JxlBlendInfo* blend_info);
1158
1174JXL_EXPORT JxlEncoderStatus JxlEncoderSetBasicInfo(JxlEncoder* enc,
1175 const JxlBasicInfo* info);
1176
1193JXL_EXPORT JxlEncoderStatus JxlEncoderSetUpsamplingMode(JxlEncoder* enc,
1194 const int64_t factor,
1195 const int64_t mode);
1196
1207JXL_EXPORT void JxlEncoderInitExtraChannelInfo(JxlExtraChannelType type,
1208 JxlExtraChannelInfo* info);
1209
1220JXL_EXPORT JxlEncoderStatus JxlEncoderSetExtraChannelInfo(
1221 JxlEncoder* enc, size_t index, const JxlExtraChannelInfo* info);
1222
1237JXL_EXPORT JxlEncoderStatus JxlEncoderSetExtraChannelName(JxlEncoder* enc,
1238 size_t index,
1239 const char* name,
1240 size_t size);
1241
1256JXL_EXPORT JxlEncoderStatus JxlEncoderFrameSettingsSetOption(
1257 JxlEncoderFrameSettings* frame_settings, JxlEncoderFrameSettingId option,
1258 int64_t value);
1259
1274JXL_EXPORT JxlEncoderStatus JxlEncoderFrameSettingsSetFloatOption(
1275 JxlEncoderFrameSettings* frame_settings, JxlEncoderFrameSettingId option,
1276 float value);
1277
1296JXL_EXPORT JxlEncoderStatus JxlEncoderUseContainer(JxlEncoder* enc,
1297 JXL_BOOL use_container);
1298
1313JXL_EXPORT JxlEncoderStatus
1314JxlEncoderStoreJPEGMetadata(JxlEncoder* enc, JXL_BOOL store_jpeg_metadata);
1315
1350JXL_EXPORT JxlEncoderStatus JxlEncoderSetCodestreamLevel(JxlEncoder* enc,
1351 int level);
1352
1372JXL_EXPORT int JxlEncoderGetRequiredCodestreamLevel(const JxlEncoder* enc);
1373
1392JXL_EXPORT JxlEncoderStatus JxlEncoderSetFrameLossless(
1393 JxlEncoderFrameSettings* frame_settings, JXL_BOOL lossless);
1394
1409JXL_EXPORT JxlEncoderStatus JxlEncoderSetFrameDistance(
1410 JxlEncoderFrameSettings* frame_settings, float distance);
1411
1425JXL_EXPORT JxlEncoderStatus JxlEncoderSetExtraChannelDistance(
1426 JxlEncoderFrameSettings* frame_settings, size_t index, float distance);
1427
1464JXL_EXPORT float JxlEncoderDistanceFromQuality(float quality);
1465
1481JXL_EXPORT JxlEncoderFrameSettings* JxlEncoderFrameSettingsCreate(
1482 JxlEncoder* enc, const JxlEncoderFrameSettings* source);
1483
1490JXL_EXPORT void JxlColorEncodingSetToSRGB(JxlColorEncoding* color_encoding,
1491 JXL_BOOL is_gray);
1492
1499JXL_EXPORT void JxlColorEncodingSetToLinearSRGB(
1500 JxlColorEncoding* color_encoding, JXL_BOOL is_gray);
1501
1510JXL_EXPORT void JxlEncoderAllowExpertOptions(JxlEncoder* enc);
1511
1528 typedef void (*JxlDebugImageCallback)(void* opaque, const char* label,
1529 size_t xsize, size_t ysize,
1530 const JxlColorEncoding* color,
1531 const uint16_t* pixels);
1532
1545JXL_EXPORT void JxlEncoderSetDebugImageCallback(
1546 JxlEncoderFrameSettings* frame_settings, JxlDebugImageCallback callback,
1547 void* opaque);
1548
1560JXL_EXPORT void JxlEncoderCollectStats(JxlEncoderFrameSettings* frame_settings,
1561 JxlEncoderStats* stats);
1562
1563#if defined(__cplusplus) || defined(c_plusplus)
1564}
1565#endif
1566
1567#endif /* JXL_ENCODE_H_ */
1568
cms_interface.h
Interface to allow the injection of different color management systems (CMSes, also called color mana...
codestream_header.h
Definitions of structs and enums for the metadata from the JPEG XL codestream headers (signature,...
JxlBoxType
char JxlBoxType[4]
Definition types.h:146
JXL_BOOL
#define JXL_BOOL
Definition types.h:30
JxlEncoderGetRequiredCodestreamLevel
JXL_EXPORT int JxlEncoderGetRequiredCodestreamLevel(const JxlEncoder *enc)
JxlEncoderSetCodestreamLevel
JXL_EXPORT JxlEncoderStatus JxlEncoderSetCodestreamLevel(JxlEncoder *enc, int level)
JxlEncoderAddJPEGFrame
JXL_EXPORT JxlEncoderStatus JxlEncoderAddJPEGFrame(const JxlEncoderFrameSettings *frame_settings, const uint8_t *buffer, size_t size)
JxlDebugImageCallback
void(* JxlDebugImageCallback)(void *opaque, const char *label, size_t xsize, size_t ysize, const JxlColorEncoding *color, const uint16_t *pixels)
Definition encode.h:1528
JxlEncoderInitBlendInfo
JXL_EXPORT void JxlEncoderInitBlendInfo(JxlBlendInfo *blend_info)
JxlEncoderCloseInput
JXL_EXPORT void JxlEncoderCloseInput(JxlEncoder *enc)
JxlEncoderSetParallelRunner
JXL_EXPORT JxlEncoderStatus JxlEncoderSetParallelRunner(JxlEncoder *enc, JxlParallelRunner parallel_runner, void *parallel_runner_opaque)
JxlEncoderCollectStats
JXL_EXPORT void JxlEncoderCollectStats(JxlEncoderFrameSettings *frame_settings, JxlEncoderStats *stats)
JxlEncoderStats
struct JxlEncoderStatsStruct JxlEncoderStats
Definition stats.h:29
JxlEncoderFrameSettingsSetOption
JXL_EXPORT JxlEncoderStatus JxlEncoderFrameSettingsSetOption(JxlEncoderFrameSettings *frame_settings, JxlEncoderFrameSettingId option, int64_t value)
JxlEncoder
struct JxlEncoderStruct JxlEncoder
Definition encode.h:46
JxlEncoderCreate
JXL_EXPORT JxlEncoder * JxlEncoderCreate(const JxlMemoryManager *memory_manager)
JxlEncoderSetExtraChannelBuffer
JXL_EXPORT JxlEncoderStatus JxlEncoderSetExtraChannelBuffer(const JxlEncoderFrameSettings *frame_settings, const JxlPixelFormat *pixel_format, const void *buffer, size_t size, uint32_t index)
JxlEncoderProcessOutput
JXL_EXPORT JxlEncoderStatus JxlEncoderProcessOutput(JxlEncoder *enc, uint8_t **next_out, size_t *avail_out)
JxlEncoderUseContainer
JXL_EXPORT JxlEncoderStatus JxlEncoderUseContainer(JxlEncoder *enc, JXL_BOOL use_container)
JxlColorEncodingSetToSRGB
JXL_EXPORT void JxlColorEncodingSetToSRGB(JxlColorEncoding *color_encoding, JXL_BOOL is_gray)
JxlEncoderSetCms
JXL_EXPORT void JxlEncoderSetCms(JxlEncoder *enc, JxlCmsInterface cms)
JxlEncoderSetFrameBitDepth
JXL_EXPORT JxlEncoderStatus JxlEncoderSetFrameBitDepth(JxlEncoderFrameSettings *frame_settings, const JxlBitDepth *bit_depth)
JxlEncoderInitFrameHeader
JXL_EXPORT void JxlEncoderInitFrameHeader(JxlFrameHeader *frame_header)
JxlEncoderDistanceFromQuality
JXL_EXPORT float JxlEncoderDistanceFromQuality(float quality)
JxlEncoderReset
JXL_EXPORT void JxlEncoderReset(JxlEncoder *enc)
JxlEncoderSetFrameLossless
JXL_EXPORT JxlEncoderStatus JxlEncoderSetFrameLossless(JxlEncoderFrameSettings *frame_settings, JXL_BOOL lossless)
JxlEncoderFrameSettingsSetFloatOption
JXL_EXPORT JxlEncoderStatus JxlEncoderFrameSettingsSetFloatOption(JxlEncoderFrameSettings *frame_settings, JxlEncoderFrameSettingId option, float value)
JxlEncoderUseBoxes
JXL_EXPORT JxlEncoderStatus JxlEncoderUseBoxes(JxlEncoder *enc)
JxlEncoderSetOutputProcessor
JXL_EXPORT JxlEncoderStatus JxlEncoderSetOutputProcessor(JxlEncoder *enc, struct JxlEncoderOutputProcessor output_processor)
JxlEncoderInitBasicInfo
JXL_EXPORT void JxlEncoderInitBasicInfo(JxlBasicInfo *info)
JxlEncoderSetBasicInfo
JXL_EXPORT JxlEncoderStatus JxlEncoderSetBasicInfo(JxlEncoder *enc, const JxlBasicInfo *info)
JxlEncoderSetColorEncoding
JXL_EXPORT JxlEncoderStatus JxlEncoderSetColorEncoding(JxlEncoder *enc, const JxlColorEncoding *color)
JxlEncoderSetExtraChannelBlendInfo
JXL_EXPORT JxlEncoderStatus JxlEncoderSetExtraChannelBlendInfo(JxlEncoderFrameSettings *frame_settings, size_t index, const JxlBlendInfo *blend_info)
JxlEncoderCloseBoxes
JXL_EXPORT void JxlEncoderCloseBoxes(JxlEncoder *enc)
JxlEncoderSetFrameDistance
JXL_EXPORT JxlEncoderStatus JxlEncoderSetFrameDistance(JxlEncoderFrameSettings *frame_settings, float distance)
JxlEncoderStatus
JxlEncoderStatus
Definition encode.h:61
JxlEncoderAllowExpertOptions
JXL_EXPORT void JxlEncoderAllowExpertOptions(JxlEncoder *enc)
JxlEncoderSetFrameHeader
JXL_EXPORT JxlEncoderStatus JxlEncoderSetFrameHeader(JxlEncoderFrameSettings *frame_settings, const JxlFrameHeader *frame_header)
JxlColorEncodingSetToLinearSRGB
JXL_EXPORT void JxlColorEncodingSetToLinearSRGB(JxlColorEncoding *color_encoding, JXL_BOOL is_gray)
JxlEncoderInitExtraChannelInfo
JXL_EXPORT void JxlEncoderInitExtraChannelInfo(JxlExtraChannelType type, JxlExtraChannelInfo *info)
JxlEncoderSetExtraChannelDistance
JXL_EXPORT JxlEncoderStatus JxlEncoderSetExtraChannelDistance(JxlEncoderFrameSettings *frame_settings, size_t index, float distance)
JxlEncoderCloseFrames
JXL_EXPORT void JxlEncoderCloseFrames(JxlEncoder *enc)
JxlEncoderAddImageFrame
JXL_EXPORT JxlEncoderStatus JxlEncoderAddImageFrame(const JxlEncoderFrameSettings *frame_settings, const JxlPixelFormat *pixel_format, const void *buffer, size_t size)
JxlEncoderSetICCProfile
JXL_EXPORT JxlEncoderStatus JxlEncoderSetICCProfile(JxlEncoder *enc, const uint8_t *icc_profile, size_t size)
JxlEncoderSetFrameName
JXL_EXPORT JxlEncoderStatus JxlEncoderSetFrameName(JxlEncoderFrameSettings *frame_settings, const char *frame_name)
JxlEncoderSetDebugImageCallback
JXL_EXPORT void JxlEncoderSetDebugImageCallback(JxlEncoderFrameSettings *frame_settings, JxlDebugImageCallback callback, void *opaque)
JxlEncoderVersion
JXL_EXPORT uint32_t JxlEncoderVersion(void)
JxlEncoderFrameSettingsCreate
JXL_EXPORT JxlEncoderFrameSettings * JxlEncoderFrameSettingsCreate(JxlEncoder *enc, const JxlEncoderFrameSettings *source)
JxlEncoderGetError
JXL_EXPORT JxlEncoderError JxlEncoderGetError(JxlEncoder *enc)
JxlEncoderSetExtraChannelName
JXL_EXPORT JxlEncoderStatus JxlEncoderSetExtraChannelName(JxlEncoder *enc, size_t index, const char *name, size_t size)
JxlEncoderFrameSettings
struct JxlEncoderFrameSettingsStruct JxlEncoderFrameSettings
Definition encode.h:56
JxlEncoderAddBox
JXL_EXPORT JxlEncoderStatus JxlEncoderAddBox(JxlEncoder *enc, const JxlBoxType type, const uint8_t *contents, size_t size, JXL_BOOL compress_box)
JxlEncoderFlushInput
JXL_EXPORT JxlEncoderStatus JxlEncoderFlushInput(JxlEncoder *enc)
JxlEncoderError
JxlEncoderError
Definition encode.h:82
JxlEncoderFrameSettingId
JxlEncoderFrameSettingId
Definition encode.h:125
JxlEncoderSetUpsamplingMode
JXL_EXPORT JxlEncoderStatus JxlEncoderSetUpsamplingMode(JxlEncoder *enc, const int64_t factor, const int64_t mode)
JxlEncoderDestroy
JXL_EXPORT void JxlEncoderDestroy(JxlEncoder *enc)
JxlEncoderSetExtraChannelInfo
JXL_EXPORT JxlEncoderStatus JxlEncoderSetExtraChannelInfo(JxlEncoder *enc, size_t index, const JxlExtraChannelInfo *info)
JxlEncoderStoreJPEGMetadata
JXL_EXPORT JxlEncoderStatus JxlEncoderStoreJPEGMetadata(JxlEncoder *enc, JXL_BOOL store_jpeg_metadata)
JxlEncoderAddChunkedFrame
JXL_EXPORT JxlEncoderStatus JxlEncoderAddChunkedFrame(const JxlEncoderFrameSettings *frame_settings, JXL_BOOL is_last_frame, struct JxlChunkedFrameInputSource chunked_frame_input)
Adds a frame to the encoder using a chunked input source.
JXL_ENC_ERROR
@ JXL_ENC_ERROR
Definition encode.h:69
JXL_ENC_NEED_MORE_OUTPUT
@ JXL_ENC_NEED_MORE_OUTPUT
Definition encode.h:73
JXL_ENC_SUCCESS
@ JXL_ENC_SUCCESS
Definition encode.h:65
JXL_ENC_ERR_NOT_SUPPORTED
@ JXL_ENC_ERR_NOT_SUPPORTED
Definition encode.h:109
JXL_ENC_ERR_JBRD
@ JXL_ENC_ERR_JBRD
Definition encode.h:99
JXL_ENC_ERR_API_USAGE
@ JXL_ENC_ERR_API_USAGE
Definition encode.h:115
JXL_ENC_ERR_OOM
@ JXL_ENC_ERR_OOM
Definition encode.h:94
JXL_ENC_ERR_OK
@ JXL_ENC_ERR_OK
Definition encode.h:85
JXL_ENC_ERR_GENERIC
@ JXL_ENC_ERR_GENERIC
Definition encode.h:89
JXL_ENC_ERR_BAD_INPUT
@ JXL_ENC_ERR_BAD_INPUT
Definition encode.h:103
JXL_ENC_FRAME_SETTING_DECODING_SPEED
@ JXL_ENC_FRAME_SETTING_DECODING_SPEED
Definition encode.h:137
JXL_ENC_FRAME_SETTING_JPEG_COMPRESS_BOXES
@ JXL_ENC_FRAME_SETTING_JPEG_COMPRESS_BOXES
Definition encode.h:340
JXL_ENC_FRAME_SETTING_MODULAR_GROUP_SIZE
@ JXL_ENC_FRAME_SETTING_MODULAR_GROUP_SIZE
Definition encode.h:289
JXL_ENC_FRAME_SETTING_PROGRESSIVE_DC
@ JXL_ENC_FRAME_SETTING_PROGRESSIVE_DC
Definition encode.h:247
JXL_ENC_FRAME_SETTING_EXTRA_CHANNEL_RESAMPLING
@ JXL_ENC_FRAME_SETTING_EXTRA_CHANNEL_RESAMPLING
Definition encode.h:152
JXL_ENC_FRAME_SETTING_GROUP_ORDER_CENTER_X
@ JXL_ENC_FRAME_SETTING_GROUP_ORDER_CENTER_X
Definition encode.h:219
JXL_ENC_FRAME_SETTING_JPEG_KEEP_XMP
@ JXL_ENC_FRAME_SETTING_JPEG_KEEP_XMP
Definition encode.h:370
JXL_ENC_FRAME_SETTING_NOISE
@ JXL_ENC_FRAME_SETTING_NOISE
Definition encode.h:176
JXL_ENC_FRAME_SETTING_ALREADY_DOWNSAMPLED
@ JXL_ENC_FRAME_SETTING_ALREADY_DOWNSAMPLED
Definition encode.h:163
JXL_ENC_FRAME_SETTING_RESPONSIVE
@ JXL_ENC_FRAME_SETTING_RESPONSIVE
Definition encode.h:229
JXL_ENC_FRAME_SETTING_JPEG_RECON_CFL
@ JXL_ENC_FRAME_SETTING_JPEG_RECON_CFL
Definition encode.h:315
JXL_ENC_FRAME_SETTING_PATCHES
@ JXL_ENC_FRAME_SETTING_PATCHES
Definition encode.h:186
JXL_ENC_FRAME_SETTING_JPEG_KEEP_JUMBF
@ JXL_ENC_FRAME_SETTING_JPEG_KEEP_JUMBF
Definition encode.h:377
JXL_ENC_FRAME_SETTING_GROUP_ORDER
@ JXL_ENC_FRAME_SETTING_GROUP_ORDER
Definition encode.h:213
JXL_ENC_FRAME_SETTING_EPF
@ JXL_ENC_FRAME_SETTING_EPF
Definition encode.h:191
JXL_ENC_FRAME_SETTING_CHANNEL_COLORS_GLOBAL_PERCENT
@ JXL_ENC_FRAME_SETTING_CHANNEL_COLORS_GLOBAL_PERCENT
Definition encode.h:253
JXL_ENC_FRAME_SETTING_RESAMPLING
@ JXL_ENC_FRAME_SETTING_RESAMPLING
Definition encode.h:145
JXL_ENC_FRAME_SETTING_DOTS
@ JXL_ENC_FRAME_SETTING_DOTS
Definition encode.h:181
JXL_ENC_FRAME_SETTING_COLOR_TRANSFORM
@ JXL_ENC_FRAME_SETTING_COLOR_TRANSFORM
Definition encode.h:276
JXL_ENC_FRAME_SETTING_EFFORT
@ JXL_ENC_FRAME_SETTING_EFFORT
Definition encode.h:131
JXL_ENC_FRAME_SETTING_MODULAR
@ JXL_ENC_FRAME_SETTING_MODULAR
Definition encode.h:202
JXL_ENC_FRAME_SETTING_MODULAR_COLOR_SPACE
@ JXL_ENC_FRAME_SETTING_MODULAR_COLOR_SPACE
Definition encode.h:285
JXL_ENC_FRAME_SETTING_KEEP_INVISIBLE
@ JXL_ENC_FRAME_SETTING_KEEP_INVISIBLE
Definition encode.h:207
JXL_ENC_FRAME_SETTING_PHOTON_NOISE
@ JXL_ENC_FRAME_SETTING_PHOTON_NOISE
Definition encode.h:170
JXL_ENC_FRAME_SETTING_BUFFERING
@ JXL_ENC_FRAME_SETTING_BUFFERING
Definition encode.h:353
JXL_ENC_FRAME_SETTING_BROTLI_EFFORT
@ JXL_ENC_FRAME_SETTING_BROTLI_EFFORT
Definition encode.h:333
JXL_ENC_FRAME_SETTING_GROUP_ORDER_CENTER_Y
@ JXL_ENC_FRAME_SETTING_GROUP_ORDER_CENTER_Y
Definition encode.h:224
JXL_ENC_FRAME_SETTING_GABORISH
@ JXL_ENC_FRAME_SETTING_GABORISH
Definition encode.h:196
JXL_ENC_FRAME_SETTING_QPROGRESSIVE_AC
@ JXL_ENC_FRAME_SETTING_QPROGRESSIVE_AC
Definition encode.h:241
JXL_ENC_FRAME_SETTING_MODULAR_NB_PREV_CHANNELS
@ JXL_ENC_FRAME_SETTING_MODULAR_NB_PREV_CHANNELS
Definition encode.h:310
JXL_ENC_FRAME_SETTING_JPEG_KEEP_EXIF
@ JXL_ENC_FRAME_SETTING_JPEG_KEEP_EXIF
Definition encode.h:362
JXL_ENC_FRAME_SETTING_FILL_ENUM
@ JXL_ENC_FRAME_SETTING_FILL_ENUM
Definition encode.h:382
JXL_ENC_FRAME_SETTING_PROGRESSIVE_AC
@ JXL_ENC_FRAME_SETTING_PROGRESSIVE_AC
Definition encode.h:235
JXL_ENC_FRAME_SETTING_MODULAR_MA_TREE_LEARNING_PERCENT
@ JXL_ENC_FRAME_SETTING_MODULAR_MA_TREE_LEARNING_PERCENT
Definition encode.h:302
JXL_ENC_FRAME_SETTING_LOSSY_PALETTE
@ JXL_ENC_FRAME_SETTING_LOSSY_PALETTE
Definition encode.h:269
JXL_ENC_FRAME_SETTING_MODULAR_PREDICTOR
@ JXL_ENC_FRAME_SETTING_MODULAR_PREDICTOR
Definition encode.h:296
JXL_ENC_FRAME_SETTING_PALETTE_COLORS
@ JXL_ENC_FRAME_SETTING_PALETTE_COLORS
Definition encode.h:264
JXL_ENC_FRAME_SETTING_CHANNEL_COLORS_GROUP_PERCENT
@ JXL_ENC_FRAME_SETTING_CHANNEL_COLORS_GROUP_PERCENT
Definition encode.h:259
JXL_ENC_FRAME_INDEX_BOX
@ JXL_ENC_FRAME_INDEX_BOX
Definition encode.h:326
JxlExtraChannelType
JxlExtraChannelType
Definition codestream_header.h:44
JxlParallelRunner
JxlParallelRetCode(* JxlParallelRunner)(void *runner_opaque, void *jpegxl_opaque, JxlParallelRunInit init, JxlParallelRunFunction func, uint32_t start_range, uint32_t end_range)
Definition parallel_runner.h:119
memory_manager.h
Abstraction functions used by JPEG XL to allocate memory.
parallel_runner.h
stats.h
API to collect various statistics from JXL encoder.
JxlBasicInfo
Definition codestream_header.h:95
JxlBitDepth
Definition types.h:133
JxlBlendInfo
Definition codestream_header.h:328
JxlChunkedFrameInputSource
Definition encode.h:801
JxlChunkedFrameInputSource::release_buffer
void(* release_buffer)(void *opaque, const void *buf)
Definition encode.h:905
JxlChunkedFrameInputSource::get_color_channels_pixel_format
void(* get_color_channels_pixel_format)(void *opaque, JxlPixelFormat *pixel_format)
Definition encode.h:820
JxlChunkedFrameInputSource::get_extra_channel_pixel_format
void(* get_extra_channel_pixel_format)(void *opaque, size_t ec_index, JxlPixelFormat *pixel_format)
Definition encode.h:863
JxlChunkedFrameInputSource::opaque
void * opaque
Definition encode.h:806
JxlCmsInterface
Definition cms_interface.h:224
JxlColorEncoding
Definition color_encoding.h:116
JxlEncoderOutputProcessor
Definition encode.h:703
JxlEncoderOutputProcessor::opaque
void * opaque
Definition encode.h:709
JxlEncoderOutputProcessor::seek
void(* seek)(void *opaque, uint64_t position)
Definition encode.h:751
JxlEncoderOutputProcessor::set_finalized_position
void(* set_finalized_position)(void *opaque, uint64_t finalized_position)
Definition encode.h:764
JxlEncoderOutputProcessor::release_buffer
void(* release_buffer)(void *opaque, size_t written_bytes)
Definition encode.h:739
JxlExtraChannelInfo
Definition codestream_header.h:263
JxlFrameHeader
Definition codestream_header.h:389
JxlMemoryManagerStruct
Definition memory_manager.h:51
JxlPixelFormat
Definition types.h:79
types.h
Data types for the JPEG XL API, for both encoding and decoding.