Vips.Dbuf
Description: Reference for Vips.Dbuf

### Struct

# VipsDbuf

#### Description

    struct VipsDbuf {
      /* No available fields */
    }

No description available.

#### Instance methods

###### vips_dbuf_allocate

Make sure `dbuf` has at least `size` bytes available after the write point.

###### vips_dbuf_destroy

Destroy `dbuf`. This frees any allocated memory. Useful for dbufs on the stack.

###### vips_dbuf_get_write

Return a pointer to an area you can write to, return length of area in `size`. Use `vips_dbuf_allocate()` before this call to set a minimum amount of space to have available.

###### vips_dbuf_init

Initialize `dbuf`. You can also just init to zero, eg. `VipsDbuf buf = {0};`.

###### vips_dbuf_minimum_size

Make sure `dbuf` is at least `size` bytes.

###### vips_dbuf_read

Up to `size` bytes are read from the buffer and copied to `data`. The number of bytes transferred is returned.

###### vips_dbuf_reset

Reset the buffer to empty. No memory is freed, just the data size and write point are reset.

###### vips_dbuf_seek

Move the write point. `whence` can be `SEEK_SET`, `SEEK_CUR`, `SEEK_END`, with the usual meaning.

###### vips_dbuf_steal

Destroy a buffer, but rather than freeing memory, a pointer is returned. This must be freed with `g_free()`.

###### vips_dbuf_string

Return a pointer to `dbuf`‘s internal data.

###### vips_dbuf_tell

No description available.

###### vips_dbuf_truncate

Truncate the data so that it ends at the write point. No memory is freed.

###### vips_dbuf_write

Append `size` bytes from `data`. `dbuf` expands if necessary.

###### vips_dbuf_write_amp

Write `str` to `dbuf`, but escape stuff that xml hates in text. Our argument string is utf-8.

###### vips_dbuf_writef

Format the string and write to `dbuf`.