Skip to content

Instantly share code, notes, and snippets.

@hb3p8
Created October 28, 2016 06:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hb3p8/27ecf1bde8bc16fb784127384de23f3e to your computer and use it in GitHub Desktop.
Save hb3p8/27ecf1bde8bc16fb784127384de23f3e to your computer and use it in GitHub Desktop.
const size_t MAX_SIZE = 1<<24;
char* binary = new char[MAX_SIZE];
GLenum format;
GLint length;
theGlContext->core44->glGetProgramBinary (myRaytraceProgram->ProgramId(), MAX_SIZE, &length, &format, binary);
std::ofstream file ("D:/asm.bin", ios::out | ios::binary );
file.write (binary, length);
file.close();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment