编译后我收到以下4个错误。
error C2065: 'CL_GL_CONTEXT_KHR' : undeclared identifier
error C2065: 'CL_WGL_HDC_KHR' : undeclared identifier
IntelliSense: identifier "CL_GL_CONTEXT_KHR" is undefined
IntelliSense: identifier "CL_WGL_HDC_KHR" is undefined
我使用以下标题:
#include <stdio.h>
//#include <iostream>
#include <Windows.h>
#include <GL/glew.h>
#ifdef MAC
#include <OpenCL/cl_gl.h>
#include <OpenGL/OpenGL.h>
#include <GLUT/freeglut.h>
#define GL_SHARING_EXTENSION "cl_APPLE_gl_sharing"
#else
#include <CL/cl.h>
#include <CL/cl_gl.h>
#include <GL/glut.h>