| 176 | |
| 177 | |
| 178 | ocipError ocip_API ocipCreateImage(ocipImage * ImagePtr, SImage image, void * ImageData, cl_mem_flags flags) |
| 179 | { |
| 180 | COpenCL * CL = g_CurrentContext; |
| 181 | |
| 182 | if (CL == nullptr) |
| 183 | return CL_INVALID_CONTEXT; |
| 184 | |
| 185 | H( if (image.Channels == 3) |
| 186 | *ImagePtr = (ocipImage) new ColorImage(*CL, image, ImageData); |
| 187 | else |
| 188 | *ImagePtr = (ocipImage) new Image(*CL, image, ImageData, flags); |
| 189 | ) |
| 190 | } |
| 191 | |
| 192 | ocipError ocip_API ocipSendImage(ocipImage image) |
| 193 | { |