projects
/
xscreensaver
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
http://ftp.x.org/contrib/applications/xscreensaver-3.07.tar.gz
[xscreensaver]
/
hacks
/
glx
/
moebius.c
diff --git
a/hacks/glx/moebius.c
b/hacks/glx/moebius.c
index 3fd933c7a3523b00bacffdbe3584c984d71fe454..66560fca5448766521580b0374ef620a02ed3657 100644
(file)
--- a/
hacks/glx/moebius.c
+++ b/
hacks/glx/moebius.c
@@
-38,9
+38,7
@@
static const char sccsid[] = "@(#)moebius.c 4.08 97/01/04 xlockmore";
* Since I'm not a native English speaker, my apologies for any grammatical
* mistake.
*
* Since I'm not a native English speaker, my apologies for any grammatical
* mistake.
*
- * My e-mail addresses are
- * vianna@cat.cbpf.br
- * and
+ * My e-mail address is
* m-vianna@usa.net
*
* Marcelo F. Vianna (Jun-01-1997)
* m-vianna@usa.net
*
* Marcelo F. Vianna (Jun-01-1997)
@@
-108,8
+106,8
@@
static int noants;
static XrmOptionDescRec opts[] =
{
static XrmOptionDescRec opts[] =
{
-
{"-solidmoebius", ".moebius.solidmoebius", XrmoptionNoArg, (caddr_t) "on"},
-
{"+solidmoebius", ".moebius.solidmoebius", XrmoptionNoArg, (caddr_t) "off"},
+ {"-solidmoebius", ".moebius.solidmoebius", XrmoptionNoArg, (caddr_t) "on"},
+ {"+solidmoebius", ".moebius.solidmoebius", XrmoptionNoArg, (caddr_t) "off"},
{"-noants", ".moebius.noants", XrmoptionNoArg, (caddr_t) "on"},
{"+noants", ".moebius.noants", XrmoptionNoArg, (caddr_t) "off"}
};
{"-noants", ".moebius.noants", XrmoptionNoArg, (caddr_t) "on"},
{"+noants", ".moebius.noants", XrmoptionNoArg, (caddr_t) "off"}
};
@@
-125,13
+123,13
@@
static OptionStruct desc[] =
};
ModeSpecOpt moebius_opts =
};
ModeSpecOpt moebius_opts =
-{
4, opts, 2
, vars, desc};
+{
sizeof opts / sizeof opts[0], opts, sizeof vars / sizeof vars[0]
, vars, desc};
#ifdef USE_MODULES
ModStruct moebius_description =
{"moebius", "init_moebius", "draw_moebius", "release_moebius",
"draw_moebius", "change_moebius", NULL, &moebius_opts,
#ifdef USE_MODULES
ModStruct moebius_description =
{"moebius", "init_moebius", "draw_moebius", "release_moebius",
"draw_moebius", "change_moebius", NULL, &moebius_opts,
- 1000, 1, 1, 1, 1.0, "",
+ 1000, 1, 1, 1,
4,
1.0, "",
"Shows Moebius Strip II, an Escher-like GL scene with ants", 0, NULL};
#endif
"Shows Moebius Strip II, an Escher-like GL scene with ants", 0, NULL};
#endif
@@
-424,7
+422,7
@@
draw_moebius_strip(ModeInfo * mi)
GLfloat cPhi, sPhi;
moebiusstruct *mp = &moebius[MI_SCREEN(mi)];
int i, j;
GLfloat cPhi, sPhi;
moebiusstruct *mp = &moebius[MI_SCREEN(mi)];
int i, j;
- int mono = MI_
WIN_
IS_MONO(mi);
+ int mono = MI_IS_MONO(mi);
float Cx, Cy, Cz;
float Cx, Cy, Cz;
@@
-624,7
+622,7
@@
init_moebius(ModeInfo * mi)
if (moebius == NULL) {
if ((moebius = (moebiusstruct *) calloc(MI_NUM_SCREENS(mi),
if (moebius == NULL) {
if ((moebius = (moebiusstruct *) calloc(MI_NUM_SCREENS(mi),
-
sizeof (moebiusstruct))) == NULL)
+ sizeof (moebiusstruct))) == NULL)
return;
}
mp = &moebius[screen];
return;
}
mp = &moebius[screen];
@@
-633,13
+631,13
@@
init_moebius(ModeInfo * mi)
if ((mp->glx_context = init_GL(mi)) != NULL) {
if ((mp->glx_context = init_GL(mi)) != NULL) {
- reshape(mi, MI_WI
N_WIDTH(mi), MI_WIN
_HEIGHT(mi));
+ reshape(mi, MI_WI
DTH(mi), MI
_HEIGHT(mi));
glDrawBuffer(GL_BACK);
if (!glIsList(objects))
objects = glGenLists(3);
pinit();
} else {
glDrawBuffer(GL_BACK);
if (!glIsList(objects))
objects = glGenLists(3);
pinit();
} else {
- MI_CLEARWINDOW(mi);
+
MI_CLEARWINDOW(mi);
}
}
}
}
@@
-662,13
+660,13
@@
draw_moebius(ModeInfo * mi)
glTranslatef(0.0, 0.0, -10.0);
glTranslatef(0.0, 0.0, -10.0);
- if (!MI_
WIN_
IS_ICONIC(mi)) {
+ if (!MI_IS_ICONIC(mi)) {
glScalef(Scale4Window * mp->WindH / mp->WindW, Scale4Window, Scale4Window);
} else {
glScalef(Scale4Iconic * mp->WindH / mp->WindW, Scale4Iconic, Scale4Iconic);
}
glScalef(Scale4Window * mp->WindH / mp->WindW, Scale4Window, Scale4Window);
} else {
glScalef(Scale4Iconic * mp->WindH / mp->WindW, Scale4Iconic, Scale4Iconic);
}
- /* moebius */
+
/* moebius */
glRotatef(mp->step * 100, 1, 0, 0);
glRotatef(mp->step * 95, 0, 1, 0);
glRotatef(mp->step * 90, 0, 0, 1);
glRotatef(mp->step * 100, 1, 0, 0);
glRotatef(mp->step * 95, 0, 1, 0);
glRotatef(mp->step * 90, 0, 0, 1);