Back to Adaptive Vision Library website

You are here: Start » Function Reference » Array Transforms » RemoveNils

RemoveNils


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

Removes all Nil elements from an array.

Syntax

void avl::RemoveNils
(
	const atl::Array< typename atl::ToConditionalType<Type>::Type >& inArray,
	atl::Array<Type>& outArray,
	atl::Array<bool>& outElementExisted
)

Parameters

Name Type Default Description
inArray const Array< typename ToConditionalType<Type>::Type >& Input array
outArray Array<Type>& Output array
outElementExisted Array<bool>& Array with the same size as input array representing if the element was not a Nil

Examples

inArray = {2, 5, Nil, Nil, 7, Nil}
outArray = {2, 5, 7}