projects
/
xscreensaver
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
From http://www.jwz.org/xscreensaver/xscreensaver-5.18.tar.gz
[xscreensaver]
/
hacks
/
flame.c
diff --git
a/hacks/flame.c
b/hacks/flame.c
index 01f16ababa6c235a7e66b03c2781d0992570d9f6..eed6287cefd3a6141475b8100533527789d6fb8a 100644
(file)
--- a/
hacks/flame.c
+++ b/
hacks/flame.c
@@
-173,7
+173,7
@@
flame_init (Display *dpy, Window window)
static int
recurse (struct state *st, double x, double y, int l, Display *dpy, Window win)
{
static int
recurse (struct state *st, double x, double y, int l, Display *dpy, Window win)
{
- int
/*xp, yp,*/
i;
+ int i;
double nx, ny;
if (l == st->max_levels)
double nx, ny;
if (l == st->max_levels)
@@
-184,8
+184,8
@@
recurse (struct state *st, double x, double y, int l, Display *dpy, Window win)
if (x > -1.0 && x < 1.0 && y > -1.0 && y < 1.0)
{
if (x > -1.0 && x < 1.0 && y > -1.0 && y < 1.0)
{
-
/* xp =
st->points[st->num_points].x = (int) ((st->width / 2) * (x + 1.0));
- yp = st->points[st->num_points].y = (int) ((st->height / 2) * (y + 1.0));*/
+
st->points[st->num_points].x = (int) ((st->width / 2) * (x + 1.0));
+ st->points[st->num_points].y = (int) ((st->height / 2) * (y + 1.0));
st->num_points++;
if (st->num_points >= POINT_BUFFER_SIZE)
{
st->num_points++;
if (st->num_points >= POINT_BUFFER_SIZE)
{
@@
-434,6
+434,9
@@
static void
flame_reshape (Display *dpy, Window window, void *closure,
unsigned int w, unsigned int h)
{
flame_reshape (Display *dpy, Window window, void *closure,
unsigned int w, unsigned int h)
{
+ struct state *st = (struct state *) closure;
+ st->width = w;
+ st->height = h;
}
static Bool
}
static Bool