mirror of
https://github.com/onyx-and-iris/voicemeeter-rb.git
synced 2024-11-22 09:50:49 +00:00
use map to build vban instream/outstream
This commit is contained in:
parent
4b311520d4
commit
b047d6c706
@ -48,10 +48,8 @@ module Voicemeeter
|
|||||||
|
|
||||||
def initialize(remote)
|
def initialize(remote)
|
||||||
vban_in, vban_out = remote.kind.vban
|
vban_in, vban_out = remote.kind.vban
|
||||||
@instream = []
|
@instream = (0...vban_in).map { |i| VbanInstream.new(remote, i) }
|
||||||
vban_in.times { |i| @instream << VbanInstream.new(remote, i) }
|
@outstream = (0...vban_out).map { |i| VbanOutstream.new(remote, i) }
|
||||||
@outstream = []
|
|
||||||
vban_out.times { |i| @outstream << VbanOutstream.new(remote, i) }
|
|
||||||
|
|
||||||
@remote = remote
|
@remote = remote
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user