OSC message to change a color property fails
OSC message to change a color property fails.
Expected Behavior
We should be able to change a color property with a string argument such as "#ffcc33" for orange.
Actual Behavior
There is an error message in the console and it doesn't work.
Steps to Reproduce the Problem
- apt-get install liblo-tools
- Launch MapMap and open the project attached
-
oscsend localhost 12345 /mapmap/paint/color is 0 "#ffcc33"
Specifications
- Version: dev (soon to be 0.7)
- Platform: Ubuntu 19.10
Error message
avr. 01 20 20:38 | Debug: C++OscReceiver Received: "/mapmap/paint/color" (QVariant(int, 0), QVariant(QString, "ffcc33")) - src/control/qosc/oscreceiver.cpp:24
avr. 01 20 20:38 | Debug: Attempt to set a paint property "color" QVariant(QString, "#ffcc33") - src/control/OscInterface.cpp:215
avr. 01 20 20:38 | Debug: Path could not be processed: "/mapmap/paint/color" - src/control/OscInterface.cpp:273
avr. 01 20 20:38 | Debug: "/mapmap/paint/color" - src/control/OscInterface.cpp:139
avr. 01 20 20:38 | Debug: "is" - src/control/OscInterface.cpp:139
avr. 01 20 20:38 | Debug: 0 - src/control/OscInterface.cpp:131
avr. 01 20 20:38 | Debug: "#ffcc33" - src/control/OscInterface.cpp:139
avr. 01 20 20:38 | Debug: - src/control/OscInterface.cpp:146
here is the example project. (a simple triangle that is pink)
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapmap>
<project version="0.6.3">
<paints>
<paint className="Color" name="#cc49ff" locked="false" id="1">
<opacity>1</opacity>
<color>#cc49ff</color>
</paint>
</paints>
<mappings>
<mapping className="ColorMapping" name="Triangle 1" visible="true" locked="false" paintId="1" depth="1" id="1" solo="false">
<opacity>1</opacity>
<destination className="Triangle">
<locked>false</locked>
<vertices>
<vertex y="223" x="265"/>
<vertex y="223" x="795"/>
<vertex y="74" x="530"/>
</vertices>
</destination>
</mapping>
</mappings>
</project>
The error message should be more explicit - did it fail at setting the property or at finding the object to alter?
Try
oscsend localhost 12345 /mapmap/paint/color is 1 "#ffcc33"
(I just tested it)
However: the color of the paint seems to change but it is not updated properly in the property manager...
@aalex Did you try: oscsend localhost 12345 /mapmap/paint/color is 1 "#ffcc33"
I did, but I remember it wasn't working either. It works for you? I will try again soon. @sofian