~ubuntu-branches/ubuntu/raring/fyre/raring

« back to all changes in this revision

Viewing changes to src/de-jong.h

  • Committer: Bazaar Package Importer
  • Author(s): Christoph Haas
  • Date: 2005-05-25 21:59:19 UTC
  • Revision ID: james.westby@ubuntu.com-20050525215919-jawtso5ic23qb401
Tags: upstream-1.0.0
ImportĀ upstreamĀ versionĀ 1.0.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* -*- mode: c; c-basic-offset: 4; -*-
 
2
 *
 
3
 * de-jong.h - The DeJong object builds on the ParameterHolder and HistogramRender
 
4
 *             objects to provide a rendering of the DeJong map into a histogram image.
 
5
 *
 
6
 * Fyre - rendering and interactive exploration of chaotic functions
 
7
 * Copyright (C) 2004-2005 David Trowbridge and Micah Dowty
 
8
 *
 
9
 * This program is free software; you can redistribute it and/or
 
10
 * modify it under the terms of the GNU General Public License
 
11
 * as published by the Free Software Foundation; either version 2
 
12
 * of the License, or (at your option) any later version.
 
13
 *
 
14
 * This program is distributed in the hope that it will be useful,
 
15
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
16
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
17
 * GNU General Public License for more details.
 
18
 *
 
19
 * You should have received a copy of the GNU General Public License
 
20
 * along with this program; if not, write to the Free Software
 
21
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
 
22
 *
 
23
 */
 
24
 
 
25
#ifndef __DE_JONG_H__
 
26
#define __DE_JONG_H__
 
27
 
 
28
#include <gtk/gtk.h>
 
29
#include "iterative-map.h"
 
30
 
 
31
G_BEGIN_DECLS
 
32
 
 
33
#define DE_JONG_TYPE            (de_jong_get_type ())
 
34
#define DE_JONG(obj)            (G_TYPE_CHECK_INSTANCE_CAST ((obj), DE_JONG_TYPE, DeJong))
 
35
#define DE_JONG_CLASS(klass)    (G_TYPE_CHECK_CLASS_CAST ((klass), DE_JONG_TYPE, DeJongClass))
 
36
#define IS_DE_JONG(obj)         (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DE_JONG_TYPE))
 
37
#define IS_DE_JONG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DE_JONG_TYPE))
 
38
 
 
39
typedef struct _DeJong      DeJong;
 
40
typedef struct _DeJongClass DeJongClass;
 
41
 
 
42
typedef struct {
 
43
    gdouble a, b, c, d;
 
44
} DeJongParams;
 
45
 
 
46
struct _DeJong {
 
47
    IterativeMap parent;
 
48
 
 
49
    /* Calculation Parameters */
 
50
    DeJongParams param;
 
51
    gdouble zoom, aspect, xoffset, yoffset, rotation;
 
52
    gdouble blur_radius, blur_ratio;
 
53
    gboolean tileable;
 
54
 
 
55
    gboolean emphasize_transient;
 
56
    guint transient_iterations;
 
57
    gint initial_conditions;
 
58
    gdouble initial_xscale, initial_yscale;
 
59
    gdouble initial_xoffset, initial_yoffset;
 
60
 
 
61
    gboolean calc_dirty_flag;
 
62
 
 
63
    /* Current calculation state */
 
64
    gdouble point_x, point_y;
 
65
    guint remaining_transient_iterations;
 
66
};
 
67
 
 
68
struct _DeJongClass {
 
69
    IterativeMapClass parent_class;
 
70
};
 
71
 
 
72
 
 
73
/************************************************************************************/
 
74
/******************************************************************* Public Methods */
 
75
/************************************************************************************/
 
76
 
 
77
GType      de_jong_get_type         ();
 
78
DeJong*    de_jong_new              ();
 
79
 
 
80
G_END_DECLS
 
81
 
 
82
#endif /* __DE_JONG_H__ */
 
83
 
 
84
/* The End */