Automatically generated Node.js Foreign Function Interface (FFI) package for libjpeg
v9d. It is meant as a base to build feature-rich packages on top of — without the hassle of writing library bindings and building native dependencies.
libjpeg
: Libjpeg is a widely used C library for reading and writing JPEG image files.
linux-x86_64
Conan package id f2fe22dad08bad39aab2a38cb612e26da46e90c0
.
No library dependencies.
macos-armv8
Conan package id 30acef53c04f36d5f9412c84a1b3a7434a1f10fb
.
No library dependencies.
macos-x86_64
Conan package id ca6b19bf89270552244fca32806dded803132e76
.
No library dependencies.
windows-x86_64
Conan package id 995e0f0b86a651012a3bfca00d60f35ae037db5e
.
No library dependencies.
npm install --save github:node-ffi-libraries/node-ffi-library-libjpeg-v9d#semver:^2.0.1
const { load } = require("@ffi-libraries/libjpeg-v9d");
async function main() {
// Lazy-loading the library and all dependencies.
const library = await load();
// A library might have more than one header file.
console.dir(library);
// Lazy-load an individual header file (random example, see output from above).
const headerLoader = library.headers["./include/jconfig.h"];
const header = await headerLoader();
// You can now use the functions and types exported by the header file.
console.dir(header);
// Properly unload when done.
await library.unload();
}
main();
- Used from Node.js (Javascript) to call the
libjpeg
dynamic library (C/C++).- No compilation required. All available binaries are included in the package and are loaded automatically.
- Library header files are included, but most other documentation is not. See instead documentation for
libjpeg
.
- The
header
variable in the above example contains a Javascript object generated from the C/C++ header file.- C/C++ constants.
- FFI typedefs.
- Bindings to C/C++ functions.
- See the Node.js FFI tutorial to get started.
- Using N-API (
-napi
) versions of FFI libraries is required. - See ffi-napi, ref-napi, and related
-napi
packages.
- Using N-API (
- Repository/package automatically generated by
@ffi-packager/ffi-packager
:- Version: v2.0.1
- Generator run by: Joel Purra
- Repository published to Github:
- Branch:
v2.0.1
- Repository:
node-ffi-library-libjpeg-v9d
- Organization:
node-ffi-libraries
- Branch:
- Package was not published to NPM.
- Version:
2.0.1
(based on the package generator version) - Name:
@ffi-libraries/libjpeg-v9d
- Organization/scope:
ffi-libraries
- Version:
- Library binaries made available by Conan.io:
- Package reference:
libjpeg/9d@
- Conan remote:
conan-center
- Package reference:
- The library is
libjpeg
:- Version: v9d
- Description: "Libjpeg is a widely used C library for reading and writing JPEG image files."
- License: http://ijg.org/files/README
- Topics: image, format, jpg, jpeg, picture, multimedia, graphics
@ffi-libraries/libjpeg-v9d Copyright © 2021 Joel Purra. License: MIT.