Mercurial > audlegacy-plugins
annotate src/rovascope/paranormal.h @ 1219:31c44eb25a4a
Fix more crashes and metadata.
author | William Pitcock <nenolod@atheme-project.org> |
---|---|
date | Sun, 08 Jul 2007 22:39:59 -0500 |
parents | f305ebcc8136 |
children |
rev | line source |
---|---|
149
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
1 #ifndef _PARANORMAL_H |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
2 #define _PARANORMAL_H |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
3 |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
4 #include <glib.h> |
1059 | 5 #include <math.h> |
6 #include <string.h> | |
7 #include <stdlib.h> | |
149
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
8 |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
9 #include "actuators.h" |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
10 |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
11 struct pn_sound_data |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
12 { |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
13 gint16 pcm_data[2][512]; |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
14 gint16 freq_data[2][256]; |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
15 }; |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
16 |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
17 struct pn_image_data |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
18 { |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
19 int width, height; |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
20 struct pn_color cmap[256]; |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
21 guchar *surface[2]; |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
22 }; |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
23 |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
24 /* The executable (ie xmms.c or standalone.c) |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
25 is responsible for allocating this and filling |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
26 it with default/saved values */ |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
27 struct pn_rc |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
28 { |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
29 struct pn_actuator *actuator; |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
30 }; |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
31 |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
32 /* core funcs */ |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
33 void pn_init (void); |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
34 void pn_cleanup (void); |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
35 void pn_render (void); |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
36 void pn_swap_surfaces (void); |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
37 |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
38 /* Implemented elsewhere (ie xmms.c or standalone.c) */ |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
39 void pn_set_rc (); |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
40 void pn_fatal_error (const char *fmt, ...); |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
41 void pn_error (const char *fmt, ...); |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
42 void pn_quit (void); |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
43 |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
44 /* Implimented in cfg.c */ |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
45 void pn_configure (void); |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
46 |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
47 /* globals used for rendering */ |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
48 extern struct pn_rc *pn_rc; |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
49 extern struct pn_sound_data *pn_sound_data; |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
50 extern struct pn_image_data *pn_image_data; |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
51 |
302 | 52 extern gboolean pn_new_beat; |
53 | |
149
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
54 /* global trig pre-computes */ |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
55 extern float sin_val[360]; |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
56 extern float cos_val[360]; |
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
57 |
170
13955c70fbec
[svn] - split out beat detection code into beatdetect.c
nenolod
parents:
149
diff
changeset
|
58 /* beat detection */ |
13955c70fbec
[svn] - split out beat detection code into beatdetect.c
nenolod
parents:
149
diff
changeset
|
59 int pn_is_new_beat(void); |
13955c70fbec
[svn] - split out beat detection code into beatdetect.c
nenolod
parents:
149
diff
changeset
|
60 |
408
290588854a9d
[svn] - rovascope -- a variant of the paranormal visualization engine that is
nenolod
parents:
302
diff
changeset
|
61 struct pn_actuator *rovascope_get_random_colourmap(void); |
290588854a9d
[svn] - rovascope -- a variant of the paranormal visualization engine that is
nenolod
parents:
302
diff
changeset
|
62 struct pn_actuator *rovascope_get_random_general(void); |
290588854a9d
[svn] - rovascope -- a variant of the paranormal visualization engine that is
nenolod
parents:
302
diff
changeset
|
63 struct pn_actuator *rovascope_get_random_normal_scope(void); |
290588854a9d
[svn] - rovascope -- a variant of the paranormal visualization engine that is
nenolod
parents:
302
diff
changeset
|
64 |
290588854a9d
[svn] - rovascope -- a variant of the paranormal visualization engine that is
nenolod
parents:
302
diff
changeset
|
65 struct pn_actuator *rovascope_get_random_actuator(void); |
290588854a9d
[svn] - rovascope -- a variant of the paranormal visualization engine that is
nenolod
parents:
302
diff
changeset
|
66 |
149
fd9c0a5871ac
[svn] - new and IMPROVED paranormal visualization studio
nenolod
parents:
diff
changeset
|
67 #endif /* _PARANORMAL_H */ |