mirror of
https://github.com/ddidderr/wuffs.git
synced 2026-11-23 08:47:56 +01:00
Add C++ convenience methods
This commit is contained in:
1 parent
60a7b48745
commit
30cfaa5db7
20 files changed
+1444
-229
No files matched your search
+61
-13
@@ -671,23 +671,13 @@ static inline uint32_t wuffs_base__rect_ie_u32__height(
|
||||
|
||||
// ---------------- I/O
|
||||
|
||||
// wuffs_base__io_buffer is a 1-dimensional buffer (a pointer and length), plus
|
||||
// additional indexes into that buffer, plus an opened / closed flag.
|
||||
//
|
||||
// A value with all fields NULL or zero is a valid, empty buffer.
|
||||
typedef struct {
|
||||
uint8_t* ptr; // Pointer.
|
||||
size_t len; // Length.
|
||||
size_t wi; // Write index. Invariant: wi <= len.
|
||||
size_t ri; // Read index. Invariant: ri <= wi.
|
||||
bool closed; // No further writes are expected.
|
||||
} wuffs_base__io_buffer;
|
||||
struct wuffs_base__io_buffer__struct;
|
||||
|
||||
typedef struct {
|
||||
// Do not access the private_impl's fields directly. There is no API/ABI
|
||||
// compatibility or safety guarantee if you do so.
|
||||
struct {
|
||||
wuffs_base__io_buffer* buf;
|
||||
struct wuffs_base__io_buffer__struct* buf;
|
||||
// The bounds values are typically NULL, when created by the Wuffs public
|
||||
// API. NULL means that the callee substitutes the implicit bounds derived
|
||||
// from buf.
|
||||
@@ -699,7 +689,7 @@ typedef struct {
|
||||
// Do not access the private_impl's fields directly. There is no API/ABI
|
||||
// compatibility or safety guarantee if you do so.
|
||||
struct {
|
||||
wuffs_base__io_buffer* buf;
|
||||
struct wuffs_base__io_buffer__struct* buf;
|
||||
// The bounds values are typically NULL, when created by the Wuffs public
|
||||
// API. NULL means that the callee substitutes the implicit bounds derived
|
||||
// from buf.
|
||||
@@ -707,6 +697,25 @@ typedef struct {
|
||||
} private_impl;
|
||||
} wuffs_base__io_writer;
|
||||
|
||||
// wuffs_base__io_buffer is a 1-dimensional buffer (a pointer and length), plus
|
||||
// additional indexes into that buffer, plus an opened / closed flag.
|
||||
//
|
||||
// A value with all fields NULL or zero is a valid, empty buffer.
|
||||
typedef struct wuffs_base__io_buffer__struct {
|
||||
uint8_t* ptr; // Pointer.
|
||||
size_t len; // Length.
|
||||
size_t wi; // Write index. Invariant: wi <= len.
|
||||
size_t ri; // Read index. Invariant: ri <= wi.
|
||||
bool closed; // No further writes are expected.
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void compact();
|
||||
inline wuffs_base__io_reader reader();
|
||||
inline wuffs_base__io_writer writer();
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_base__io_buffer;
|
||||
|
||||
// wuffs_base__io_buffer__compact moves any written but unread bytes to the
|
||||
// start of the buffer.
|
||||
static inline void wuffs_base__io_buffer__compact(wuffs_base__io_buffer* buf) {
|
||||
@@ -735,6 +744,22 @@ static inline wuffs_base__io_writer wuffs_base__io_buffer__writer(
|
||||
return ret;
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_base__io_buffer__struct::compact() {
|
||||
wuffs_base__io_buffer__compact(this);
|
||||
}
|
||||
|
||||
inline wuffs_base__io_reader wuffs_base__io_buffer__struct::reader() {
|
||||
return wuffs_base__io_buffer__reader(this);
|
||||
}
|
||||
|
||||
inline wuffs_base__io_writer wuffs_base__io_buffer__struct::writer() {
|
||||
return wuffs_base__io_buffer__writer(this);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
// ---------------- Images
|
||||
|
||||
// wuffs_base__color_u32argb is an 8 bit per channel Alpha, Red, Green, Blue
|
||||
@@ -1342,6 +1367,13 @@ typedef struct {
|
||||
bool f_started;
|
||||
|
||||
} private_impl;
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version);
|
||||
inline uint32_t update(wuffs_base__slice_u8 a_x);
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_adler32__hasher;
|
||||
|
||||
// ---------------- Public Initializer Prototypes
|
||||
@@ -1360,6 +1392,22 @@ void wuffs_adler32__hasher__check_wuffs_version(wuffs_adler32__hasher* self,
|
||||
uint32_t wuffs_adler32__hasher__update(wuffs_adler32__hasher* self,
|
||||
wuffs_base__slice_u8 a_x);
|
||||
|
||||
// ---------------- C++ Convenience Methods
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_adler32__hasher::check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version) {
|
||||
wuffs_adler32__hasher__check_wuffs_version(this, sizeof_star_self,
|
||||
wuffs_version);
|
||||
}
|
||||
|
||||
inline uint32_t wuffs_adler32__hasher::update(wuffs_base__slice_u8 a_x) {
|
||||
return wuffs_adler32__hasher__update(this, a_x);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
#endif
|
||||
|
||||
+62
-13
@@ -671,23 +671,13 @@ static inline uint32_t wuffs_base__rect_ie_u32__height(
|
||||
|
||||
// ---------------- I/O
|
||||
|
||||
// wuffs_base__io_buffer is a 1-dimensional buffer (a pointer and length), plus
|
||||
// additional indexes into that buffer, plus an opened / closed flag.
|
||||
//
|
||||
// A value with all fields NULL or zero is a valid, empty buffer.
|
||||
typedef struct {
|
||||
uint8_t* ptr; // Pointer.
|
||||
size_t len; // Length.
|
||||
size_t wi; // Write index. Invariant: wi <= len.
|
||||
size_t ri; // Read index. Invariant: ri <= wi.
|
||||
bool closed; // No further writes are expected.
|
||||
} wuffs_base__io_buffer;
|
||||
struct wuffs_base__io_buffer__struct;
|
||||
|
||||
typedef struct {
|
||||
// Do not access the private_impl's fields directly. There is no API/ABI
|
||||
// compatibility or safety guarantee if you do so.
|
||||
struct {
|
||||
wuffs_base__io_buffer* buf;
|
||||
struct wuffs_base__io_buffer__struct* buf;
|
||||
// The bounds values are typically NULL, when created by the Wuffs public
|
||||
// API. NULL means that the callee substitutes the implicit bounds derived
|
||||
// from buf.
|
||||
@@ -699,7 +689,7 @@ typedef struct {
|
||||
// Do not access the private_impl's fields directly. There is no API/ABI
|
||||
// compatibility or safety guarantee if you do so.
|
||||
struct {
|
||||
wuffs_base__io_buffer* buf;
|
||||
struct wuffs_base__io_buffer__struct* buf;
|
||||
// The bounds values are typically NULL, when created by the Wuffs public
|
||||
// API. NULL means that the callee substitutes the implicit bounds derived
|
||||
// from buf.
|
||||
@@ -707,6 +697,25 @@ typedef struct {
|
||||
} private_impl;
|
||||
} wuffs_base__io_writer;
|
||||
|
||||
// wuffs_base__io_buffer is a 1-dimensional buffer (a pointer and length), plus
|
||||
// additional indexes into that buffer, plus an opened / closed flag.
|
||||
//
|
||||
// A value with all fields NULL or zero is a valid, empty buffer.
|
||||
typedef struct wuffs_base__io_buffer__struct {
|
||||
uint8_t* ptr; // Pointer.
|
||||
size_t len; // Length.
|
||||
size_t wi; // Write index. Invariant: wi <= len.
|
||||
size_t ri; // Read index. Invariant: ri <= wi.
|
||||
bool closed; // No further writes are expected.
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void compact();
|
||||
inline wuffs_base__io_reader reader();
|
||||
inline wuffs_base__io_writer writer();
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_base__io_buffer;
|
||||
|
||||
// wuffs_base__io_buffer__compact moves any written but unread bytes to the
|
||||
// start of the buffer.
|
||||
static inline void wuffs_base__io_buffer__compact(wuffs_base__io_buffer* buf) {
|
||||
@@ -735,6 +744,22 @@ static inline wuffs_base__io_writer wuffs_base__io_buffer__writer(
|
||||
return ret;
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_base__io_buffer__struct::compact() {
|
||||
wuffs_base__io_buffer__compact(this);
|
||||
}
|
||||
|
||||
inline wuffs_base__io_reader wuffs_base__io_buffer__struct::reader() {
|
||||
return wuffs_base__io_buffer__reader(this);
|
||||
}
|
||||
|
||||
inline wuffs_base__io_writer wuffs_base__io_buffer__struct::writer() {
|
||||
return wuffs_base__io_buffer__writer(this);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
// ---------------- Images
|
||||
|
||||
// wuffs_base__color_u32argb is an 8 bit per channel Alpha, Red, Green, Blue
|
||||
@@ -1341,6 +1366,13 @@ typedef struct {
|
||||
uint32_t f_state;
|
||||
|
||||
} private_impl;
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version);
|
||||
inline uint32_t update(wuffs_base__slice_u8 a_x);
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_crc32__ieee_hasher;
|
||||
|
||||
// ---------------- Public Initializer Prototypes
|
||||
@@ -1360,6 +1392,23 @@ void wuffs_crc32__ieee_hasher__check_wuffs_version(
|
||||
uint32_t wuffs_crc32__ieee_hasher__update(wuffs_crc32__ieee_hasher* self,
|
||||
wuffs_base__slice_u8 a_x);
|
||||
|
||||
// ---------------- C++ Convenience Methods
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_crc32__ieee_hasher::check_wuffs_version(
|
||||
size_t sizeof_star_self,
|
||||
uint64_t wuffs_version) {
|
||||
wuffs_crc32__ieee_hasher__check_wuffs_version(this, sizeof_star_self,
|
||||
wuffs_version);
|
||||
}
|
||||
|
||||
inline uint32_t wuffs_crc32__ieee_hasher::update(wuffs_base__slice_u8 a_x) {
|
||||
return wuffs_crc32__ieee_hasher__update(this, a_x);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
#endif
|
||||
|
||||
+65
-13
@@ -671,23 +671,13 @@ static inline uint32_t wuffs_base__rect_ie_u32__height(
|
||||
|
||||
// ---------------- I/O
|
||||
|
||||
// wuffs_base__io_buffer is a 1-dimensional buffer (a pointer and length), plus
|
||||
// additional indexes into that buffer, plus an opened / closed flag.
|
||||
//
|
||||
// A value with all fields NULL or zero is a valid, empty buffer.
|
||||
typedef struct {
|
||||
uint8_t* ptr; // Pointer.
|
||||
size_t len; // Length.
|
||||
size_t wi; // Write index. Invariant: wi <= len.
|
||||
size_t ri; // Read index. Invariant: ri <= wi.
|
||||
bool closed; // No further writes are expected.
|
||||
} wuffs_base__io_buffer;
|
||||
struct wuffs_base__io_buffer__struct;
|
||||
|
||||
typedef struct {
|
||||
// Do not access the private_impl's fields directly. There is no API/ABI
|
||||
// compatibility or safety guarantee if you do so.
|
||||
struct {
|
||||
wuffs_base__io_buffer* buf;
|
||||
struct wuffs_base__io_buffer__struct* buf;
|
||||
// The bounds values are typically NULL, when created by the Wuffs public
|
||||
// API. NULL means that the callee substitutes the implicit bounds derived
|
||||
// from buf.
|
||||
@@ -699,7 +689,7 @@ typedef struct {
|
||||
// Do not access the private_impl's fields directly. There is no API/ABI
|
||||
// compatibility or safety guarantee if you do so.
|
||||
struct {
|
||||
wuffs_base__io_buffer* buf;
|
||||
struct wuffs_base__io_buffer__struct* buf;
|
||||
// The bounds values are typically NULL, when created by the Wuffs public
|
||||
// API. NULL means that the callee substitutes the implicit bounds derived
|
||||
// from buf.
|
||||
@@ -707,6 +697,25 @@ typedef struct {
|
||||
} private_impl;
|
||||
} wuffs_base__io_writer;
|
||||
|
||||
// wuffs_base__io_buffer is a 1-dimensional buffer (a pointer and length), plus
|
||||
// additional indexes into that buffer, plus an opened / closed flag.
|
||||
//
|
||||
// A value with all fields NULL or zero is a valid, empty buffer.
|
||||
typedef struct wuffs_base__io_buffer__struct {
|
||||
uint8_t* ptr; // Pointer.
|
||||
size_t len; // Length.
|
||||
size_t wi; // Write index. Invariant: wi <= len.
|
||||
size_t ri; // Read index. Invariant: ri <= wi.
|
||||
bool closed; // No further writes are expected.
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void compact();
|
||||
inline wuffs_base__io_reader reader();
|
||||
inline wuffs_base__io_writer writer();
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_base__io_buffer;
|
||||
|
||||
// wuffs_base__io_buffer__compact moves any written but unread bytes to the
|
||||
// start of the buffer.
|
||||
static inline void wuffs_base__io_buffer__compact(wuffs_base__io_buffer* buf) {
|
||||
@@ -735,6 +744,22 @@ static inline wuffs_base__io_writer wuffs_base__io_buffer__writer(
|
||||
return ret;
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_base__io_buffer__struct::compact() {
|
||||
wuffs_base__io_buffer__compact(this);
|
||||
}
|
||||
|
||||
inline wuffs_base__io_reader wuffs_base__io_buffer__struct::reader() {
|
||||
return wuffs_base__io_buffer__reader(this);
|
||||
}
|
||||
|
||||
inline wuffs_base__io_writer wuffs_base__io_buffer__struct::writer() {
|
||||
return wuffs_base__io_buffer__writer(this);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
// ---------------- Images
|
||||
|
||||
// wuffs_base__color_u32argb is an 8 bit per channel Alpha, Red, Green, Blue
|
||||
@@ -1429,6 +1454,14 @@ typedef struct {
|
||||
uint32_t v_hdist;
|
||||
} c_decode_huffman_slow[1];
|
||||
} private_impl;
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version);
|
||||
inline wuffs_base__status decode(wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src);
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_deflate__decoder;
|
||||
|
||||
// ---------------- Public Initializer Prototypes
|
||||
@@ -1448,6 +1481,25 @@ wuffs_base__status wuffs_deflate__decoder__decode(wuffs_deflate__decoder* self,
|
||||
wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src);
|
||||
|
||||
// ---------------- C++ Convenience Methods
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_deflate__decoder::check_wuffs_version(
|
||||
size_t sizeof_star_self,
|
||||
uint64_t wuffs_version) {
|
||||
wuffs_deflate__decoder__check_wuffs_version(this, sizeof_star_self,
|
||||
wuffs_version);
|
||||
}
|
||||
|
||||
inline wuffs_base__status wuffs_deflate__decoder::decode(
|
||||
wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src) {
|
||||
return wuffs_deflate__decoder__decode(this, a_dst, a_src);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
#endif
|
||||
|
||||
+121
-13
@@ -671,23 +671,13 @@ static inline uint32_t wuffs_base__rect_ie_u32__height(
|
||||
|
||||
// ---------------- I/O
|
||||
|
||||
// wuffs_base__io_buffer is a 1-dimensional buffer (a pointer and length), plus
|
||||
// additional indexes into that buffer, plus an opened / closed flag.
|
||||
//
|
||||
// A value with all fields NULL or zero is a valid, empty buffer.
|
||||
typedef struct {
|
||||
uint8_t* ptr; // Pointer.
|
||||
size_t len; // Length.
|
||||
size_t wi; // Write index. Invariant: wi <= len.
|
||||
size_t ri; // Read index. Invariant: ri <= wi.
|
||||
bool closed; // No further writes are expected.
|
||||
} wuffs_base__io_buffer;
|
||||
struct wuffs_base__io_buffer__struct;
|
||||
|
||||
typedef struct {
|
||||
// Do not access the private_impl's fields directly. There is no API/ABI
|
||||
// compatibility or safety guarantee if you do so.
|
||||
struct {
|
||||
wuffs_base__io_buffer* buf;
|
||||
struct wuffs_base__io_buffer__struct* buf;
|
||||
// The bounds values are typically NULL, when created by the Wuffs public
|
||||
// API. NULL means that the callee substitutes the implicit bounds derived
|
||||
// from buf.
|
||||
@@ -699,7 +689,7 @@ typedef struct {
|
||||
// Do not access the private_impl's fields directly. There is no API/ABI
|
||||
// compatibility or safety guarantee if you do so.
|
||||
struct {
|
||||
wuffs_base__io_buffer* buf;
|
||||
struct wuffs_base__io_buffer__struct* buf;
|
||||
// The bounds values are typically NULL, when created by the Wuffs public
|
||||
// API. NULL means that the callee substitutes the implicit bounds derived
|
||||
// from buf.
|
||||
@@ -707,6 +697,25 @@ typedef struct {
|
||||
} private_impl;
|
||||
} wuffs_base__io_writer;
|
||||
|
||||
// wuffs_base__io_buffer is a 1-dimensional buffer (a pointer and length), plus
|
||||
// additional indexes into that buffer, plus an opened / closed flag.
|
||||
//
|
||||
// A value with all fields NULL or zero is a valid, empty buffer.
|
||||
typedef struct wuffs_base__io_buffer__struct {
|
||||
uint8_t* ptr; // Pointer.
|
||||
size_t len; // Length.
|
||||
size_t wi; // Write index. Invariant: wi <= len.
|
||||
size_t ri; // Read index. Invariant: ri <= wi.
|
||||
bool closed; // No further writes are expected.
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void compact();
|
||||
inline wuffs_base__io_reader reader();
|
||||
inline wuffs_base__io_writer writer();
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_base__io_buffer;
|
||||
|
||||
// wuffs_base__io_buffer__compact moves any written but unread bytes to the
|
||||
// start of the buffer.
|
||||
static inline void wuffs_base__io_buffer__compact(wuffs_base__io_buffer* buf) {
|
||||
@@ -735,6 +744,22 @@ static inline wuffs_base__io_writer wuffs_base__io_buffer__writer(
|
||||
return ret;
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_base__io_buffer__struct::compact() {
|
||||
wuffs_base__io_buffer__compact(this);
|
||||
}
|
||||
|
||||
inline wuffs_base__io_reader wuffs_base__io_buffer__struct::reader() {
|
||||
return wuffs_base__io_buffer__reader(this);
|
||||
}
|
||||
|
||||
inline wuffs_base__io_writer wuffs_base__io_buffer__struct::writer() {
|
||||
return wuffs_base__io_buffer__writer(this);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
// ---------------- Images
|
||||
|
||||
// wuffs_base__color_u32argb is an 8 bit per channel Alpha, Red, Green, Blue
|
||||
@@ -1371,6 +1396,15 @@ typedef struct {
|
||||
uint64_t v_n_copied;
|
||||
} c_decode[1];
|
||||
} private_impl;
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version);
|
||||
inline void set_literal_width(uint32_t a_lw);
|
||||
inline wuffs_base__status decode(wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src);
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_lzw__decoder;
|
||||
|
||||
// ---------------- Public Initializer Prototypes
|
||||
@@ -1393,6 +1427,28 @@ wuffs_base__status wuffs_lzw__decoder__decode(wuffs_lzw__decoder* self,
|
||||
wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src);
|
||||
|
||||
// ---------------- C++ Convenience Methods
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_lzw__decoder::check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version) {
|
||||
wuffs_lzw__decoder__check_wuffs_version(this, sizeof_star_self,
|
||||
wuffs_version);
|
||||
}
|
||||
|
||||
inline void wuffs_lzw__decoder::set_literal_width(uint32_t a_lw) {
|
||||
return wuffs_lzw__decoder__set_literal_width(this, a_lw);
|
||||
}
|
||||
|
||||
inline wuffs_base__status wuffs_lzw__decoder::decode(
|
||||
wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src) {
|
||||
return wuffs_lzw__decoder__decode(this, a_dst, a_src);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
#endif
|
||||
@@ -1530,6 +1586,20 @@ typedef struct {
|
||||
wuffs_base__status v_z;
|
||||
} c_decode_id_part1[1];
|
||||
} private_impl;
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version);
|
||||
inline wuffs_base__status decode_config(wuffs_base__image_config* a_dst,
|
||||
wuffs_base__io_reader a_src);
|
||||
inline uint64_t frame_count();
|
||||
inline wuffs_base__range_ii_u64 work_buffer_size();
|
||||
inline wuffs_base__status decode_frame(wuffs_base__image_buffer* a_dst,
|
||||
wuffs_base__io_reader a_src,
|
||||
wuffs_base__slice_u8 a_work_buffer);
|
||||
inline wuffs_base__status decode_up_to_id_part1(wuffs_base__io_reader a_src);
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_gif__decoder;
|
||||
|
||||
// ---------------- Public Initializer Prototypes
|
||||
@@ -1565,6 +1635,44 @@ wuffs_base__status wuffs_gif__decoder__decode_up_to_id_part1(
|
||||
wuffs_gif__decoder* self,
|
||||
wuffs_base__io_reader a_src);
|
||||
|
||||
// ---------------- C++ Convenience Methods
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_gif__decoder::check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version) {
|
||||
wuffs_gif__decoder__check_wuffs_version(this, sizeof_star_self,
|
||||
wuffs_version);
|
||||
}
|
||||
|
||||
inline wuffs_base__status wuffs_gif__decoder::decode_config(
|
||||
wuffs_base__image_config* a_dst,
|
||||
wuffs_base__io_reader a_src) {
|
||||
return wuffs_gif__decoder__decode_config(this, a_dst, a_src);
|
||||
}
|
||||
|
||||
inline uint64_t wuffs_gif__decoder::frame_count() {
|
||||
return wuffs_gif__decoder__frame_count(this);
|
||||
}
|
||||
|
||||
inline wuffs_base__range_ii_u64 wuffs_gif__decoder::work_buffer_size() {
|
||||
return wuffs_gif__decoder__work_buffer_size(this);
|
||||
}
|
||||
|
||||
inline wuffs_base__status wuffs_gif__decoder::decode_frame(
|
||||
wuffs_base__image_buffer* a_dst,
|
||||
wuffs_base__io_reader a_src,
|
||||
wuffs_base__slice_u8 a_work_buffer) {
|
||||
return wuffs_gif__decoder__decode_frame(this, a_dst, a_src, a_work_buffer);
|
||||
}
|
||||
|
||||
inline wuffs_base__status wuffs_gif__decoder::decode_up_to_id_part1(
|
||||
wuffs_base__io_reader a_src) {
|
||||
return wuffs_gif__decoder__decode_up_to_id_part1(this, a_src);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
#endif
|
||||
|
||||
+120
-13
@@ -671,23 +671,13 @@ static inline uint32_t wuffs_base__rect_ie_u32__height(
|
||||
|
||||
// ---------------- I/O
|
||||
|
||||
// wuffs_base__io_buffer is a 1-dimensional buffer (a pointer and length), plus
|
||||
// additional indexes into that buffer, plus an opened / closed flag.
|
||||
//
|
||||
// A value with all fields NULL or zero is a valid, empty buffer.
|
||||
typedef struct {
|
||||
uint8_t* ptr; // Pointer.
|
||||
size_t len; // Length.
|
||||
size_t wi; // Write index. Invariant: wi <= len.
|
||||
size_t ri; // Read index. Invariant: ri <= wi.
|
||||
bool closed; // No further writes are expected.
|
||||
} wuffs_base__io_buffer;
|
||||
struct wuffs_base__io_buffer__struct;
|
||||
|
||||
typedef struct {
|
||||
// Do not access the private_impl's fields directly. There is no API/ABI
|
||||
// compatibility or safety guarantee if you do so.
|
||||
struct {
|
||||
wuffs_base__io_buffer* buf;
|
||||
struct wuffs_base__io_buffer__struct* buf;
|
||||
// The bounds values are typically NULL, when created by the Wuffs public
|
||||
// API. NULL means that the callee substitutes the implicit bounds derived
|
||||
// from buf.
|
||||
@@ -699,7 +689,7 @@ typedef struct {
|
||||
// Do not access the private_impl's fields directly. There is no API/ABI
|
||||
// compatibility or safety guarantee if you do so.
|
||||
struct {
|
||||
wuffs_base__io_buffer* buf;
|
||||
struct wuffs_base__io_buffer__struct* buf;
|
||||
// The bounds values are typically NULL, when created by the Wuffs public
|
||||
// API. NULL means that the callee substitutes the implicit bounds derived
|
||||
// from buf.
|
||||
@@ -707,6 +697,25 @@ typedef struct {
|
||||
} private_impl;
|
||||
} wuffs_base__io_writer;
|
||||
|
||||
// wuffs_base__io_buffer is a 1-dimensional buffer (a pointer and length), plus
|
||||
// additional indexes into that buffer, plus an opened / closed flag.
|
||||
//
|
||||
// A value with all fields NULL or zero is a valid, empty buffer.
|
||||
typedef struct wuffs_base__io_buffer__struct {
|
||||
uint8_t* ptr; // Pointer.
|
||||
size_t len; // Length.
|
||||
size_t wi; // Write index. Invariant: wi <= len.
|
||||
size_t ri; // Read index. Invariant: ri <= wi.
|
||||
bool closed; // No further writes are expected.
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void compact();
|
||||
inline wuffs_base__io_reader reader();
|
||||
inline wuffs_base__io_writer writer();
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_base__io_buffer;
|
||||
|
||||
// wuffs_base__io_buffer__compact moves any written but unread bytes to the
|
||||
// start of the buffer.
|
||||
static inline void wuffs_base__io_buffer__compact(wuffs_base__io_buffer* buf) {
|
||||
@@ -735,6 +744,22 @@ static inline wuffs_base__io_writer wuffs_base__io_buffer__writer(
|
||||
return ret;
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_base__io_buffer__struct::compact() {
|
||||
wuffs_base__io_buffer__compact(this);
|
||||
}
|
||||
|
||||
inline wuffs_base__io_reader wuffs_base__io_buffer__struct::reader() {
|
||||
return wuffs_base__io_buffer__reader(this);
|
||||
}
|
||||
|
||||
inline wuffs_base__io_writer wuffs_base__io_buffer__struct::writer() {
|
||||
return wuffs_base__io_buffer__writer(this);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
// ---------------- Images
|
||||
|
||||
// wuffs_base__color_u32argb is an 8 bit per channel Alpha, Red, Green, Blue
|
||||
@@ -1350,6 +1375,13 @@ typedef struct {
|
||||
uint32_t f_state;
|
||||
|
||||
} private_impl;
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version);
|
||||
inline uint32_t update(wuffs_base__slice_u8 a_x);
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_crc32__ieee_hasher;
|
||||
|
||||
// ---------------- Public Initializer Prototypes
|
||||
@@ -1369,6 +1401,23 @@ void wuffs_crc32__ieee_hasher__check_wuffs_version(
|
||||
uint32_t wuffs_crc32__ieee_hasher__update(wuffs_crc32__ieee_hasher* self,
|
||||
wuffs_base__slice_u8 a_x);
|
||||
|
||||
// ---------------- C++ Convenience Methods
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_crc32__ieee_hasher::check_wuffs_version(
|
||||
size_t sizeof_star_self,
|
||||
uint64_t wuffs_version) {
|
||||
wuffs_crc32__ieee_hasher__check_wuffs_version(this, sizeof_star_self,
|
||||
wuffs_version);
|
||||
}
|
||||
|
||||
inline uint32_t wuffs_crc32__ieee_hasher::update(wuffs_base__slice_u8 a_x) {
|
||||
return wuffs_crc32__ieee_hasher__update(this, a_x);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
#endif
|
||||
@@ -1503,6 +1552,14 @@ typedef struct {
|
||||
uint32_t v_hdist;
|
||||
} c_decode_huffman_slow[1];
|
||||
} private_impl;
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version);
|
||||
inline wuffs_base__status decode(wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src);
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_deflate__decoder;
|
||||
|
||||
// ---------------- Public Initializer Prototypes
|
||||
@@ -1522,6 +1579,25 @@ wuffs_base__status wuffs_deflate__decoder__decode(wuffs_deflate__decoder* self,
|
||||
wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src);
|
||||
|
||||
// ---------------- C++ Convenience Methods
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_deflate__decoder::check_wuffs_version(
|
||||
size_t sizeof_star_self,
|
||||
uint64_t wuffs_version) {
|
||||
wuffs_deflate__decoder__check_wuffs_version(this, sizeof_star_self,
|
||||
wuffs_version);
|
||||
}
|
||||
|
||||
inline wuffs_base__status wuffs_deflate__decoder::decode(
|
||||
wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src) {
|
||||
return wuffs_deflate__decoder__decode(this, a_dst, a_src);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
#endif
|
||||
@@ -1578,6 +1654,15 @@ typedef struct {
|
||||
uint64_t scratch;
|
||||
} c_decode[1];
|
||||
} private_impl;
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version);
|
||||
inline void set_ignore_checksum(bool a_ic);
|
||||
inline wuffs_base__status decode(wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src);
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_gzip__decoder;
|
||||
|
||||
// ---------------- Public Initializer Prototypes
|
||||
@@ -1600,6 +1685,28 @@ wuffs_base__status wuffs_gzip__decoder__decode(wuffs_gzip__decoder* self,
|
||||
wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src);
|
||||
|
||||
// ---------------- C++ Convenience Methods
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_gzip__decoder::check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version) {
|
||||
wuffs_gzip__decoder__check_wuffs_version(this, sizeof_star_self,
|
||||
wuffs_version);
|
||||
}
|
||||
|
||||
inline void wuffs_gzip__decoder::set_ignore_checksum(bool a_ic) {
|
||||
return wuffs_gzip__decoder__set_ignore_checksum(this, a_ic);
|
||||
}
|
||||
|
||||
inline wuffs_base__status wuffs_gzip__decoder::decode(
|
||||
wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src) {
|
||||
return wuffs_gzip__decoder__decode(this, a_dst, a_src);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
#endif
|
||||
|
||||
+69
-13
@@ -671,23 +671,13 @@ static inline uint32_t wuffs_base__rect_ie_u32__height(
|
||||
|
||||
// ---------------- I/O
|
||||
|
||||
// wuffs_base__io_buffer is a 1-dimensional buffer (a pointer and length), plus
|
||||
// additional indexes into that buffer, plus an opened / closed flag.
|
||||
//
|
||||
// A value with all fields NULL or zero is a valid, empty buffer.
|
||||
typedef struct {
|
||||
uint8_t* ptr; // Pointer.
|
||||
size_t len; // Length.
|
||||
size_t wi; // Write index. Invariant: wi <= len.
|
||||
size_t ri; // Read index. Invariant: ri <= wi.
|
||||
bool closed; // No further writes are expected.
|
||||
} wuffs_base__io_buffer;
|
||||
struct wuffs_base__io_buffer__struct;
|
||||
|
||||
typedef struct {
|
||||
// Do not access the private_impl's fields directly. There is no API/ABI
|
||||
// compatibility or safety guarantee if you do so.
|
||||
struct {
|
||||
wuffs_base__io_buffer* buf;
|
||||
struct wuffs_base__io_buffer__struct* buf;
|
||||
// The bounds values are typically NULL, when created by the Wuffs public
|
||||
// API. NULL means that the callee substitutes the implicit bounds derived
|
||||
// from buf.
|
||||
@@ -699,7 +689,7 @@ typedef struct {
|
||||
// Do not access the private_impl's fields directly. There is no API/ABI
|
||||
// compatibility or safety guarantee if you do so.
|
||||
struct {
|
||||
wuffs_base__io_buffer* buf;
|
||||
struct wuffs_base__io_buffer__struct* buf;
|
||||
// The bounds values are typically NULL, when created by the Wuffs public
|
||||
// API. NULL means that the callee substitutes the implicit bounds derived
|
||||
// from buf.
|
||||
@@ -707,6 +697,25 @@ typedef struct {
|
||||
} private_impl;
|
||||
} wuffs_base__io_writer;
|
||||
|
||||
// wuffs_base__io_buffer is a 1-dimensional buffer (a pointer and length), plus
|
||||
// additional indexes into that buffer, plus an opened / closed flag.
|
||||
//
|
||||
// A value with all fields NULL or zero is a valid, empty buffer.
|
||||
typedef struct wuffs_base__io_buffer__struct {
|
||||
uint8_t* ptr; // Pointer.
|
||||
size_t len; // Length.
|
||||
size_t wi; // Write index. Invariant: wi <= len.
|
||||
size_t ri; // Read index. Invariant: ri <= wi.
|
||||
bool closed; // No further writes are expected.
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void compact();
|
||||
inline wuffs_base__io_reader reader();
|
||||
inline wuffs_base__io_writer writer();
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_base__io_buffer;
|
||||
|
||||
// wuffs_base__io_buffer__compact moves any written but unread bytes to the
|
||||
// start of the buffer.
|
||||
static inline void wuffs_base__io_buffer__compact(wuffs_base__io_buffer* buf) {
|
||||
@@ -735,6 +744,22 @@ static inline wuffs_base__io_writer wuffs_base__io_buffer__writer(
|
||||
return ret;
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_base__io_buffer__struct::compact() {
|
||||
wuffs_base__io_buffer__compact(this);
|
||||
}
|
||||
|
||||
inline wuffs_base__io_reader wuffs_base__io_buffer__struct::reader() {
|
||||
return wuffs_base__io_buffer__reader(this);
|
||||
}
|
||||
|
||||
inline wuffs_base__io_writer wuffs_base__io_buffer__struct::writer() {
|
||||
return wuffs_base__io_buffer__writer(this);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
// ---------------- Images
|
||||
|
||||
// wuffs_base__color_u32argb is an 8 bit per channel Alpha, Red, Green, Blue
|
||||
@@ -1362,6 +1387,15 @@ typedef struct {
|
||||
uint64_t v_n_copied;
|
||||
} c_decode[1];
|
||||
} private_impl;
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version);
|
||||
inline void set_literal_width(uint32_t a_lw);
|
||||
inline wuffs_base__status decode(wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src);
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_lzw__decoder;
|
||||
|
||||
// ---------------- Public Initializer Prototypes
|
||||
@@ -1384,6 +1418,28 @@ wuffs_base__status wuffs_lzw__decoder__decode(wuffs_lzw__decoder* self,
|
||||
wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src);
|
||||
|
||||
// ---------------- C++ Convenience Methods
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_lzw__decoder::check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version) {
|
||||
wuffs_lzw__decoder__check_wuffs_version(this, sizeof_star_self,
|
||||
wuffs_version);
|
||||
}
|
||||
|
||||
inline void wuffs_lzw__decoder::set_literal_width(uint32_t a_lw) {
|
||||
return wuffs_lzw__decoder__set_literal_width(this, a_lw);
|
||||
}
|
||||
|
||||
inline wuffs_base__status wuffs_lzw__decoder::decode(
|
||||
wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src) {
|
||||
return wuffs_lzw__decoder__decode(this, a_dst, a_src);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
#endif
|
||||
|
||||
+119
-13
@@ -671,23 +671,13 @@ static inline uint32_t wuffs_base__rect_ie_u32__height(
|
||||
|
||||
// ---------------- I/O
|
||||
|
||||
// wuffs_base__io_buffer is a 1-dimensional buffer (a pointer and length), plus
|
||||
// additional indexes into that buffer, plus an opened / closed flag.
|
||||
//
|
||||
// A value with all fields NULL or zero is a valid, empty buffer.
|
||||
typedef struct {
|
||||
uint8_t* ptr; // Pointer.
|
||||
size_t len; // Length.
|
||||
size_t wi; // Write index. Invariant: wi <= len.
|
||||
size_t ri; // Read index. Invariant: ri <= wi.
|
||||
bool closed; // No further writes are expected.
|
||||
} wuffs_base__io_buffer;
|
||||
struct wuffs_base__io_buffer__struct;
|
||||
|
||||
typedef struct {
|
||||
// Do not access the private_impl's fields directly. There is no API/ABI
|
||||
// compatibility or safety guarantee if you do so.
|
||||
struct {
|
||||
wuffs_base__io_buffer* buf;
|
||||
struct wuffs_base__io_buffer__struct* buf;
|
||||
// The bounds values are typically NULL, when created by the Wuffs public
|
||||
// API. NULL means that the callee substitutes the implicit bounds derived
|
||||
// from buf.
|
||||
@@ -699,7 +689,7 @@ typedef struct {
|
||||
// Do not access the private_impl's fields directly. There is no API/ABI
|
||||
// compatibility or safety guarantee if you do so.
|
||||
struct {
|
||||
wuffs_base__io_buffer* buf;
|
||||
struct wuffs_base__io_buffer__struct* buf;
|
||||
// The bounds values are typically NULL, when created by the Wuffs public
|
||||
// API. NULL means that the callee substitutes the implicit bounds derived
|
||||
// from buf.
|
||||
@@ -707,6 +697,25 @@ typedef struct {
|
||||
} private_impl;
|
||||
} wuffs_base__io_writer;
|
||||
|
||||
// wuffs_base__io_buffer is a 1-dimensional buffer (a pointer and length), plus
|
||||
// additional indexes into that buffer, plus an opened / closed flag.
|
||||
//
|
||||
// A value with all fields NULL or zero is a valid, empty buffer.
|
||||
typedef struct wuffs_base__io_buffer__struct {
|
||||
uint8_t* ptr; // Pointer.
|
||||
size_t len; // Length.
|
||||
size_t wi; // Write index. Invariant: wi <= len.
|
||||
size_t ri; // Read index. Invariant: ri <= wi.
|
||||
bool closed; // No further writes are expected.
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void compact();
|
||||
inline wuffs_base__io_reader reader();
|
||||
inline wuffs_base__io_writer writer();
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_base__io_buffer;
|
||||
|
||||
// wuffs_base__io_buffer__compact moves any written but unread bytes to the
|
||||
// start of the buffer.
|
||||
static inline void wuffs_base__io_buffer__compact(wuffs_base__io_buffer* buf) {
|
||||
@@ -735,6 +744,22 @@ static inline wuffs_base__io_writer wuffs_base__io_buffer__writer(
|
||||
return ret;
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_base__io_buffer__struct::compact() {
|
||||
wuffs_base__io_buffer__compact(this);
|
||||
}
|
||||
|
||||
inline wuffs_base__io_reader wuffs_base__io_buffer__struct::reader() {
|
||||
return wuffs_base__io_buffer__reader(this);
|
||||
}
|
||||
|
||||
inline wuffs_base__io_writer wuffs_base__io_buffer__struct::writer() {
|
||||
return wuffs_base__io_buffer__writer(this);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
// ---------------- Images
|
||||
|
||||
// wuffs_base__color_u32argb is an 8 bit per channel Alpha, Red, Green, Blue
|
||||
@@ -1351,6 +1376,13 @@ typedef struct {
|
||||
bool f_started;
|
||||
|
||||
} private_impl;
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version);
|
||||
inline uint32_t update(wuffs_base__slice_u8 a_x);
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_adler32__hasher;
|
||||
|
||||
// ---------------- Public Initializer Prototypes
|
||||
@@ -1369,6 +1401,22 @@ void wuffs_adler32__hasher__check_wuffs_version(wuffs_adler32__hasher* self,
|
||||
uint32_t wuffs_adler32__hasher__update(wuffs_adler32__hasher* self,
|
||||
wuffs_base__slice_u8 a_x);
|
||||
|
||||
// ---------------- C++ Convenience Methods
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_adler32__hasher::check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version) {
|
||||
wuffs_adler32__hasher__check_wuffs_version(this, sizeof_star_self,
|
||||
wuffs_version);
|
||||
}
|
||||
|
||||
inline uint32_t wuffs_adler32__hasher::update(wuffs_base__slice_u8 a_x) {
|
||||
return wuffs_adler32__hasher__update(this, a_x);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
#endif
|
||||
@@ -1503,6 +1551,14 @@ typedef struct {
|
||||
uint32_t v_hdist;
|
||||
} c_decode_huffman_slow[1];
|
||||
} private_impl;
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version);
|
||||
inline wuffs_base__status decode(wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src);
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_deflate__decoder;
|
||||
|
||||
// ---------------- Public Initializer Prototypes
|
||||
@@ -1522,6 +1578,25 @@ wuffs_base__status wuffs_deflate__decoder__decode(wuffs_deflate__decoder* self,
|
||||
wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src);
|
||||
|
||||
// ---------------- C++ Convenience Methods
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_deflate__decoder::check_wuffs_version(
|
||||
size_t sizeof_star_self,
|
||||
uint64_t wuffs_version) {
|
||||
wuffs_deflate__decoder__check_wuffs_version(this, sizeof_star_self,
|
||||
wuffs_version);
|
||||
}
|
||||
|
||||
inline wuffs_base__status wuffs_deflate__decoder::decode(
|
||||
wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src) {
|
||||
return wuffs_deflate__decoder__decode(this, a_dst, a_src);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
#endif
|
||||
@@ -1576,6 +1651,15 @@ typedef struct {
|
||||
uint64_t scratch;
|
||||
} c_decode[1];
|
||||
} private_impl;
|
||||
|
||||
#ifdef __cplusplus
|
||||
inline void check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version);
|
||||
inline void set_ignore_checksum(bool a_ic);
|
||||
inline wuffs_base__status decode(wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src);
|
||||
#endif // __cplusplus
|
||||
|
||||
} wuffs_zlib__decoder;
|
||||
|
||||
// ---------------- Public Initializer Prototypes
|
||||
@@ -1598,6 +1682,28 @@ wuffs_base__status wuffs_zlib__decoder__decode(wuffs_zlib__decoder* self,
|
||||
wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src);
|
||||
|
||||
// ---------------- C++ Convenience Methods
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
inline void wuffs_zlib__decoder::check_wuffs_version(size_t sizeof_star_self,
|
||||
uint64_t wuffs_version) {
|
||||
wuffs_zlib__decoder__check_wuffs_version(this, sizeof_star_self,
|
||||
wuffs_version);
|
||||
}
|
||||
|
||||
inline void wuffs_zlib__decoder::set_ignore_checksum(bool a_ic) {
|
||||
return wuffs_zlib__decoder__set_ignore_checksum(this, a_ic);
|
||||
}
|
||||
|
||||
inline wuffs_base__status wuffs_zlib__decoder::decode(
|
||||
wuffs_base__io_writer a_dst,
|
||||
wuffs_base__io_reader a_src) {
|
||||
return wuffs_zlib__decoder__decode(this, a_dst, a_src);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
#endif
|
||||
|
||||
Reference in new issue
Block a user