Skip to content

Instantly share code, notes, and snippets.

Vardhan vrdhn

Block or report user

Report or block vrdhn

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View Using GL_OES_EGL_image_external on Android
1. The texture target needs to be GLES20.GL_TEXTURE_EXTERNAL_OES instead of GL_TEXTURE_2D, e.g. in the glBindTexture calls and glTexParameteri calls.
2. In the fragment shader define a requirement to use the extension:
#extension GL_OES_EGL_image_external : require
3. For the texture sampler used in the fragment shader, use samplerExternalOES instead of sampler2D.
Everything below here is all in the C code, no more Java.
4. In the C code, use glEGLImageTargetTexture2DOES(GL_TEXTURE_EXTERNAL_OES, eglImage) to specify where the data is, instead of using glTexImage2D family of functions.
@bcachet
bcachet / splitpatch.rb
Created Nov 9, 2011
Script to split a unified patch file into several ones
View splitpatch.rb
#!/usr/bin/env ruby
#
# splitpatch is a simple script to split a patch up into multiple patch files.
# if the --hunks option is provided on the command line, each hunk gets its
# own patchfile.
#
# Copyright (C) 2007, Peter Hutterer <peter@cs.unisa.edu.au>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
You can’t perform that action at this time.