|
| bool | init () |
| |
| bool | isAvailable () |
| |
| struct jpeg_error_mgr * | std_error (struct jpeg_error_mgr *err) |
| |
| void | create_compress (j_compress_ptr cinfo) |
| |
| void | destroy_compress (j_compress_ptr cinfo) |
| |
| void | mem_dest (j_compress_ptr cinfo, unsigned char **outbuffer, unsigned long *outsize) |
| |
| void | set_defaults (j_compress_ptr cinfo) |
| |
| void | set_quality (j_compress_ptr cinfo, int quality, boolean force_baseline) |
| |
| void | suppress_tables (j_compress_ptr cinfo, boolean suppress) |
| |
| void | start_compress (j_compress_ptr cinfo, boolean write_all_tables) |
| |
| JDIMENSION | write_scanlines (j_compress_ptr cinfo, JSAMPARRAY scanlines, JDIMENSION num_lines) |
| |
| JDIMENSION | write_raw_data (j_compress_ptr cinfo, JSAMPIMAGE data, JDIMENSION num_lines) |
| |
| void | finish_compress (j_compress_ptr cinfo) |
| |
| void | set_hardware_acceleration_parameters_enc (j_compress_ptr cinfo, boolean hw_acceleration, unsigned int defaultBuffSize, unsigned int maxBuffSize, unsigned int hwBuffSize) |
| |
| void | create_decompress (j_decompress_ptr cinfo) |
| |
| void | destroy_decompress (j_decompress_ptr cinfo) |
| |
| void | mem_src (j_decompress_ptr cinfo, unsigned char *inbuffer, unsigned long insize) |
| |
| int | read_header (j_decompress_ptr cinfo, boolean require_image) |
| |
| boolean | start_decompress (j_decompress_ptr cinfo) |
| |
| JDIMENSION | read_raw_data (j_decompress_ptr cinfo, JSAMPIMAGE data, JDIMENSION max_lines) |
| |
| boolean | finish_decompress (j_decompress_ptr cinfo) |
| |
L4TMJpegLoader - Dynamic loader for NVIDIA's libnvjpeg.so
This wrapper exists to resolve a symbol conflict between:
- vcpkg's libjpeg-turbo (linked statically, version 62, struct size 520/632)
- NVIDIA's libnvjpeg.so (contains libjpeg version 80, struct size 728/776)
L4TM modules (JPEGEncoderL4TM, JPEGDecoderL4TM) need NVIDIA's extended jpeg structs with fields like image_scale, scaled_image_width, etc.
By using dlopen/dlsym, we bypass the linker's symbol resolution and ensure L4TM code calls the correct NVIDIA implementation.
See: docs/declarative-pipeline/JETSON_KNOWN_ISSUES.md (Issue J1)
Dynamic loader for NVIDIA's libnvjpeg.so
This module resolves the libjpeg version conflict between vcpkg (v62) and NVIDIA's L4T Multimedia API (v80) by dynamically loading functions from libnvjpeg.so at runtime, bypassing the static linker.
The struct sizes differ significantly:
- vcpkg: jpeg_compress_struct=520, jpeg_decompress_struct=632
- NVIDIA: jpeg_compress_struct=728, jpeg_decompress_struct=776
L4TM code compiled with NVIDIA headers uses the larger structs, so we must call libnvjpeg.so's implementation which expects those struct sizes.