/* * $Id$ * * $Date$ * $Revision$ * * Written in 2018 by Daniel "Daytona675x" Müßener * * This file is part of the MiniGL library project * See the file Licence.txt for more details * */ #if defined(MGL_TABOR) && !defined(MGL_TABOR_NO_ABI_BRIDGE) #include "mgl/minigl.h" #include "tabor.h" extern void VARARGS68K cgl_MinTriArea(struct GLContextIFace *, GLfloat area); extern void VARARGS68K cgl_SetZOffset(struct GLContextIFace *, GLfloat offset); extern void VARARGS68K cgl_GLAlphaFunc(struct GLContextIFace *, GLenum func, GLclampf ref); extern void VARARGS68K cgl_GLClearColor(struct GLContextIFace *, GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha); extern void VARARGS68K cgl_GLClearDepth(struct GLContextIFace *, GLclampd depth); extern void VARARGS68K cgl_GLColor4f(struct GLContextIFace *, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); extern void VARARGS68K cgl_GLDepthRange(struct GLContextIFace *, GLclampd n, GLclampd f); extern void VARARGS68K cgl_GLFogf(struct GLContextIFace *, GLenum pname, GLfloat param); extern void VARARGS68K cgl_GLFrustum(struct GLContextIFace *, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar); extern void VARARGS68K cgl_GLNormal3f(struct GLContextIFace *, GLfloat x, GLfloat y, GLfloat z); extern void VARARGS68K cgl_GLOrtho(struct GLContextIFace *, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar); extern void VARARGS68K cgl_GLPolygonOffset(struct GLContextIFace *, GLfloat factor, GLfloat units); extern void VARARGS68K cgl_GLRotatef(struct GLContextIFace *, GLfloat angle, GLfloat x, GLfloat y, GLfloat z); extern void VARARGS68K cgl_GLScalef(struct GLContextIFace *, GLfloat x, GLfloat y, GLfloat z); extern void VARARGS68K cgl_GLTexCoord2f(struct GLContextIFace *, GLfloat s, GLfloat t); extern void VARARGS68K cgl_GLTexCoord4f(struct GLContextIFace *, GLfloat s, GLfloat t, GLfloat r, GLfloat q); extern void VARARGS68K cgl_GLTranslatef(struct GLContextIFace *, GLfloat x, GLfloat y, GLfloat z); extern void VARARGS68K cgl_GLVertex4f(struct GLContextIFace *, GLfloat x, GLfloat y, GLfloat z, GLfloat w); extern void VARARGS68K cgl_GLRectf(struct GLContextIFace *, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2); extern void VARARGS68K cgl_GLMultiTexCoord2f(struct GLContextIFace *, GLenum unit, GLfloat s, GLfloat t); extern void VARARGS68K cgl_GLMultiTexCoord4f(struct GLContextIFace *, GLenum unit, GLfloat s, GLfloat t, GLfloat r, GLfloat q); extern void VARARGS68K cgl_GLMaterialf(struct GLContextIFace *, GLenum face, GLenum pname, GLfloat param); extern void VARARGS68K cgl_GLLightf(struct GLContextIFace *, GLenum light, GLenum pname, GLfloat param); extern void VARARGS68K cgl_GLLightModelf(struct GLContextIFace *, GLenum pname, GLfloat param); extern void VARARGS68K cgl_GLLineWidth(struct GLContextIFace *, GLfloat width); extern void VARARGS68K cgl_GLPointSize(struct GLContextIFace *, GLfloat size); extern void VARARGS68K cgl_GLBitmap(struct GLContextIFace *, GLsizei w, GLsizei h, GLfloat xbo, GLfloat ybo, GLfloat xbi, GLfloat ybi, const GLubyte *data); extern void VARARGS68K cgl_GLRasterPos4f(struct GLContextIFace *, GLfloat x, GLfloat y, GLfloat z, GLfloat w); extern void VARARGS68K cgl_GLMap1f(struct GLContextIFace *, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points); extern void VARARGS68K cgl_GLMap1d(struct GLContextIFace *, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLdouble* points); extern void VARARGS68K cgl_GLEvalCoord1f(struct GLContextIFace *, GLfloat arg); extern void VARARGS68K cgl_GLMapGrid1f(struct GLContextIFace *, GLint n, GLfloat u1, GLfloat u2); extern void VARARGS68K cgl_GLMap2f(struct GLContextIFace *, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points); extern void VARARGS68K cgl_GLMap2d(struct GLContextIFace *, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points); extern void VARARGS68K cgl_GLEvalCoord2f(struct GLContextIFace *, GLfloat u, GLfloat v); extern void VARARGS68K cgl_GLMapGrid2f(struct GLContextIFace *, GLint nu, GLfloat u1, GLfloat u2, GLint nv, GLfloat v1, GLfloat v2); extern void VARARGS68K cgl_GLPixelTransferf(struct GLContextIFace *, GLenum param, GLfloat value); extern void VARARGS68K cgl_GLUTessProperty(struct GLContextIFace *, GLUtesselator * tess, GLenum which, GLdouble value); extern void VARARGS68K cgl_GLUTessNormal(struct GLContextIFace *, GLUtesselator * tess, GLdouble x, GLdouble y, GLdouble z); extern void VARARGS68K cgl_GLUOrtho2D(struct GLContextIFace *, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top); extern void VARARGS68K cgl_GLUPerspective(struct GLContextIFace *, GLdouble fovy, GLdouble aspect, GLdouble zNear, GLdouble zFar); extern void VARARGS68K cgl_GLULookAt(struct GLContextIFace *, GLdouble eyex, GLdouble eyey, GLdouble eyez, GLdouble centerx, GLdouble centery, GLdouble centerz, GLdouble upx, GLdouble upy, GLdouble upz); extern GLint VARARGS68K cgl_GLUProject(struct GLContextIFace *, GLdouble objx, GLdouble objy, GLdouble objz, const GLdouble * modelMatrix, const GLdouble * projMatrix, const GLint * viewPort, GLdouble * winx, GLdouble * winy, GLdouble * winz); extern GLint VARARGS68K cgl_GLUUnProject(struct GLContextIFace *, GLdouble winx, GLdouble winy, GLdouble winz, const GLdouble * modelMatrix, const GLdouble * projMatrix, const GLint * viewPort, GLdouble * objx, GLdouble * objy, GLdouble * objz); extern GLint VARARGS68K cgl_GLUUnProject4(struct GLContextIFace *, GLdouble winx, GLdouble winy, GLdouble winz, GLdouble clipw, const GLdouble * modelMatrix, const GLdouble * projMatrix, const GLint * viewPort, GLdouble nearVal, GLdouble farVal, GLdouble * objx, GLdouble * objy, GLdouble * objz, GLdouble * objw); extern void VARARGS68K cgl_GLUPickMatrix(struct GLContextIFace *, GLdouble x, GLdouble y, GLdouble deltax, GLdouble deltay, GLint * viewport); extern void VARARGS68K cgl_GLUCylinder(struct GLContextIFace *, GLUquadric * qobj, GLdouble baseRadius, GLdouble topRadius, GLdouble height, GLint slices, GLint stacks); extern void VARARGS68K cgl_GLUDisk(struct GLContextIFace *, GLUquadric * qobj, GLdouble innerRadius, GLdouble outerRadius, GLint slices, GLint loops); extern void VARARGS68K cgl_GLUPartialDisk(struct GLContextIFace *, GLUquadric * qobj, GLdouble innerRadius, GLdouble outerRadius, GLint slices, GLint loops, GLdouble startAngle, GLdouble sweepAngle); extern void VARARGS68K cgl_GLUSphere(struct GLContextIFace *, GLUquadric * qobj, GLdouble radius, GLint slices, GLint stacks); extern void VARARGS68K cgl_GLUNurbsProperty(struct GLContextIFace *, GLUnurbs * r, GLenum property, GLfloat value); extern void VARARGS68K cgl_GLPixelZoom(struct GLContextIFace *, GLfloat zoomx, GLfloat zoomy); extern void VARARGS68K cgl_GLClipPlane(struct GLContextIFace *, GLenum plane, const GLdouble *eqn); extern void VARARGS68K cgl_GLUTessVertex(struct GLContextIFace *, GLUtesselator * tess, GLdouble * coords, void * data); void TABORIZE_GLUE(cgl_GLUTessVertex)(struct GLContextIFace *self, GLUtesselator * tess, void * data) { TB_GET_CONTEXT; cgl_GLUTessVertex(self,tess,&TB_DBL_0,data); } void TABORIZE_GLUE(cgl_GLClipPlane)(struct GLContextIFace *self, GLenum plane) { TB_GET_CONTEXT; // cgl_GLClipPlane(self,plane,&TB_DBL_0); GLdouble vec[4]={TB_DBL_0,TB_DBL_1,TB_DBL_2,TB_DBL_3}; cgl_GLClipPlane(self,plane,vec); } void TABORIZE_GLUE(cgl_GLClearDepth)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLClearDepth(self,TB_DBL_0); } void TABORIZE_GLUE(cgl_GLDepthRange)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLDepthRange(self,TB_DBL_0,TB_DBL_1); } void TABORIZE_GLUE(cgl_GLAlphaFunc)(struct GLContextIFace *self, GLenum func) { TB_GET_CONTEXT; cgl_GLAlphaFunc(self,func,TB_FLT_0); } void TABORIZE_GLUE(cgl_GLClearColor)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLClearColor(self,TB_FLT_0,TB_FLT_1,TB_FLT_2,TB_FLT_3); } void TABORIZE_GLUE(cgl_MinTriArea)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_MinTriArea(self,TB_FLT_0); } void TABORIZE_GLUE(cgl_SetZOffset)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_SetZOffset(self,TB_FLT_0); } void TABORIZE_GLUE(cgl_GLColor4f)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLColor4f(self,TB_FLT_0,TB_FLT_1,TB_FLT_2,TB_FLT_3); } void TABORIZE_GLUE(cgl_GLFogf)(struct GLContextIFace *self, GLenum pname) { TB_GET_CONTEXT; cgl_GLFogf(self,pname,TB_FLT_0); } void TABORIZE_GLUE(cgl_GLFrustum)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLFrustum(self,TB_DBL_0,TB_DBL_1,TB_DBL_2,TB_DBL_3,TB_DBL_4,TB_DBL_5); } void TABORIZE_GLUE(cgl_GLNormal3f)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLNormal3f(self,TB_FLT_0,TB_FLT_1,TB_FLT_2); } void TABORIZE_GLUE(cgl_GLOrtho)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLOrtho(self,TB_DBL_0,TB_DBL_1,TB_DBL_2,TB_DBL_3,TB_DBL_4,TB_DBL_5); } void TABORIZE_GLUE(cgl_GLPolygonOffset)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLPolygonOffset(self,TB_FLT_0,TB_FLT_1); } void TABORIZE_GLUE(cgl_GLRotatef)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLRotatef(self,TB_FLT_0,TB_FLT_1,TB_FLT_2,TB_FLT_3); } void TABORIZE_GLUE(cgl_GLScalef)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLScalef(self,TB_FLT_0,TB_FLT_1,TB_FLT_2); } void TABORIZE_GLUE(cgl_GLTexCoord2f)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLTexCoord2f(self,TB_FLT_0,TB_FLT_1); } void TABORIZE_GLUE(cgl_GLTexCoord4f)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLTexCoord4f(self,TB_FLT_0,TB_FLT_1,TB_FLT_2,TB_FLT_3); } void TABORIZE_GLUE(cgl_GLTranslatef)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLTranslatef(self,TB_FLT_0,TB_FLT_1,TB_FLT_2); } void TABORIZE_GLUE(cgl_GLVertex4f)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLVertex4f(self,TB_FLT_0,TB_FLT_1,TB_FLT_2,TB_FLT_3); } void TABORIZE_GLUE(cgl_GLRectf)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLRectf(self,TB_FLT_0,TB_FLT_1,TB_FLT_2,TB_FLT_3); } void TABORIZE_GLUE(cgl_GLMultiTexCoord2f)(struct GLContextIFace *self, GLenum unit) { TB_GET_CONTEXT; cgl_GLMultiTexCoord2f(self,unit,TB_FLT_0,TB_FLT_1); } void TABORIZE_GLUE(cgl_GLMultiTexCoord4f)(struct GLContextIFace *self, GLenum unit) { TB_GET_CONTEXT; cgl_GLMultiTexCoord4f(self,unit,TB_FLT_0,TB_FLT_1,TB_FLT_2,TB_FLT_3); } void TABORIZE_GLUE(cgl_GLMaterialf)(struct GLContextIFace *self, GLenum face, GLenum pname) { TB_GET_CONTEXT; cgl_GLMaterialf(self,face,pname,TB_FLT_0); } void TABORIZE_GLUE(cgl_GLLightf)(struct GLContextIFace *self, GLenum light, GLenum pname) { TB_GET_CONTEXT; cgl_GLLightf(self,light,pname,TB_FLT_0); } void TABORIZE_GLUE(cgl_GLLightModelf)(struct GLContextIFace *self, GLenum pname) { TB_GET_CONTEXT; cgl_GLLightModelf(self,pname,TB_FLT_0); } void TABORIZE_GLUE(cgl_GLLineWidth)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLLineWidth(self,TB_FLT_0); } void TABORIZE_GLUE(cgl_GLPointSize)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLPointSize(self,TB_FLT_0); } void TABORIZE_GLUE(cgl_GLBitmap)(struct GLContextIFace *self, GLsizei w, GLsizei h, const GLubyte *data) { TB_GET_CONTEXT; cgl_GLBitmap(self,w,h,TB_FLT_0,TB_FLT_1,TB_FLT_2,TB_FLT_3,data); } void TABORIZE_GLUE(cgl_GLRasterPos4f)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLRasterPos4f(self,TB_FLT_0,TB_FLT_1,TB_FLT_2,TB_FLT_3); } void TABORIZE_GLUE(cgl_GLMap1f)(struct GLContextIFace *self, GLenum target, GLint stride, GLint order, const GLfloat* points) { TB_GET_CONTEXT; cgl_GLMap1f(self,target,TB_FLT_0,TB_FLT_1,stride,order,points); } void TABORIZE_GLUE(cgl_GLMap1d)(struct GLContextIFace *self, GLenum target, GLint stride, GLint order, const GLdouble* points) { TB_GET_CONTEXT; cgl_GLMap1d(self,target,TB_FLT_0,TB_FLT_1,stride,order,points); } void TABORIZE_GLUE(cgl_GLEvalCoord1f)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLEvalCoord1f(self,TB_FLT_0); } void TABORIZE_GLUE(cgl_GLMapGrid1f)(struct GLContextIFace *self, GLint n) { TB_GET_CONTEXT; cgl_GLMapGrid1f(self,n,TB_FLT_0,TB_FLT_1); } void TABORIZE_GLUE(cgl_GLMap2f)(struct GLContextIFace *self, GLenum target, GLint ustride, GLint uorder, GLint vstride, GLint vorder, const GLfloat* points) { TB_GET_CONTEXT; cgl_GLMap2f(self,target,TB_FLT_0,TB_FLT_1,ustride,uorder,TB_FLT_2,TB_FLT_3,vstride,vorder,points); } void TABORIZE_GLUE(cgl_GLMap2d)(struct GLContextIFace *self, GLenum target, GLint ustride, GLint uorder, GLint vstride, GLint vorder, const GLdouble* points) { TB_GET_CONTEXT; cgl_GLMap2d(self,target,TB_DBL_0,TB_DBL_1,ustride,uorder,TB_DBL_2,TB_DBL_3,vstride,vorder,points); } void TABORIZE_GLUE(cgl_GLEvalCoord2f)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLEvalCoord2f(self,TB_FLT_0,TB_FLT_1); } void TABORIZE_GLUE(cgl_GLMapGrid2f)(struct GLContextIFace *self, GLint nu, GLint nv) { TB_GET_CONTEXT; cgl_GLMapGrid2f(self,nu,TB_FLT_0,TB_FLT_1,nv,TB_FLT_2,TB_FLT_3); } void TABORIZE_GLUE(cgl_GLPixelTransferf)(struct GLContextIFace *self, GLenum param) { TB_GET_CONTEXT; cgl_GLPixelTransferf(self,param,TB_FLT_0); } void TABORIZE_GLUE(cgl_GLUTessProperty)(struct GLContextIFace *self, GLUtesselator * tess, GLenum which) { TB_GET_CONTEXT; cgl_GLUTessProperty(self,tess,which,TB_DBL_0); } void TABORIZE_GLUE(cgl_GLUTessNormal)(struct GLContextIFace *self, GLUtesselator * tess) { TB_GET_CONTEXT; cgl_GLUTessNormal(self,tess,TB_DBL_0,TB_DBL_1,TB_DBL_2); } void TABORIZE_GLUE(cgl_GLUOrtho2D)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLUOrtho2D(self,TB_DBL_0,TB_DBL_1,TB_DBL_2,TB_DBL_3); } void TABORIZE_GLUE(cgl_GLUPerspective)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLUPerspective(self,TB_DBL_0,TB_DBL_1,TB_DBL_2,TB_DBL_3); } void TABORIZE_GLUE(cgl_GLULookAt)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLULookAt(self,TB_DBL_0,TB_DBL_1,TB_DBL_2,TB_DBL_3,TB_DBL_4,TB_DBL_5,TB_DBL_6,TB_DBL_7,TB_DBL_8); } GLint TABORIZE_GLUE(cgl_GLUProject)(struct GLContextIFace *self, const GLdouble * modelMatrix, const GLdouble * projMatrix, const GLint * viewPort, GLdouble * winx, GLdouble * winy, GLdouble * winz) { TB_GET_CONTEXT; return cgl_GLUProject(self,TB_DBL_0,TB_DBL_1,TB_DBL_2,modelMatrix,projMatrix,viewPort,winx,winy,winz); } GLint TABORIZE_GLUE(cgl_GLUUnProject)(struct GLContextIFace *self, const GLdouble * modelMatrix, const GLdouble * projMatrix, const GLint * viewPort, GLdouble * objx, GLdouble * objy, GLdouble * objz) { TB_GET_CONTEXT; return cgl_GLUUnProject(self,TB_DBL_0,TB_DBL_1,TB_DBL_2,modelMatrix,projMatrix,viewPort,objx,objy,objz); } GLint TABORIZE_GLUE(cgl_GLUUnProject4)(struct GLContextIFace *self, const GLdouble * modelMatrix, const GLdouble * projMatrix, const GLint * viewPort, GLdouble * objx, GLdouble * objy, GLdouble * objz, GLdouble * objw) { TB_GET_CONTEXT; return cgl_GLUUnProject4(self,TB_DBL_0,TB_DBL_1,TB_DBL_2,TB_DBL_3,modelMatrix,projMatrix,viewPort,TB_DBL_4,TB_DBL_5,objx,objy,objz,objw); } void TABORIZE_GLUE(cgl_GLUPickMatrix)(struct GLContextIFace *self, GLint * viewport) { TB_GET_CONTEXT; cgl_GLUPickMatrix(self,TB_DBL_0,TB_DBL_1,TB_DBL_2,TB_DBL_3,viewport); } void TABORIZE_GLUE(cgl_GLUCylinder)(struct GLContextIFace *self, GLUquadric * qobj, GLint slices, GLint stacks) { TB_GET_CONTEXT; cgl_GLUCylinder(self,qobj,TB_DBL_0,TB_DBL_1,TB_DBL_2,slices,stacks); } void TABORIZE_GLUE(cgl_GLUDisk)(struct GLContextIFace *self, GLUquadric * qobj, GLint slices, GLint loops) { TB_GET_CONTEXT; cgl_GLUDisk(self,qobj,TB_DBL_0,TB_DBL_1,slices,loops); } void TABORIZE_GLUE(cgl_GLUPartialDisk)(struct GLContextIFace *self, GLUquadric * qobj, GLint slices, GLint loops) { TB_GET_CONTEXT; cgl_GLUPartialDisk(self,qobj,TB_DBL_0,TB_DBL_1,slices,loops,TB_DBL_2,TB_DBL_3); } void TABORIZE_GLUE(cgl_GLUSphere)(struct GLContextIFace *self, GLUquadric * qobj, GLint slices, GLint stacks) { TB_GET_CONTEXT; cgl_GLUSphere(self,qobj,TB_DBL_0,slices,stacks); } void TABORIZE_GLUE(cgl_GLUNurbsProperty)(struct GLContextIFace *self, GLUnurbs * r, GLenum property) { TB_GET_CONTEXT; cgl_GLUNurbsProperty(self,r,property,TB_FLT_0); } void TABORIZE_GLUE(cgl_GLPixelZoom)(struct GLContextIFace *self) { TB_GET_CONTEXT; cgl_GLPixelZoom(self,TB_FLT_0,TB_FLT_1); } #endif