Voxel
 All Classes Namespaces Files Functions Typedefs Enumerations Enumerator Macros Pages
Public Member Functions | List of all members
OpenCL::Exception Struct Reference

OpenCL exception class. More...

#include <opencl_exception.h>

Public Member Functions

 Exception (char const *const file, unsigned int const line, std::string const &what, cl_int const result)
virtual const char * what () const throw ()
 Returns text (UTF-8) error message for this exception.

Detailed Description

OpenCL exception class.

OpenCL Exceptions should not be constructed explicitly. Instead, use the THROW_OPENCL_EXCEPTION() macro, which will construct and throw an exception annotated with the filename and line number of the failure.

The difference between this class and the "default" exception class is that an OpenCL exception converts OpenCL error codes into error strings.

The error message returned by what() has the following components:

  1. Filename and line number at which the exception was thrown.
  2. Description string what passed to the constructor.
  3. Description of the OpenCL error code passed to the constructor.

Definition at line 79 of file opencl_exception.h.


The documentation for this struct was generated from the following files: