Skip to content

Commit

Permalink
API design change.
Browse files Browse the repository at this point in the history
We'll reference count shaders/programs internally so there's no concern
 about deleting an in-use object.

--HG--
branch : trunk
  • Loading branch information
icculus committed Apr 26, 2008
1 parent 61d9de6 commit f655c10
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions mojoshader.h
Expand Up @@ -513,17 +513,17 @@ void MOJOSHADER_glProgramReady(void);
* Free the resources of a linked program. This will delete the GL object
* and free memory.
*
* You must not call this on a bound program! Either bind a different one
* or call MOJOSHADER_glBindProgram(NULL) first to unbind it.
* If the program is currently bound by MOJOSHADER_glBindProgram(), it will
* be deleted as soon as it becomes unbound.
*/
void MOJOSHADER_glDeleteProgram(const MOJOSHADER_glProgram *program);

/*
* Free the resources of a compiled shader. This will delete the GL object
* and free memory.
*
* You must not call this on a shader that's currently linked in a program.
* Call MOJOSHADER_glDeleteProgram() on any programs, first.
* If the shader is currently referenced by a linked program, it will
* be deleted as soon as all referencing programs are deleted, too.
*/
void MOJOSHADER_glDeleteShader(const MOJOSHADER_glShader *shader);

Expand Down

0 comments on commit f655c10

Please sign in to comment.