Other¶
The functions below can be used for initialization, finalization and to perform other management tasks:
TranslateReturnCode¶
-
static inline String Ensenso::sealed::TranslateReturnCode(int errorCode)¶
Retrieves a string description for an API return code.
- Parameters
errorCode – The error code which shall be translated.
- Returns
The corresponding error text of the error code.
WriteDebugMessages¶
-
static inline void Ensenso::sealed::WriteDebugMessage(String message)¶
Wraps nxLibWriteDebugMessage()
- Parameters
message – The message to write.
- Throws
Ensenso::NxLibException –
-
static inline void Ensenso::sealed::WriteDebugMessage(int result, String message)¶
Wraps nxLibWriteDebugMessage()
- Parameters
result – The error code of operation.
message – The message to be written.
GetDebugMessages¶
-
static inline String Ensenso::sealed::GetDebugMessages()¶
Wraps nxLibGetDebugMessages()
- Throws
Ensenso::NxLibException –
- Returns
The debug messages from all threads separated by the newline character (\n).
-
static inline String Ensenso::sealed::GetDebugMessages(int result)¶
Wraps nxLibGetDebugMessages()
- Returns
The debug messages from all threads separated by the newline character (\n).
GetDebugBuffer¶
-
template<typename T>
static inline void Ensenso::sealed::GetDebugBuffer(array<T> destinationBuffer, bool clearRead, bool overflow)¶ Wraps nxLibGetDebugBuffer()
- Parameters
destinationBuffer – Pointer to an allocated memory block.
clearRead – When set to true the operation will also remove the retrieved content from the debug buffer.
overflow – True, if an overflow happened. False otherwise.
- Throws
Ensenso::NxLibException –
-
template<typename T>
static inline void Ensenso::sealed::GetDebugBuffer(int result, array<T> destinationBuffer, bool clearRead, bool overflow)¶ Wraps nxLibGetDebugBuffer()
- Parameters
result – The error code of operation. If the debug buffer could not hold all streamed debug information, the error code NxLibDebugMessageOverflow will be returned.
destinationBuffer – Pointer to an allocated memory block.
clearRead – When set to true the operation will also remove the retrieved content from the debug buffer.
overflow – True, if an overflow happened. False otherwise.
Initialize¶
-
static inline void Ensenso::sealed::Initialize(int result, bool waitForInitialCameraRefresh)¶
Wraps nxLibInitialize()
- Parameters
result – The error code of operation.
waitForInitialCameraRefresh – Specifies, whether to wait for all cameras to be enumerated or to be returned immediately.
Finalize¶
-
static inline void Ensenso::sealed::Finalize(int result)¶
Wraps nxLibFinalize()
Note
Pay attention to not confuse this function with Finalize() Objects of C#-Objects.
- Parameters
result – The error code of operation.
OpenTcpPort¶
-
static inline void Ensenso::sealed::OpenTcpPort(int portNumber, int openedPort)¶
Opens a TCP port on which NxLibRemote can connect to the current NxLib instance.
- Parameters
portNumber – The port to be opened. Specify 0 here to automatically choose a port in the range 24000 to 25000.
openedPort – A pointer to a variable receiving the opened port number.
- Throws
Ensenso::NxLibException –
-
static inline void Ensenso::sealed::OpenTcpPort(int result, int portNumber, int openedPort)¶
Opens a TCP port on which NxLibRemote can connect to the current NxLib instance.
- Parameters
result – The error code of operation.
portNumber – The port to be opened. Specify 0 here to automatically choose a port in the range 24000 to 25000.
openedPort – A pointer to a variable receiving the opened port number.
CloseTcpPort¶
-
static inline void Ensenso::sealed::CloseTcpPort(int result)¶
Disconnects all connected NxLibRemote instances and closes the opened TCP port, if any.
- Parameters
result – The error code of operation.
-
static inline void Ensenso::sealed::CloseTcpPort()¶
Disconnects all connected NxLibRemote instances and closes the opened TCP port, if any.
- Throws
Ensenso::NxLibException –