~ubuntu-branches/ubuntu/vivid/fyre/vivid

« back to all changes in this revision

Viewing changes to src/bifurcation-diagram.c

  • Committer: Bazaar Package Importer
  • Author(s): Christoph Haas
  • Date: 2006-10-22 20:33:21 UTC
  • mfrom: (2.1.1 etch)
  • Revision ID: james.westby@ubuntu.com-20061022203321-xlc2dvrxbptdojtf
Tags: 1.0.1-1
* New upstream release
* Patch from Sebastian Dröge included to avoid libcairo dependency.

Show diffs side-by-side

added added

removed removed

Lines of Context:
6
6
 *                         image at those parameters.
7
7
 *
8
8
 * Fyre - rendering and interactive exploration of chaotic functions
9
 
 * Copyright (C) 2004-2005 David Trowbridge and Micah Dowty
 
9
 * Copyright (C) 2004-2006 David Trowbridge and Micah Dowty
10
10
 *
11
11
 * This program is free software; you can redistribute it and/or
12
12
 * modify it under the terms of the GNU General Public License
171
171
 
172
172
        /* Shuffle them, so we render in a seemingly-random order */
173
173
        for (i=self->num_columns-1; i>=0; i--) {
174
 
            j = g_random_int_range(0, i+1);
 
174
            j = int_variate(0, i+1);
175
175
            tmp = self->columns[i].ix;
176
176
            self->columns[i].ix = self->columns[j].ix;
177
177
            self->columns[j].ix = tmp;
222
222
                                                   BifurcationColumn  *column,
223
223
                                                   DeJongParams       *param) {
224
224
    /* Get a random parameter set from the given column, creating it if necessary */
225
 
    int interpIndex = g_random_int_range(0, sizeof(self->columns[0].interpolated)/
226
 
                                         sizeof(self->columns[0].interpolated[0]));
 
225
    int interpIndex = int_variate(0, sizeof(self->columns[0].interpolated)/
 
226
                                  sizeof(self->columns[0].interpolated[0]));
227
227
 
228
228
    if (!column->interpolated[interpIndex].valid) {
229
229