Next: bpipe_write_hdr, Previous: bpipe_write_dpkt, Up: BPipe Manipulations
Write several data packets to a binary pipe output channel.
#include <bpipe/bpipe.h>int bpipe_write_dpkts( BPipe *bpipe, void *buf, size_t n_pkts, BPipeOutput *bpo );
BPipe *bpipe
- the binary bpipe to which to write the packets
void *buf
- a pointer to a user-provided memory buffer containing the data packets to be written
size_t n_pkts
- the number of data packets to write
BPipeOutput *bpo
- the output channel to which to write the packets.
bpipe_write_dpkts
writes one or more data packets to a single
binary pipe output channel. Contrast it with
bpipe_write_dpkt
and bpipe_write_dpkt_n
. It must be
called after a call to bpipe_write_hdr
. It converts the
packets' core images into output images. It is more efficient to
call bpipe_write_dpkt
if there is only one data packet to be
written.
It returns zero upon success, non-zero upon failure. Upon failure
bpipe_errno
is set to BPEIOERR
.