P300 magic card extension

Working with OpenViBE signal processing scenarios and doing scenario/BCI design
Post Reply
duvi
Posts: 17
Joined: Fri Sep 04, 2009 8:20 am

P300 magic card extension

Post by duvi »

Hi all,

For a student project, I need to implement a P300 magic card-like system. However, some of the requirements are not implemented in Openvibe: a dark background and a 5*5 matrix:
- Regarding the background, I modified the value in the interface to dark but there is still a small area around the picture which is in grey. I tried to modified bordure values in Glade but nothing is working. Any idea ?
- Regarding the 5*5 matrix, I read on a post that I have to modify the C-code. Is it the only way ? If yes, what do I have to change ?

Best regards,

Duvi

lbonnet
Site Admin
Posts: 417
Joined: Wed Oct 07, 2009 12:11 pm

Re: P300 magic card extension

Post by lbonnet »

Hi Duvi !
Regarding the background, I modified the value in the interface to dark but there is still a small area around the picture which is in grey. I tried to modified bordure values in Glade but nothing is working. Any idea ?
I guess the bordure value of the cards are not defined in the glade file, but in the P300 magic card visualization box, with the setting "background color".
- Regarding the 5*5 matrix, I read on a post that I have to modify the C-code. Is it the only way ? If yes, what do I have to change ?
The P300 magic card visualization box reads the number of row and column in the glade .ui file (widget "p300-magic-card-table"), and deduces the number of cards.
I tried to change the table, removing a whole column. The visualisation was ok then (with a 3*3 matrix in my case, instead of 3*4).
Quick test, I didn't get further, but you should give it a try.

If you extend the table to 5*5, I guess you will have to add some settings in the box for the cards showed.
Of course, there will be more stimulations triggering the flashs of the cards, thus the incoming stimulation stream should be also tweaked to deliver the right stimulations.

Hope this helps !

Laurent-
Follow us on twitter >> openvibebci

Checkout my (old) blog for some OpenViBE tips & tricks : here !

duvi
Posts: 17
Joined: Fri Sep 04, 2009 8:20 am

Re: P300 magic card extension

Post by duvi »

Thank you for your quick response !
Regarding the background, I have already changed this and I obtained something shown in the picture below (on Ubuntu or Windows).

Regarding the number of rows, I succeeded in creating a lower number of cards but not a higher one (the script is crashing and there is no more entry for the PNG picture filename). I looked at the C-code, but I do not see something to increase the number of filename inputs.

Thanks in advance for any help !

Best regards,

Duvi
Attachments
Capture.png
Capture.png (63.95 KiB) Viewed 5853 times

lbonnet
Site Admin
Posts: 417
Joined: Wed Oct 07, 2009 12:11 pm

Re: P300 magic card extension

Post by lbonnet »

You're welcome!
Regarding the number of rows, I succeeded in creating a lower number of cards but not a higher one (the script is crashing and there is no more entry for the PNG picture filename). I looked at the C-code, but I do not see something to increase the number of filename inputs.
I assume that if you don't have enough settings for image filenames, the box will crash when trying to fill the table with the images.
If you look at the header file (namely ovpCBoxAlgorithmP300MagicCardVisualisation.h) you will see the descriptor of the box.
In the function getBoxPrototype of the descriptor you will see how the box is constructed: inputs, outputs and settings.
You can add settings by copy-pasting the lines:

Code: Select all

rBoxAlgorithmPrototype.addSetting("Card filename", OV_TypeId_Filename, "PATH-TO-IMAGE.png");
Then compile the software and test the new box. As the box descriptor has changed, you will have to update these boxes in your scenarios.

If you need to get deeper in the code of the box, I suggest you take a look at the developer tutorials about developing a plugin.

Laurent
Follow us on twitter >> openvibebci

Checkout my (old) blog for some OpenViBE tips & tricks : here !

duvi
Posts: 17
Joined: Fri Sep 04, 2009 8:20 am

Re: P300 magic card extension

Post by duvi »

Thanks ! It works as desired. But, I have still the problem that the background is not black everywhere. Do you have an idea ?

Best regards,

Duvi

Post Reply