NVIDIA Holoscan SDK v0.6
v0.6

Class HostBuffer

class HostBuffer

Public Functions

inline explicit HostBuffer(holoinfer_datatype data_type = holoinfer_datatype::h_Float32)

Constructor.

Parameters

data_type – data type of the buffer

inline void *data()

Get the buffer data on the host.

Returns

void pointer to the buffer

inline size_t size() const

Get the number of elements in the buffer.

Returns

size

inline void set_type(holoinfer_datatype in_type)

Set the data type and resize the buffer.

Parameters

in_type – input data type

inline void resize(size_t number_of_elements)

Resize the underlying buffer on host.

Parameters

number_of_elements – Number of elements to be resized with

© Copyright 2022-2023, NVIDIA. Last updated on Feb 9, 2024.