line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
#_{ Encoding and name |
2
|
|
|
|
|
|
|
=encoding utf8 |
3
|
|
|
|
|
|
|
=head1 NAME |
4
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
Csound::ScoreStatement |
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
L |
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
=cut |
10
|
|
|
|
|
|
|
#_} |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
package Csound::ScoreStatement::f; |
13
|
|
|
|
|
|
|
|
14
|
2
|
|
|
2
|
|
47429
|
use warnings; |
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
67
|
|
15
|
2
|
|
|
2
|
|
13
|
use strict; |
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
58
|
|
16
|
2
|
|
|
2
|
|
38
|
use 5.10.0; # state |
|
2
|
|
|
|
|
9
|
|
17
|
|
|
|
|
|
|
|
18
|
2
|
|
|
2
|
|
16
|
use Carp; |
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
126
|
|
19
|
|
|
|
|
|
|
|
20
|
2
|
|
|
2
|
|
231
|
use Csound::ScoreStatement; |
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
454
|
|
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
our $VERSION = $Csound::VERSION; |
23
|
|
|
|
|
|
|
our @ISA = qw(Csound::ScoreStatement); |
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
#_{ Synopsis |
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
=head1 SYNOPSIS |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
use Csound::ScoreStatement::f; |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
... |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
=cut |
34
|
|
|
|
|
|
|
#_} |
35
|
|
|
|
|
|
|
#_{ Description |
36
|
|
|
|
|
|
|
=head DESCRIPTION |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
The C statement causes a so called GEN subroutine to place values in a stored function table. |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
The syntax is |
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
f tableNumber actionTime size genRoutine … |
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
=cut |
45
|
|
|
|
|
|
|
#_} |
46
|
|
|
|
|
|
|
#_{ Methods |
47
|
|
|
|
|
|
|
#_{ |
48
|
|
|
|
|
|
|
=head1 METHODS |
49
|
|
|
|
|
|
|
=cut |
50
|
|
|
|
|
|
|
#_} |
51
|
|
|
|
|
|
|
sub new { #_{ |
52
|
|
|
|
|
|
|
#_{ POD |
53
|
|
|
|
|
|
|
=head2 new |
54
|
|
|
|
|
|
|
=cut |
55
|
|
|
|
|
|
|
#_} |
56
|
|
|
|
|
|
|
|
57
|
2
|
|
|
2
|
0
|
86
|
state $_table_nr = 0; |
58
|
|
|
|
|
|
|
|
59
|
2
|
|
|
|
|
3
|
my $class = shift; |
60
|
2
|
|
|
|
|
3
|
my $gen_nr = shift; |
61
|
2
|
|
|
|
|
4
|
my $size = shift; |
62
|
2
|
|
|
|
|
3
|
my @params = @_; |
63
|
|
|
|
|
|
|
|
64
|
2
|
|
|
|
|
3
|
my $self = {}; |
65
|
|
|
|
|
|
|
|
66
|
2
|
|
|
|
|
3
|
bless $self, $class; |
67
|
2
|
50
|
|
|
|
11
|
die unless $self->isa('Csound::ScoreStatement::f'); |
68
|
|
|
|
|
|
|
|
69
|
2
|
|
|
|
|
7
|
$self->{table_nr } = ++$_table_nr; |
70
|
2
|
|
|
|
|
3
|
$self->{t_action } = 0; # Currently always 0 |
71
|
2
|
|
|
|
|
4
|
$self->{gen_nr } = $gen_nr; |
72
|
2
|
|
|
|
|
3
|
$self->{size } = $size; |
73
|
2
|
|
|
|
|
4
|
$self->{parameters} =\@params; |
74
|
|
|
|
|
|
|
|
75
|
2
|
|
|
|
|
5
|
return $self; |
76
|
|
|
|
|
|
|
|
77
|
|
|
|
|
|
|
} #_} |
78
|
|
|
|
|
|
|
sub score_text { #_{ |
79
|
|
|
|
|
|
|
#_{ POD |
80
|
|
|
|
|
|
|
=head2 new |
81
|
|
|
|
|
|
|
=cut |
82
|
|
|
|
|
|
|
#_} |
83
|
|
|
|
|
|
|
|
84
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
85
|
0
|
0
|
|
|
|
|
die unless $self->isa('Csound::ScoreStatement::f'); |
86
|
|
|
|
|
|
|
|
87
|
0
|
|
|
|
|
|
return sprintf("f%d %d %d %d %s", $self->{table_nr}, $self->{t_action}, $self->{size}, $self->{gen_nr}, join " ", @{$self->{parameters}}); |
|
0
|
|
|
|
|
|
|
88
|
|
|
|
|
|
|
|
89
|
|
|
|
|
|
|
} #_} |
90
|
|
|
|
|
|
|
#_} |
91
|
|
|
|
|
|
|
#_{ POD: Copyright |
92
|
|
|
|
|
|
|
|
93
|
|
|
|
|
|
|
=head1 Copyright |
94
|
|
|
|
|
|
|
|
95
|
|
|
|
|
|
|
Copyright © 2017 René Nyffenegger, Switzerland. All rights reserved. |
96
|
|
|
|
|
|
|
This program is free software; you can redistribute it and/or modify it |
97
|
|
|
|
|
|
|
under the terms of the the Artistic License (2.0). You may obtain a |
98
|
|
|
|
|
|
|
copy of the full license at: L |
99
|
|
|
|
|
|
|
|
100
|
|
|
|
|
|
|
=cut |
101
|
|
|
|
|
|
|
|
102
|
|
|
|
|
|
|
#_} |
103
|
|
|
|
|
|
|
|
104
|
|
|
|
|
|
|
'tq84'; |