143 ctx->Array.VertexPtr = (
void *)
ptr;
178 ctx->Array.NormalPtr = (
void *)
ptr;
227 ctx->Array.ColorPtr = (
void *)
ptr;
258 ctx->Array.IndexPtr = (
void *)
ptr;
292 ctx->Array.TexCoordSize =
size;
293 ctx->Array.TexCoordType =
type;
295 ctx->Array.TexCoordPtr = (
void *)
ptr;
324 if (
ctx->Array.NormalEnabled) {
326 +
i *
ctx->Array.NormalStrideB;
360 VB->Normal[
count][0] =
ctx->Current.Normal[0];
361 VB->Normal[
count][1] =
ctx->Current.Normal[1];
362 VB->Normal[
count][2] =
ctx->Current.Normal[2];
366 if (
ctx->Array.ColorEnabled) {
370 switch (
ctx->Array.ColorSize) {
376 switch (
ctx->Array.ColorSize) {
382 switch (
ctx->Array.ColorSize) {
388 switch (
ctx->Array.ColorSize) {
394 switch (
ctx->Array.ColorSize) {
400 switch (
ctx->Array.ColorSize) {
406 switch (
ctx->Array.ColorSize) {
412 switch (
ctx->Array.ColorSize) {
427 if (
ctx->Light.ColorMaterialEnabled) {
429 color[0] =
ctx->Current.ByteColor[0] *
ctx->Visual->InvRedScale;
430 color[1] =
ctx->Current.ByteColor[1] *
ctx->Visual->InvGreenScale;
431 color[2] =
ctx->Current.ByteColor[2] *
ctx->Visual->InvBlueScale;
432 color[3] =
ctx->Current.ByteColor[3] *
ctx->Visual->InvAlphaScale;
437 if (
ctx->Array.IndexEnabled) {
462 if (
ctx->Array.TexCoordEnabled) {
464 +
i *
ctx->Array.TexCoordStrideB;
470 switch (
ctx->Array.TexCoordSize) {
479 switch (
ctx->Array.TexCoordSize) {
488 switch (
ctx->Array.TexCoordSize) {
497 switch (
ctx->Array.TexCoordSize) {
514 if (
ctx->Array.EdgeFlagEnabled) {
516 +
i *
ctx->Array.EdgeFlagStrideB;
523 if (
ctx->Array.VertexEnabled) {
525 +
i *
ctx->Array.VertexStrideB;
530 switch (
ctx->Array.VertexSize) {
539 switch (
ctx->Array.VertexSize) {
548 switch (
ctx->Array.VertexSize) {
557 switch (
ctx->Array.VertexSize) {
594 if (
ctx->Array.NormalEnabled) {
596 +
i *
ctx->Array.NormalStrideB;
619 if (
ctx->Array.ColorEnabled) {
623 switch (
ctx->Array.ColorSize) {
629 switch (
ctx->Array.ColorSize) {
635 switch (
ctx->Array.ColorSize) {
641 switch (
ctx->Array.ColorSize) {
647 switch (
ctx->Array.ColorSize) {
653 switch (
ctx->Array.ColorSize) {
659 switch (
ctx->Array.ColorSize) {
665 switch (
ctx->Array.ColorSize) {
676 if (
ctx->Array.IndexEnabled) {
697 if (
ctx->Array.TexCoordEnabled) {
699 +
i *
ctx->Array.TexCoordStrideB;
702 switch (
ctx->Array.TexCoordSize) {
710 switch (
ctx->Array.TexCoordSize) {
718 switch (
ctx->Array.TexCoordSize) {
726 switch (
ctx->Array.TexCoordSize) {
734 gl_problem(
ctx,
"Bad texcoord type in gl_save_ArrayElement");
739 if (
ctx->Array.EdgeFlagEnabled) {
744 if (
ctx->Array.VertexEnabled) {
746 +
i *
ctx->Array.VertexStrideB;
749 switch (
ctx->Array.VertexSize) {
756 switch (
ctx->Array.VertexSize) {
763 switch (
ctx->Array.VertexSize) {
770 switch (
ctx->Array.VertexSize) {
813 if (!
ctx->Light.Enabled
814 && !
ctx->Texture.Enabled
816 &&
ctx->Array.VertexStride==0 &&
ctx->Array.VertexSize==3
817 && !
ctx->Array.NormalEnabled
818 && !
ctx->Array.ColorEnabled
819 && !
ctx->Array.IndexEnabled
820 && !
ctx->Array.TexCoordEnabled
821 && !
ctx->Array.EdgeFlagEnabled) {
833 while (remaining>0) {
837 n =
MIN2( vbspace, remaining );
853 VB->Edgeflag[
VB->Start+
i] =
ctx->Current.EdgeFlag;
860 VB->Count =
VB->Start +
n;
868 else if (!
ctx->CompileFlag
869 &&
ctx->Light.Enabled
870 && !
ctx->Texture.Enabled
872 &&
ctx->Array.VertexStride==0 &&
ctx->Array.VertexSize==4
874 &&
ctx->Array.NormalStride==0
875 && !
ctx->Array.ColorEnabled
876 && !
ctx->Array.IndexEnabled
877 && !
ctx->Array.TexCoordEnabled
878 && !
ctx->Array.EdgeFlagEnabled) {
882 GLfloat (*vptr)[4], (*nptr)[3];
892 while (remaining>0) {
896 n =
MIN2( vbspace, remaining );
900 ctx->Transform.Normalize );
906 VB->Edgeflag[
VB->Start+
i] =
ctx->Current.EdgeFlag;
913 VB->Count =
VB->Start +
n;
922 else if (!
ctx->CompileFlag
923 &&
ctx->Light.Enabled
924 && !
ctx->Texture.Enabled
926 &&
ctx->Array.VertexStride==0 &&
ctx->Array.VertexSize==3
928 &&
ctx->Array.NormalStride==0
929 && !
ctx->Array.ColorEnabled
930 && !
ctx->Array.IndexEnabled
931 && !
ctx->Array.TexCoordEnabled
932 && !
ctx->Array.EdgeFlagEnabled) {
936 GLfloat (*vptr)[3], (*nptr)[3];
946 while (remaining>0) {
950 n =
MIN2( vbspace, remaining );
954 ctx->Transform.Normalize );
960 VB->Edgeflag[
VB->Start+
i] =
ctx->Current.EdgeFlag;
967 VB->Count =
VB->Start +
n;
1167 GLint tcomps, ccomps, vcomps;
1169 GLint coffset, noffset, voffset;
1184 tcomps = 0; ccomps = 0; vcomps = 2;
1190 tcomps = 0; ccomps = 0; vcomps = 3;
1196 tcomps = 0; ccomps = 4; vcomps = 2;
1200 defstride =
c + 2*
f;
1204 tcomps = 0; ccomps = 4; vcomps = 3;
1208 defstride =
c + 3*
f;
1212 tcomps = 0; ccomps = 3; vcomps = 3;
1220 tcomps = 0; ccomps = 0; vcomps = 3;
1227 tcomps = 0; ccomps = 4; vcomps = 3;
1236 tcomps = 2; ccomps = 0; vcomps = 3;
1242 tcomps = 4; ccomps = 0; vcomps = 4;
1248 tcomps = 2; ccomps = 4; vcomps = 3;
1256 tcomps = 2; ccomps = 3; vcomps = 3;
1264 tcomps = 2; ccomps = 0; vcomps = 3;
1271 tcomps = 2; ccomps = 4; vcomps = 3;
1280 tcomps = 4; ccomps = 4; vcomps = 4;
while(CdLookupNextInitialFileDirent(IrpContext, Fcb, FileContext))
void gl_save_Begin(GLcontext *ctx, GLenum mode)
void gl_save_End(GLcontext *ctx)
void gl_problem(const GLcontext *ctx, const char *s)
void gl_error(GLcontext *ctx, GLenum error, const char *s)
void gl_DisableClientState(GLcontext *ctx, GLenum cap)
void gl_EnableClientState(GLcontext *ctx, GLenum cap)
GLAPI void GLAPIENTRY glTexCoord1iv(const GLint *v)
GLAPI void GLAPIENTRY glVertex2dv(const GLdouble *v)
#define GL_TEXTURE_COORD_ARRAY
GLAPI void GLAPIENTRY glColor4usv(const GLushort *v)
GLAPI void GLAPIENTRY glTexCoord4dv(const GLdouble *v)
GLAPI void GLAPIENTRY glVertex4sv(const GLshort *v)
GLAPI void GLAPIENTRY glTexCoord3iv(const GLint *v)
GLAPI void GLAPIENTRY glVertex2iv(const GLint *v)
GLAPI void GLAPIENTRY glIndexdv(const GLdouble *c)
GLAPI void GLAPIENTRY glVertex4dv(const GLdouble *v)
GLAPI void GLAPIENTRY glColor4iv(const GLint *v)
GLAPI void GLAPIENTRY glIndexiv(const GLint *c)
GLAPI void GLAPIENTRY glVertex4iv(const GLint *v)
GLAPI void GLAPIENTRY glTexCoord3sv(const GLshort *v)
#define GL_UNSIGNED_SHORT
GLAPI void GLAPIENTRY glVertex2sv(const GLshort *v)
GLAPI void GLAPIENTRY glNormal3bv(const GLbyte *v)
GLAPI void GLAPIENTRY glColor3fv(const GLfloat *v)
GLAPI void GLAPIENTRY glVertex3sv(const GLshort *v)
GLAPI void GLAPIENTRY glTexCoord3fv(const GLfloat *v)
GLAPI void GLAPIENTRY glNormal3iv(const GLint *v)
GLAPI void GLAPIENTRY glVertex3iv(const GLint *v)
#define GL_T2F_C4F_N3F_V3F
GLAPI void GLAPIENTRY glNormal3sv(const GLshort *v)
GLAPI void GLAPIENTRY glVertex3dv(const GLdouble *v)
GLuint GLuint GLsizei GLenum type
#define GL_INVALID_OPERATION
GLAPI void GLAPIENTRY glColor3sv(const GLshort *v)
GLAPI void GLAPIENTRY glTexCoord4fv(const GLfloat *v)
GLAPI void GLAPIENTRY glTexCoord1dv(const GLdouble *v)
GLAPI void GLAPIENTRY glEdgeFlagv(const GLboolean *flag)
GLAPI void GLAPIENTRY glTexCoord2fv(const GLfloat *v)
GLAPI void GLAPIENTRY glTexCoord2dv(const GLdouble *v)
GLAPI void GLAPIENTRY glVertex4fv(const GLfloat *v)
GLAPI void GLAPIENTRY glColor4dv(const GLdouble *v)
GLAPI void GLAPIENTRY glColor4sv(const GLshort *v)
GLAPI void GLAPIENTRY glColor3ubv(const GLubyte *v)
GLAPI void GLAPIENTRY glTexCoord4iv(const GLint *v)
GLAPI void GLAPIENTRY glColor3dv(const GLdouble *v)
GLAPI void GLAPIENTRY glNormal3dv(const GLdouble *v)
GLAPI void GLAPIENTRY glColor3usv(const GLushort *v)
#define GL_T4F_C4F_N3F_V4F
GLAPI void GLAPIENTRY glTexCoord1fv(const GLfloat *v)
GLAPI void GLAPIENTRY glTexCoord4sv(const GLshort *v)
GLAPI void GLAPIENTRY glVertex3fv(const GLfloat *v)
GLAPI void GLAPIENTRY glTexCoord3dv(const GLdouble *v)
GLuint GLuint GLsizei count
GLint GLint GLsizei GLsizei GLsizei GLint GLenum format
GLAPI void GLAPIENTRY glColor4ubv(const GLubyte *v)
GLAPI void GLAPIENTRY glTexCoord1sv(const GLshort *v)
GLAPI void GLAPIENTRY glColor3uiv(const GLuint *v)
GLAPI void GLAPIENTRY glIndexsv(const GLshort *c)
GLAPI void GLAPIENTRY glTexCoord2sv(const GLshort *v)
GLAPI void GLAPIENTRY glColor3bv(const GLbyte *v)
GLAPI void GLAPIENTRY glIndexfv(const GLfloat *c)
#define GL_EDGE_FLAG_ARRAY
GLAPI void GLAPIENTRY glColor4bv(const GLbyte *v)
GLAPI void GLAPIENTRY glColor4uiv(const GLuint *v)
#define GL_TRIANGLE_STRIP
GLAPI void GLAPIENTRY glColor4fv(const GLfloat *v)
GLAPI void GLAPIENTRY glNormal3fv(const GLfloat *v)
GLuint GLuint GLsizei GLenum const GLvoid * indices
GLAPI void GLAPIENTRY glTexCoord2iv(const GLint *v)
GLAPI void GLAPIENTRY glColor3iv(const GLint *v)
GLAPI void GLAPIENTRY glVertex2fv(const GLfloat *v)
GLsizei const GLvoid * pointer
GLboolean GLboolean GLboolean b
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
#define SHORT_TO_FLOAT(S)
#define INSIDE_BEGIN_END(CTX)
#define COPY_4UBV(DST, SRC)
#define COPY_4V(DST, SRC)
void gl_set_material(GLcontext *ctx, GLuint bitmask, const GLfloat *params)
struct vertex_buffer * VB
void gl_DrawArrays(GLcontext *ctx, GLenum mode, GLint first, GLsizei count)
void gl_InterleavedArrays(GLcontext *ctx, GLenum format, GLsizei stride, const GLvoid *pointer)
void gl_TexCoordPointer(GLcontext *ctx, GLint size, GLenum type, GLsizei stride, const GLvoid *ptr)
void gl_save_DrawElements(GLcontext *ctx, GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
void gl_save_DrawArrays(GLcontext *ctx, GLenum mode, GLint first, GLsizei count)
void gl_ArrayElement(GLcontext *ctx, GLint i)
void gl_IndexPointer(GLcontext *ctx, GLenum type, GLsizei stride, const GLvoid *ptr)
void gl_NormalPointer(GLcontext *ctx, GLenum type, GLsizei stride, const GLvoid *ptr)
void gl_DrawElements(GLcontext *ctx, GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
void gl_save_ArrayElement(GLcontext *ctx, GLint i)
void gl_save_InterleavedArrays(GLcontext *ctx, GLenum format, GLsizei stride, const GLvoid *pointer)
void gl_VertexPointer(GLcontext *ctx, GLint size, GLenum type, GLsizei stride, const GLvoid *ptr)
void gl_EdgeFlagPointer(GLcontext *ctx, GLsizei stride, const GLboolean *ptr)
void gl_ColorPointer(GLcontext *ctx, GLint size, GLenum type, GLsizei stride, const GLvoid *ptr)
void gl_End(GLcontext *ctx)
void gl_Begin(GLcontext *ctx, GLenum p)