line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package SDL2::HapticConstant { |
2
|
2
|
|
|
2
|
|
14
|
use SDL2::Utils; |
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
14
|
|
3
|
|
|
|
|
|
|
has |
4
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
# Header |
6
|
|
|
|
|
|
|
type => 'uint16', |
7
|
|
|
|
|
|
|
direction => 'opaque', # SDL_HapticDirection |
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
# Replay |
10
|
|
|
|
|
|
|
length => 'uint32', |
11
|
|
|
|
|
|
|
delay => 'uint16', |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
# Trigger |
14
|
|
|
|
|
|
|
button => 'uint16', |
15
|
|
|
|
|
|
|
interval => 'uint16', |
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
# Constant |
18
|
|
|
|
|
|
|
level => 'sint16', |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
# Envelope |
21
|
|
|
|
|
|
|
attack_length => 'uint16', |
22
|
|
|
|
|
|
|
attack_level => 'uint16', |
23
|
|
|
|
|
|
|
fade_length => 'uint16', |
24
|
|
|
|
|
|
|
fade_level => 'uint16'; |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
=encoding utf-8 |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
=head1 NAME |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
SDL2::HapticConstant - A structure containing a template for a Constant effect |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
=head1 SYNOPSIS |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
use SDL2 qw[:all]; |
35
|
|
|
|
|
|
|
# TODO: I need to whip up a quick example |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
=head1 DESCRIPTION |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
A SDL2::HapticConstant is exclusively for the C effect. |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
A constant effect applies a constant force in the specified direction to the |
42
|
|
|
|
|
|
|
joystick. |
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
=head1 Fields |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
=over |
47
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
=item C - C |
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
=item C - Direction of the effect |
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
=item C - Duration of the effect |
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
=item C - Delay before starting the effect |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
=item C |
57
|
|
|
|
|
|
|
|
58
|
|
|
|
|
|
|
=item C - How soon it can be triggered again after button |
59
|
|
|
|
|
|
|
|
60
|
|
|
|
|
|
|
=item C - Strength of the constant effect |
61
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
=item C - Duration of the attack |
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
=item C - Level at the start of the attack |
65
|
|
|
|
|
|
|
|
66
|
|
|
|
|
|
|
=item C - Duration of the fade |
67
|
|
|
|
|
|
|
|
68
|
|
|
|
|
|
|
=item C - Level at the end of the fade |
69
|
|
|
|
|
|
|
|
70
|
|
|
|
|
|
|
=back |
71
|
|
|
|
|
|
|
|
72
|
|
|
|
|
|
|
=head1 AUTHOR |
73
|
|
|
|
|
|
|
|
74
|
|
|
|
|
|
|
Sanko Robinson Esanko@cpan.orgE |
75
|
|
|
|
|
|
|
|
76
|
|
|
|
|
|
|
=begin stopwords |
77
|
|
|
|
|
|
|
|
78
|
|
|
|
|
|
|
|
79
|
|
|
|
|
|
|
=end stopwords |
80
|
|
|
|
|
|
|
|
81
|
|
|
|
|
|
|
=cut |
82
|
|
|
|
|
|
|
|
83
|
|
|
|
|
|
|
}; |
84
|
|
|
|
|
|
|
1; |