tree: a59506d75107746050289a1479be97bc34772532 [path history] [tgz]
  1. compression-decoders.md
  2. hashers.md
  3. image-decoders.md
  4. README.md
doc/std/README.md

Standard Library

Wuffs' standard library consists of multiple packages, each implementing a particular file format or algorithm. Those packages can be grouped into several categories:

The general pattern is that a package foo (e.g. jpeg, png) contains a struct bar (e.g. hasher, decoder, etc) that implements a package-independent interface. For example, every compression decoder struct would have a decode_io_writer method. In C, this would be invoked as

// Allocate and initialize the struct.
wuffs_foo__decoder* dec = etc;

// Do the work. Error checking is not shown, for brevity.
const char* status = wuffs_foo__decoder__decode_io_writer(dec, etc);

When that C library is used as C++, that last line can be shortened:

const char* status = dec->decode_io_writer(etc);

See also the glossary, as well as the notes on: