Update RingOpenGL - Add Function (Source Code) : void glDrawPixels(GLsizei width,GLsizei height,GLenum format,GLenum type,const GLvoid * data)
@@ -2414,6 +2414,36 @@ RING_FUNC(ring_glDrawElements)
glDrawElements( (GLenum ) (int) RING_API_GETNUMBER(1), (GLsizei ) (int) RING_API_GETNUMBER(2), (GLenum ) (int) RING_API_GETNUMBER(3),(GLvoid *) RING_API_GETCPOINTER(4,"GLvoid"));
}
+
+RING_FUNC(ring_glDrawPixels)
+{
+ if ( RING_API_PARACOUNT != 5 ) {
+ RING_API_ERROR(RING_API_BADPARACOUNT);
+ return ;
+ }
+ if ( ! RING_API_ISNUMBER(1) ) {
+ RING_API_ERROR(RING_API_BADPARATYPE);
+ return ;
+ }
+ if ( ! RING_API_ISNUMBER(2) ) {
+ RING_API_ERROR(RING_API_BADPARATYPE);
+ return ;
+ }
+ if ( ! RING_API_ISNUMBER(3) ) {
+ RING_API_ERROR(RING_API_BADPARATYPE);
+ return ;
+ }
+ if ( ! RING_API_ISNUMBER(4) ) {
+ RING_API_ERROR(RING_API_BADPARATYPE);
+ return ;
+ }
+ if ( ! RING_API_ISPOINTER(5) ) {
+ RING_API_ERROR(RING_API_BADPARATYPE);
+ return ;
+ }
+ glDrawPixels( (GLsizei ) (int) RING_API_GETNUMBER(1), (GLsizei ) (int) RING_API_GETNUMBER(2), (GLenum ) (int) RING_API_GETNUMBER(3), (GLenum ) (int) RING_API_GETNUMBER(4),(GLvoid *) RING_API_GETCPOINTER(5,"GLvoid"));
+}
+
RING_API void ringlib_init(RingState *pRingState)
{
ring_vm_funcregister("glaccum",ring_glAccum);
@@ -2528,4 +2558,5 @@ RING_API void ringlib_init(RingState *pRingState)
ring_vm_funcregister("gldrawbuffer",ring_glDrawBuffer);
ring_vm_funcregister("gldrawbuffers",ring_glDrawBuffers);
ring_vm_funcregister("gldrawelements",ring_glDrawElements);
+ ring_vm_funcregister("gldrawpixels",ring_glDrawPixels);
}
