Icons Matriz p300

Working with OpenViBE signal processing scenarios and doing scenario/BCI design
Post Reply
Ivan Santos
Posts: 7
Joined: Wed Jun 07, 2017 11:57 am

Icons Matriz p300

Post by Ivan Santos »

Hello Openvibe community.
I am changing the matrix of letters in P300, by icons through Glade. Unfortunately when I make the change, the icons do not light up, what can I do to make the icons light up like the letters?

I have tried with different types of icons, neon, transparent with jpg, png formats and I get the same results, what can I do?


Thank you very much for your future answers and I send you greetings :mrgreen:

jtlindgren
Posts: 775
Joined: Tue Dec 04, 2012 3:53 pm
Location: INRIA Rennes, FRANCE

Re: Icons Matriz p300

Post by jtlindgren »

Hi Ivan,

it seems to me that in the code (ovpCBoxAlgorithmP300SpellerVisualisation.cpp), the flashes are achieved by the following gtk library calls,

Code: Select all

                gtk_widget_modify_bg(rWidgetStyle.pWidget, GTK_STATE_NORMAL, &oColor);
                // ... [ and the following later in another function ] ...
                gtk_widget_modify_fg(rWidgetStyle.pChildWidget, GTK_STATE_NORMAL, &oColor);
Perhaps they don't do anything if the GUI element is an icon? If this is the case, possibly the code would need to be modified to use something that works with images. For example you could modify it so that you have a blank white image which is swapped to during flash.

Note that I'm just guessing here, the reason could be something else. If you can handle a little adventure in C++, it can definitely be sorted out that way. The main thing to look for is that the gtk calls that change the element state are given the handle (id pretty much) of the right widget and that the function call is suitable for the kind of widget you have. You can look at P300 Magic Card as an example where images are used as widgets. Note that in ov 1.3.0 the magic card might have some timing issues still (fixed in git and the next release).


Best,
Jussi

Post Reply