3 * gtk2 spectrum analyzer
5 * Copyright (C) 2004 Monty
7 * This analyzer is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 2, or (at your option)
12 * The analyzer is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with Postfish; see the file COPYING. If not, write to the
19 * Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
28 #include <glib-object.h>
29 #include <gtk/gtkcontainer.h>
30 #include <gtk/gtksignal.h>
31 #include <gtk/gtkdrawingarea.h>
35 #define PLOT_TYPE (plot_get_type ())
36 #define PLOT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), PLOT_TYPE, Plot))
37 #define PLOT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), PLOT_TYPE, PlotClass))
38 #define IS_PLOT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), PLOT_TYPE))
39 #define IS_PLOT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), PLOT_TYPE))
41 typedef struct _Plot Plot
;
42 typedef struct _PlotClass PlotClass
;
46 GtkDrawingArea canvas
;
51 PangoLayout
**lin_layout
;
52 PangoLayout
**log_layout
;
53 PangoLayout
**iso_layout
;
54 PangoLayout
**db_layout
;
55 PangoLayout
**imp_layout
;
56 PangoLayout
**phase_layout
;
105 GtkDrawingAreaClass parent_class
;
106 void (* plot
) (Plot
*m
);
109 GType
plot_get_type (void);
110 GtkWidget
* plot_new (int n
, int inputs
, int *channels
, int *rate
);
111 void plot_refresh (Plot
*m
, int *process
);
112 void plot_setting (Plot
*m
, int res
, int scale
, int mode
, int link
, int depth
, int noise
);
113 void plot_draw (Plot
*m
);
114 void plot_clear (Plot
*m
);
115 int plot_width (Plot
*m
);
116 float** plot_get (Plot
*m
);
117 void plot_set_active (Plot
*m
, int *, int *);
119 GdkColor
chcolor(int ch
);