Code example for EGL10

Methods: eglGetDisplayeglInitialize

0
		this.mEgl = (EGL10) EGLContext.getEGL();
 
		/* 
		 * Get to the default display. 
		 */ 
		this.mEglDisplay = this.mEgl.eglGetDisplay(EGL10.EGL_DEFAULT_DISPLAY);
 
		/* 
		 * We can now initialize EGL for that display 
		 */ 
		final int[] version = new int[2];
		this.mEgl.eglInitialize(this.mEglDisplay, version);
		this.mEglConfig = this.mEGLConfigChooser.chooseConfig(this.mEgl, this.mEglDisplay);
 
		/* 
		 * Create an OpenGL ES context. This must be done only once, an OpenGL 
		 * context is a somewhat heavy object. 
		 */ 
		this.mEglContext = this.mEGLContextFactory.createContext(this.mEgl, this.mEglDisplay, this.mEglConfig);
		if (this.mEglContext == null || this.mEglContext == EGL10.EGL_NO_CONTEXT) {
Experience pair programming with AI  Get Codota for Java