@@ -32,19 +32,19 @@ public class LSLInput : MonoBehaviour
32
32
{
33
33
public string StreamType = " EEG" ;
34
34
public float scaleInput = 0 . 1 f ;
35
- liblsl .StreamInfo [] streamInfos ;
36
- liblsl .StreamInlet streamInlet ;
35
+ LSL .StreamInfo [] streamInfos ;
36
+ LSL .StreamInlet streamInlet ;
37
37
float [] sample ;
38
38
private int channelCount = 0 ;
39
39
40
40
void Update ()
41
41
{
42
42
if (streamInlet == null )
43
43
{
44
- streamInfos = liblsl .resolve_stream (" type" , StreamType , 1 , 0 . 0 );
44
+ streamInfos = LSL .resolve_stream (" type" , StreamType , 1 , 0 . 0 );
45
45
if (streamInfos .Length > 0 )
46
46
{
47
- streamInlet = new liblsl .StreamInlet (streamInfos [0 ]);
47
+ streamInlet = new LSL .StreamInlet (streamInfos [0 ]);
48
48
channelCount = streamInlet .info ().channel_count ();
49
49
streamInlet .open_stream ();
50
50
}
@@ -87,7 +87,7 @@ public class LSLInput : MonoBehaviour
87
87
88
88
public class LSLOutput : MonoBehaviour
89
89
{
90
- private liblsl .StreamOutlet outlet ;
90
+ private LSL .StreamOutlet outlet ;
91
91
private float [] currentSample ;
92
92
93
93
public string StreamName = " Unity.ExampleStream" ;
@@ -97,12 +97,12 @@ public class LSLInput : MonoBehaviour
97
97
// Start is called before the first frame update
98
98
void Start ()
99
99
{
100
- liblsl .StreamInfo streamInfo = new liblsl .StreamInfo (StreamName , StreamType , 3 , Time .fixedDeltaTime * 1000 , liblsl .channel_format_t .cf_float32 );
101
- liblsl .XMLElement chans = streamInfo .desc ().append_child (" channels" );
100
+ LSL .StreamInfo streamInfo = new LSL .StreamInfo (StreamName , StreamType , 3 , Time .fixedDeltaTime * 1000 , liblsl .channel_format_t .cf_float32 );
101
+ LSL .XMLElement chans = streamInfo .desc ().append_child (" channels" );
102
102
chans .append_child (" channel" ).append_child_value (" label" , " X" );
103
103
chans .append_child (" channel" ).append_child_value (" label" , " Y" );
104
104
chans .append_child (" channel" ).append_child_value (" label" , " Z" );
105
- outlet = new liblsl .StreamOutlet (streamInfo );
105
+ outlet = new LSL .StreamOutlet (streamInfo );
106
106
currentSample = new float [3 ];
107
107
}
108
108
0 commit comments