! \brief Constructs a 1D Image in a specified context. * * Wraps clCreateImage(). */
| 3643 | * Wraps clCreateImage(). |
| 3644 | */ |
| 3645 | Image1D( |
| 3646 | const Context& context, |
| 3647 | cl_mem_flags flags, |
| 3648 | ImageFormat format, |
| 3649 | ::size_t width, |
| 3650 | void* host_ptr = NULL, |
| 3651 | cl_int* err = NULL) |
| 3652 | { |
| 3653 | cl_int error; |
| 3654 | cl_image_desc desc = |
| 3655 | { |
| 3656 | CL_MEM_OBJECT_IMAGE1D, |
| 3657 | width, |
| 3658 | 0, 0, 0, 0, 0, 0, 0, 0 |
| 3659 | }; |
| 3660 | object_ = ::clCreateImage( |
| 3661 | context(), |
| 3662 | flags, |
| 3663 | &format, |
| 3664 | &desc, |
| 3665 | host_ptr, |
| 3666 | &error); |
| 3667 | |
| 3668 | detail::errHandler(error, __CREATE_IMAGE_ERR); |
| 3669 | if (err != NULL) { |
| 3670 | *err = error; |
| 3671 | } |
| 3672 | } |
| 3673 | |
| 3674 | //! \brief Default constructor - initializes to NULL. |
| 3675 | Image1D() { } |
nothing calls this directly
no test coverage detected