File: blender.h

package info (click to toggle)
freebirth 0.3.2-9.2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, sid, stretch
  • size: 3,632 kB
  • ctags: 640
  • sloc: ansic: 4,724; makefile: 89; sh: 1
file content (59 lines) | stat: -rw-r--r-- 1,698 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
/* Freebirth
 * Copyright (C) 1999 topher lafata <topher@topher.com>,
 *		      Jake Donham <jake@bitmechanic.com>
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public
 * License as published by the Free Software Foundation; either
 * version 2 of the License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.	 See the GNU
 * General Public License for more details.
 *
 * You should have received a copy of the GNU General Public
 * License along with this program (see COPYING); if not, write to the
 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
 * Boston, MA 02111-1307, USA.
 */

#define __BLENDER_H

#ifndef __SAMPLE_PRODUCER_H
  #include "sample_producer.h"
#endif

#define BLEND_MAX_AMP 32768
#define BLEND_MIN_AMP 0

typedef struct blender{

  sample *(* get_buffer)(struct blender *);
  void (*next_buffer)(struct blender *);
  sample_producer **(*get_children)(struct blender *);
  char **(*get_header)(struct blender *);
  char **(*get_code)(struct blender *);
  char **(*get_footer)(struct blender *);
  char **header;
  char **code;
  int next;
  sample_producer **source;
  sample *buffer;
  sample **bufs;
  int *strength;
  int length;
  int blend_factor;

}blender;

blender *blender_new(sample_producer **sources);
void blender_next_buffer(blender *this);
sample *blender_get_buffer(blender *this);
void blender_set_strength(blender *this,int amp,int index);

/*
  Local Variables:
  mode: font-lock
  End:
*/