david wrote import com.jogamp.opengl.impl.windows.wgl.GDI; insert this line : GDI.GetDC(glcanvas.handle); after this line: glcanvas.setCurrent();