mirror of
https://github.com/ddidderr/wuffs.git
synced 2026-11-24 16:52:18 +01:00
Add some #ifndef's to the examples
This commit is contained in:
1 parent
a954e9ad81
commit
d4be1fdf72
2 files changed
+6
No files matched your search
@@ -72,8 +72,12 @@ uint64_t micros_since_start(struct timespec* now) {
|
|||||||
//
|
//
|
||||||
// We keep the whole input in memory, instead of one-pass stream processing,
|
// We keep the whole input in memory, instead of one-pass stream processing,
|
||||||
// because playing a looping animation requires re-winding the input.
|
// because playing a looping animation requires re-winding the input.
|
||||||
|
#ifndef SRC_BUFFER_SIZE
|
||||||
#define SRC_BUFFER_SIZE (64 * 1024 * 1024)
|
#define SRC_BUFFER_SIZE (64 * 1024 * 1024)
|
||||||
|
#endif
|
||||||
|
#ifndef MAX_DIMENSION
|
||||||
#define MAX_DIMENSION (4096)
|
#define MAX_DIMENSION (4096)
|
||||||
|
#endif
|
||||||
|
|
||||||
uint8_t src_buffer[SRC_BUFFER_SIZE] = {0};
|
uint8_t src_buffer[SRC_BUFFER_SIZE] = {0};
|
||||||
size_t src_len = 0;
|
size_t src_len = 0;
|
||||||
|
|||||||
@@ -40,7 +40,9 @@ for a C compiler $CC, such as clang or gcc.
|
|||||||
// it as a "foo.h"-like header, instead of a "foo.c"-like implementation.
|
// it as a "foo.h"-like header, instead of a "foo.c"-like implementation.
|
||||||
#include "wuffs/release/c/wuffs-unsupported-snapshot.c"
|
#include "wuffs/release/c/wuffs-unsupported-snapshot.c"
|
||||||
|
|
||||||
|
#ifndef DST_BUFFER_SIZE
|
||||||
#define DST_BUFFER_SIZE (1024 * 1024)
|
#define DST_BUFFER_SIZE (1024 * 1024)
|
||||||
|
#endif
|
||||||
|
|
||||||
// lgtm_ptr and lgtm_len hold a deflate-encoded "LGTM" message.
|
// lgtm_ptr and lgtm_len hold a deflate-encoded "LGTM" message.
|
||||||
uint8_t lgtm_ptr[] = {
|
uint8_t lgtm_ptr[] = {
|
||||||
|
|||||||
Reference in new issue
Block a user