LIBJXL
thread_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 
28 #ifndef JXL_THREAD_PARALLEL_RUNNER_H_
29 #define JXL_THREAD_PARALLEL_RUNNER_H_
30 
31 #include <stddef.h>
32 #include <stdint.h>
33 #include <stdio.h>
34 #include <stdlib.h>
35 
36 #include "jxl/jxl_threads_export.h"
37 #include "jxl/memory_manager.h"
38 #include "jxl/parallel_runner.h"
39 
40 #if defined(__cplusplus) || defined(c_plusplus)
41 extern "C" {
42 #endif
43 
47  void* runner_opaque, void* jpegxl_opaque, JxlParallelRunInit init,
48  JxlParallelRunFunction func, uint32_t start_range, uint32_t end_range);
49 
53 JXL_THREADS_EXPORT void* JxlThreadParallelRunnerCreate(
54  const JxlMemoryManager* memory_manager, size_t num_worker_threads);
55 
58 JXL_THREADS_EXPORT void JxlThreadParallelRunnerDestroy(void* runner_opaque);
59 
64 
65 #if defined(__cplusplus) || defined(c_plusplus)
66 }
67 #endif
68 
69 #endif /* JXL_THREAD_PARALLEL_RUNNER_H_ */
JxlParallelRetCode
int JxlParallelRetCode
Definition: parallel_runner.h:49
JxlParallelRunInit
JxlParallelRetCode(* JxlParallelRunInit)(void *jpegxl_opaque, size_t num_threads)
Definition: parallel_runner.h:74
JxlParallelRunFunction
void(* JxlParallelRunFunction)(void *jpegxl_opaque, uint32_t value, size_t thread_id)
Definition: parallel_runner.h:92
JxlThreadParallelRunnerDefaultNumWorkerThreads
JXL_THREADS_EXPORT size_t JxlThreadParallelRunnerDefaultNumWorkerThreads()
JxlThreadParallelRunnerDestroy
JXL_THREADS_EXPORT void JxlThreadParallelRunnerDestroy(void *runner_opaque)
JxlThreadParallelRunner
JXL_THREADS_EXPORT JxlParallelRetCode JxlThreadParallelRunner(void *runner_opaque, void *jpegxl_opaque, JxlParallelRunInit init, JxlParallelRunFunction func, uint32_t start_range, uint32_t end_range)
memory_manager.h
Abstraction functions used by JPEG XL to allocate memory.
JxlMemoryManagerStruct
Definition: memory_manager.h:48
parallel_runner.h
JxlThreadParallelRunnerCreate
JXL_THREADS_EXPORT void * JxlThreadParallelRunnerCreate(const JxlMemoryManager *memory_manager, size_t num_worker_threads)