~ubuntu-branches/ubuntu/quantal/xscreensaver/quantal

« back to all changes in this revision

Viewing changes to hacks/glx/mirrorblob.c

  • Committer: Bazaar Package Importer
  • Author(s): Ted Gould
  • Date: 2008-08-28 16:15:25 UTC
  • mfrom: (1.1.6 upstream) (2.1.3 lenny)
  • Revision ID: james.westby@ubuntu.com-20080828161525-mxga521aoezxjq8h
Tags: 5.07-0ubuntu1
* Upgrade upstream version
* debian/control: Remove suggest xdaliclock as it is no longer
  included
* Remove 10_jwz-screensaver-randr-patch-3.patch as it has been merged
  upstream.
* Add 24_hacks_xsublim_enable.patch as it seems that xsublim was dropped
  from the build files.  There is nothing in the Changelog about it
  so I believe it was accidental.
* Updating the .desktop files from the XML files using gnome-screensaver's
  utility to do so.  Lots of text updates.  Also:
    * Added: abstractile.desktop
    * Added: cwaves.desktop
    * Added: m6502.desktop
    * Added: skytentacles.desktop
    * Removed: xteevee.desktop
* xscreensaver-gl-extra.files: Added skytentacles
* xscreensaver-data-extra.files: Added abstractile, cwaves and m6502
* xscreensaver-data.files: Remove partial abstractile, m6502 and cwaves

Show diffs side-by-side

added added

removed removed

Lines of Context:
123
123
    {"+texture",          ".blob.texture",          XrmoptionNoArg, "false" },
124
124
    {"-colour",           ".blob.colour",           XrmoptionNoArg, "true" },
125
125
    {"+colour",           ".blob.colour",           XrmoptionNoArg, "false" },
126
 
    {"-offset-texture",   ".blob.offset_texture",   XrmoptionNoArg, "true" },
127
 
    {"+offset-texture",   ".blob.offset_texture",   XrmoptionNoArg, "false" },
128
 
    {"-paint-background", ".blob.paint_background", XrmoptionNoArg, "true" },
129
 
    {"+paint-background", ".blob.paint_background", XrmoptionNoArg, "false" },
 
126
    {"-offset-texture",   ".blob.offsetTexture",   XrmoptionNoArg, "true" },
 
127
    {"+offset-texture",   ".blob.offsetTexture",   XrmoptionNoArg, "false" },
 
128
    {"-paint-background", ".blob.paintBackground", XrmoptionNoArg, "true" },
 
129
    {"+paint-background", ".blob.paintBackground", XrmoptionNoArg, "false" },
130
130
    {"-resolution",       ".blob.resolution",       XrmoptionSepArg, NULL },
131
131
    {"-bumps",            ".blob.bumps",            XrmoptionSepArg, NULL },
132
 
    {"-motion-blur",      ".blob.motion_blur",      XrmoptionSepArg, 0 },
133
 
    {"-fade-time",        ".blob.fade_time",        XrmoptionSepArg, 0 },
134
 
    {"-hold-time",        ".blob.hold_time",        XrmoptionSepArg, 0 },
 
132
    {"-motion-blur",      ".blob.motionBlur",       XrmoptionSepArg, 0 },
 
133
    {"-fade-time",        ".blob.fadeTime",         XrmoptionSepArg, 0 },
 
134
    {"-hold-time",        ".blob.holdTime",         XrmoptionSepArg, 0 },
135
135
    {"-zoom",             ".blob.zoom",             XrmoptionSepArg, 0 },
136
136
};
137
137
 
143
143
    {&do_walls,     "walls",        "Walls",     DEF_WALLS,     t_Bool},
144
144
    {&do_texture,   "texture",      "Texture",   DEF_TEXTURE,   t_Bool},
145
145
    {&do_colour,    "colour",       "Colour",    DEF_COLOUR,   t_Bool},
146
 
    {&offset_texture, "offset_texture","Offset_Texture", DEF_OFFSET_TEXTURE, t_Bool},
147
 
    {&do_paint_background,"paint_background","Paint_Background", DEF_PAINT_BACKGROUND, t_Bool},
 
146
    {&offset_texture, "offsetTexture","OffsetTexture", DEF_OFFSET_TEXTURE, t_Bool},
 
147
    {&do_paint_background,"paintBackground","PaintBackground", DEF_PAINT_BACKGROUND, t_Bool},
148
148
    {&resolution,   "resolution",   "Resolution",   DEF_RESOLUTION,   t_Int},
149
149
    {&bumps,        "bumps",        "Bump",         DEF_BUMPS, t_Int},
150
 
    {&motion_blur,  "motion_blur",  "Motion_Blur",  DEF_MOTION_BLUR,  t_Float},
151
 
    {&fade_time,    "fade_time",    "Fade_Time",    DEF_FADE_TIME,    t_Float},
152
 
    {&hold_time,    "hold_time",    "Hold_Time",    DEF_HOLD_TIME,    t_Float},
 
150
    {&motion_blur,  "motionBlur",   "MotionBlur",   DEF_MOTION_BLUR,  t_Float},
 
151
    {&fade_time,    "fadeTime",     "FadeTime",     DEF_FADE_TIME,    t_Float},
 
152
    {&hold_time,    "holdTime",     "HoldTime",     DEF_HOLD_TIME,    t_Float},
153
153
    {&zoom,         "zoom",         "Zoom",         DEF_ZOOM,         t_Float},
154
154
};
155
155
 
1429
1429
    double current_time;
1430
1430
    check_gl_error ("draw_scene");
1431
1431
 
 
1432
    mi->polygon_count = 0;
1432
1433
    glColor4d(1.0, 1.0, 1.0, 1.0);
1433
1434
 
1434
1435
    current_time = double_time();
1468
1469
            glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
1469
1470
        }
1470
1471
        draw_background (mi);
 
1472
        mi->polygon_count++;
1471
1473
 
1472
1474
        /* When transitioning between two images paint the new image over the old
1473
1475
         * image with a varying alpha value to get a smooth fade.
1480
1482
            glColor4d (1.0, 1.0, 1.0, 1.0 - fade);
1481
1483
 
1482
1484
            draw_background (mi);
 
1485
            mi->polygon_count++;
1483
1486
 
1484
1487
            /* Select the original texture to draw the blob */
1485
1488
            glBindTexture (GL_TEXTURE_2D, gp->textures[gp->current_texture]);
1520
1523
        /* Disable the three colour chanels so that only the depth buffer is updated */
1521
1524
        glColorMask(GL_FALSE, GL_FALSE, GL_FALSE, GL_FALSE);
1522
1525
        draw_blob(gp);
 
1526
        mi->polygon_count += gp->num_faces;
1523
1527
        glColorMask(GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE);
1524
1528
        glDepthFunc(GL_LEQUAL);
1525
1529
    }
1526
1530
    glDepthFunc(GL_LEQUAL);
1527
1531
    draw_blob(gp);
 
1532
    mi->polygon_count += gp->num_faces;
1528
1533
 
1529
1534
    /* While transitioning between images draw a second blob with a modified
1530
1535
     * alpha value.
1583
1588
                }
1584
1589
 
1585
1590
                draw_blob (gp);
 
1591
                mi->polygon_count += gp->num_faces;
1586
1592
 
1587
1593
                if (do_colour)
1588
1594
                {