labstreaminglayer / liblsl-Csharp

C# bindings for liblsl
MIT License
28 stars 18 forks source link

Incorrect reference to info-object #15

Open jonashogstrom opened 3 years ago

jonashogstrom commented 3 years ago

https://github.com/labstreaminglayer/liblsl-Csharp/blob/a1f2a0c7f15d4fbf64f197e58ba027b48d79289b/examples/HandleMetaData/HandleMetaData.cs#L47

It seems as the linked line should reference the local variable "inf" and not "info". I suggest splitting the inspection of the stream info into a separate method to make it clear that the two sections of code is independent.

dmedine commented 3 years ago

Or rename inf to inletInfo to distinguish it from info which is the StreamInfo object used to create the outlet. The have identical information on the insides, of course. I would prefer this to adding a separate method as the example programs obey a kind of template that is standard across all the different language wrappers.

jonashogstrom commented 3 years ago

Renaming the variable to make it easier to tell then apart makes sense.