voicemeeter_api_ruby 4.1.5 → 4.2.0

Sign up to get free protection for your applications and to get access to all the features.
data/lib/vban.rb DELETED
@@ -1,78 +0,0 @@
1
- require_relative "iremote"
2
- require_relative "meta"
3
- require_relative "errors"
4
-
5
- class VbanStream < IRemote
6
- "
7
- A class representing a VBAN stream
8
- "
9
- include Vban_Meta_Functions
10
-
11
- def initialize(remote, i)
12
- super
13
- self.make_accessor_bool :on
14
- self.make_accessor_string :name, :ip
15
- self.make_accessor_int :quality, :route
16
- end
17
-
18
- def identifier
19
- "vban.#{self.direction}stream[#{@index}]"
20
- end
21
-
22
- def direction
23
- raise "Called abstract mehod: direction"
24
- end
25
- end
26
-
27
- class VbanInstream < VbanStream
28
- "
29
- A subclass representing a VBAN Instream
30
- "
31
- def initialize(remote, i)
32
- super
33
- self.make_reader_int :sr, :channel, :bit
34
- end
35
-
36
- def direction
37
- :in
38
- end
39
- end
40
-
41
- class VbanOutstream < VbanStream
42
- "
43
- A subclass representing a VBAN Outstream
44
- "
45
- def initialize(remote, i)
46
- super
47
- self.make_accessor_int :sr, :channel, :bit
48
- end
49
-
50
- def direction
51
- :out
52
- end
53
- end
54
-
55
- class Vban
56
- attr_accessor :instream, :outstream
57
-
58
- def initialize(remote, vban_streams)
59
- "
60
- Initializes a Vban class
61
-
62
- Creates an array for each in/out stream
63
- "
64
- vban_in, vban_out = vban_streams.values
65
- self.instream = (0...vban_in).map { |i| VbanInstream.new(remote, i) }
66
- self.outstream = (0...vban_out).map { |i| VbanOutstream.new(remote, i) }
67
-
68
- @remote = remote
69
- end
70
-
71
- def enable
72
- @remote.set_parameter("vban.enable", 1)
73
- end
74
-
75
- def disable
76
- @remote.set_parameter("vban.enable", 0)
77
- end
78
- end