rtcGetDeviceError(3) | Embree Ray Tracing Kernels 4 | rtcGetDeviceError(3) |
rtcGetDeviceError - returns the error code of the device
#include <embree4/rtcore.h> RTCError rtcGetDeviceError(RTCDevice device);
Each thread has its own error code per device. If an error occurs when calling an API function, this error code is set to the occurred error if it stores no previous error. The rtcGetDeviceError function reads and returns the currently stored error and clears the error code. This assures that the returned error code is always the first error occurred since the last invocation of rtcGetDeviceError.
Possible error codes returned by rtcGetDeviceError are:
When the device construction fails, rtcNewDevice returns NULL as device. To detect the error code of a such a failed device construction, pass NULL as device to the rtcGetDeviceError function. For all other invocations of rtcGetDeviceError, a proper device pointer must be specified.
The API function rtcGetDeviceLastErrorMessage can be used to get more details about the last RTCError a RTCDevice encountered.
For convenient reporting of a RTCError, the API function rtcGetErrorString can be used, which returns a string representation of a given RTCError.
Returns the error code for the device.
[rtcSetDeviceErrorFunction], [rtcGetDeviceLastErrorMessage], [rtcGetErrorString]