Back to Aurora Vision Library Lite website

You are here: Start » All Functions » Binary Data » WriteBufferToBuffer

WriteBufferToBuffer


This is Filter Equivalent. This function may be present in generated code, but should not be used in hand-written code.

Header: STD.h
Namespace: avl

Writes content of a source byte buffer into other byte buffer.

Syntax

void avl::WriteBufferToBuffer
(
	const avl::ByteBuffer& inBuffer,
	atl::Optional<int> inOffset,
	const avl::ByteBuffer& inSourceBuffer,
	int inSourceOffset,
	atl::Optional<int> inSourceLength,
	avl::ByteBuffer& outBuffer
)

Parameters

Name Type Range Default Description
Input value inBuffer const ByteBuffer& Initial buffer to be expanded
Input value inOffset Optional<int> 0 - NIL Write destination position
Input value inSourceBuffer const ByteBuffer& Buffer containing source data to be copied
Input value inSourceOffset int 0 - 0 Copy start position in source data
Input value inSourceLength Optional<int> 0 - NIL Length of data to be copied in bytes
Output value outBuffer ByteBuffer& Resulting data

In-place Processing

This function supports in-place data processing - you can pass the same reference to inBuffer and outBuffer

Read more about In-place Computation.

Description

This filter is intended for transferring raw binary data between byte buffers.

Source data is acquired from the buffer at the inSourceBuffer input, starting at the position determined by the inSourceOffset input (in bytes) and limited to the length determined by the inSourceLength input. When the inSourceLength input is set to Auto source data is read from the start position up to the end of inSourceBuffer.

Resulting ByteBuffer data on the outBuffer output is created by expanding data from buffer on the inBuffer input. Data is written starting at the position specified by the inOffset input (in bytes). When written data spans beyond the end of the input buffer the resulting buffer length is expanded (event when inOffset points beyond the end of the input buffer). When the inOffset input is set to Auto data is written at the end of the input buffer.

Errors

List of possible exceptions:

Error type Description
IoError Reading beyond the end of the source byte buffer.
Data block specified by the inSourceOffset and inSourceLength inputs spans beyond the end of the source byte buffer (inSourceBuffer).
IoError Resulting buffer size is too large.