LIBJXL
resizable_parallel_runner.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 
30 #ifndef JXL_RESIZABLE_PARALLEL_RUNNER_H_
31 #define JXL_RESIZABLE_PARALLEL_RUNNER_H_
32 
33 #include <stddef.h>
34 #include <stdint.h>
35 #include <stdio.h>
36 #include <stdlib.h>
37 
38 #include "jxl/jxl_threads_export.h"
39 #include "jxl/memory_manager.h"
40 #include "jxl/parallel_runner.h"
41 
42 #if defined(__cplusplus) || defined(c_plusplus)
43 extern "C" {
44 #endif
45 
49  void* runner_opaque, void* jpegxl_opaque, JxlParallelRunInit init,
50  JxlParallelRunFunction func, uint32_t start_range, uint32_t end_range);
51 
56 JXL_THREADS_EXPORT void* JxlResizableParallelRunnerCreate(
57  const JxlMemoryManager* memory_manager);
58 
61 JXL_THREADS_EXPORT void JxlResizableParallelRunnerSetThreads(
62  void* runner_opaque, size_t num_threads);
63 
66 JXL_THREADS_EXPORT uint32_t
67 JxlResizableParallelRunnerSuggestThreads(uint64_t xsize, uint64_t ysize);
68 
71 JXL_THREADS_EXPORT void JxlResizableParallelRunnerDestroy(void* runner_opaque);
72 
73 #if defined(__cplusplus) || defined(c_plusplus)
74 }
75 #endif
76 
77 #endif /* JXL_RESIZABLE_PARALLEL_RUNNER_H_ */
78 
JxlParallelRetCode(* JxlParallelRunInit)(void *jpegxl_opaque, size_t num_threads)
Definition: parallel_runner.h:77
int JxlParallelRetCode
Definition: parallel_runner.h:52
void(* JxlParallelRunFunction)(void *jpegxl_opaque, uint32_t value, size_t thread_id)
Definition: parallel_runner.h:95
JXL_THREADS_EXPORT void JxlResizableParallelRunnerDestroy(void *runner_opaque)
JXL_THREADS_EXPORT uint32_t JxlResizableParallelRunnerSuggestThreads(uint64_t xsize, uint64_t ysize)
JXL_THREADS_EXPORT void * JxlResizableParallelRunnerCreate(const JxlMemoryManager *memory_manager)
JXL_THREADS_EXPORT JxlParallelRetCode JxlResizableParallelRunner(void *runner_opaque, void *jpegxl_opaque, JxlParallelRunInit init, JxlParallelRunFunction func, uint32_t start_range, uint32_t end_range)
JXL_THREADS_EXPORT void JxlResizableParallelRunnerSetThreads(void *runner_opaque, size_t num_threads)
Abstraction functions used by JPEG XL to allocate memory.
Definition: memory_manager.h:51