Cube  Diff

Differences From Artifact [6ee2ffc9ed]:

To Artifact [0379a81562]:


52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
		        @"lighting model!");

	glGetIntegerv(GL_MAX_TEXTURE_SIZE, &glmaxtexsize);

	purgetextures();

	if (!(qsphere = gluNewQuadric()))
		fatal("glu sphere");
	gluQuadricDrawStyle(qsphere, GLU_FILL);
	gluQuadricOrientation(qsphere, GLU_INSIDE);
	gluQuadricTexture(qsphere, GL_TRUE);
	glNewList(1, GL_COMPILE);
	gluSphere(qsphere, 1, 12, 6);
	glEndList();
};







|







52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
		        @"lighting model!");

	glGetIntegerv(GL_MAX_TEXTURE_SIZE, &glmaxtexsize);

	purgetextures();

	if (!(qsphere = gluNewQuadric()))
		fatal(@"glu sphere");
	gluQuadricDrawStyle(qsphere, GLU_FILL);
	gluQuadricOrientation(qsphere, GLU_INSIDE);
	gluQuadricTexture(qsphere, GL_TRUE);
	glNewList(1, GL_COMPILE);
	gluSphere(qsphere, 1, 12, 6);
	glEndList();
};
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
		    texname); // for voodoo cards under linux
		scaledimg = alloc(xs * ys * 3);
		gluScaleImage(GL_RGB, s->w, s->h, GL_UNSIGNED_BYTE, s->pixels,
		    xs, ys, GL_UNSIGNED_BYTE, scaledimg);
	};
	if (gluBuild2DMipmaps(GL_TEXTURE_2D, GL_RGB, xs, ys, GL_RGB,
	        GL_UNSIGNED_BYTE, scaledimg))
		fatal("could not build mipmaps");
	if (xs != s->w)
		free(scaledimg);
	SDL_FreeSurface(s);
	return true;
};

// management of texture slots







|







107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
		    texname); // for voodoo cards under linux
		scaledimg = alloc(xs * ys * 3);
		gluScaleImage(GL_RGB, s->w, s->h, GL_UNSIGNED_BYTE, s->pixels,
		    xs, ys, GL_UNSIGNED_BYTE, scaledimg);
	};
	if (gluBuild2DMipmaps(GL_TEXTURE_2D, GL_RGB, xs, ys, GL_RGB,
	        GL_UNSIGNED_BYTE, scaledimg))
		fatal(@"could not build mipmaps");
	if (xs != s->w)
		free(scaledimg);
	SDL_FreeSurface(s);
	return true;
};

// management of texture slots
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
			xs = texx[i];
			ys = texy[i];
			return tid;
		};
	};

	if (curtex == MAXTEX)
		fatal("loaded too many textures");

	int tnum = curtex + FIRSTTEX;
	strcpy_s(texname[curtex], mapname[tex][frame]);

	sprintf_sd(name)("packages%c%s", PATHDIV, texname[curtex]);

	if (installtex(tnum, name, xs, ys)) {







|







187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
			xs = texx[i];
			ys = texy[i];
			return tid;
		};
	};

	if (curtex == MAXTEX)
		fatal(@"loaded too many textures");

	int tnum = curtex + FIRSTTEX;
	strcpy_s(texname[curtex], mapname[tex][frame]);

	sprintf_sd(name)("packages%c%s", PATHDIV, texname[curtex]);

	if (installtex(tnum, name, xs, ys)) {