Category : glew

I have been through some trouble with shader in opengl, but can’t find any way out. I have follow the lesson in learnopengl (https://learnopengl.com/code_viewer_gh.php?code=src/1.getting_started/3.3.shaders_class/shaders_class.cpp) but my screen doesn’t draw any thing when i use shader. Now i have no bug detect,so the shader code is fine. But with the same coordinates draw by glBegin(GL_TRIANGLES); or ..

Read more

I’m trying to use Dear ImGui and OpenGL 3 with SDL and have setup everything correctly, but I keep getting an exception in imgui_impl_opengl3 and it’s specifically this line g_VertHandle = glCreateShader(GL_VERTEX_SHADER); which is called from the ImGui_ImplOpenGL3_NewFrame(); The exception is Exception thrown at 0x0000000000000000 in Henly.exe: 0xC0000005: Access violation executing location 0x0000000000000000. Here is ..

Read more

I’ve been trying to make a code so that a line appears across the window. I’ve been using c and opengl/sdl. But for some reason the code is not making a line in the window. I can’t figure out what I’m doing wrong: #include <SDL.h> #include <stdio.h> #include <GL/glew.h> #include <SDL_opengl.h> int main(int argc, char* ..

Read more