MCPcopy Create free account
hub / github.com/NVIDIA/cuda-samples / initGL

Function initGL

cpp/5_Domain_Specific/volumeRender/volumeRender.cpp:406–418  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

404}
405
406void initGL(int *argc, char **argv)
407{
408 // initialize GLUT callback functions
409 glutInit(argc, argv);
410 glutInitDisplayMode(GLUT_RGB | GLUT_DOUBLE);
411 glutInitWindowSize(width, height);
412 glutCreateWindow("CUDA volume rendering");
413
414 if (!isGLVersionSupported(2, 0) || !areGLExtensionsSupported("GL_ARB_pixel_buffer_object")) {
415 printf("Required OpenGL extensions are missing.");
416 exit(EXIT_SUCCESS);
417 }
418}
419
420void initPixelBuffer()
421{

Callers 1

mainFunction · 0.70

Calls 2

isGLVersionSupportedFunction · 0.85
areGLExtensionsSupportedFunction · 0.85

Tested by

no test coverage detected