aboutsummaryrefslogtreecommitdiffstats
path: root/c_src/sdl_gl.c
diff options
context:
space:
mode:
authorLoïc Hoguin <[email protected]>2017-12-20 20:03:16 +0100
committerLoïc Hoguin <[email protected]>2017-12-20 20:03:16 +0100
commitb0950785e72d9d59c6fd816c01d203ecb083c663 (patch)
tree38cfae31a019ffe7b90d60dea2f6f01c3830e4b3 /c_src/sdl_gl.c
parente4f6a3c1f1032f83b25210dea21bbacf4552f8f0 (diff)
downloadesdl2-b0950785e72d9d59c6fd816c01d203ecb083c663.tar.gz
esdl2-b0950785e72d9d59c6fd816c01d203ecb083c663.tar.bz2
esdl2-b0950785e72d9d59c6fd816c01d203ecb083c663.zip
Add the sdl_mouse module implementing half of sdl_mouse.h
The latter half will be part of sdl_cursor. This depends on some changes to nif_helper. The sdl_gl part of the code is probably slithly broken now, the dependency on the window is gone. This will be resolved later on.
Diffstat (limited to 'c_src/sdl_gl.c')
-rw-r--r--c_src/sdl_gl.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/c_src/sdl_gl.c b/c_src/sdl_gl.c
index febd49f..71fef6a 100644
--- a/c_src/sdl_gl.c
+++ b/c_src/sdl_gl.c
@@ -17,7 +17,7 @@
void dtor_GLContext(ErlNifEnv* env, void* obj)
{
SDL_GL_DeleteContext(NIF_RES_GET(GLContext, obj));
- enif_release_resource(NIF_RES_DEP(GLContext, obj));
+// @todo enif_release_resource(NIF_RES_DEP(GLContext, obj));
}
// gl_create_context
@@ -33,7 +33,8 @@ NIF_CALL_HANDLER(thread_gl_create_context)
enif_keep_resource(args[0]);
- NIF_RES_TO_TERM_WITH_DEP(GLContext, context, term, args[0]);
+// @todo NIF_RES_TO_TERM_WITH_DEP(GLContext, context, term, args[0]);
+ NIF_RES_TO_TERM(GLContext, context, term);
return enif_make_tuple2(env,
atom_ok,