Page 1 of 1

How to light movable boxes with custom colors

Posted: Fri Feb 09, 2018 5:52 am
by Arun_AR
<arena ...>
...
<box id="box1" size="0.75,0.1,0.5" movable="true" mass="2.5">
<body position="0.4,2.3,0" orientation="45,0,0" />
<leds medium="id_of_led_medium">
<led offset=" 0.15, 0.15,0.15" anchor="origin" color="white" />
<led offset="-0.15, 0.15,0" anchor="origin" color="red" />
<led offset=" 0.15, 0.15,0" anchor="origin" color="blue" />
<led offset=" 0.15,-0.15,0" anchor="origin" color="green" />
</leds>
</box>
...
</arena>

While giving color to movable obstacles. what syntax must be used to give custom values for r,g &b.

Re: How to light movable boxes with custom colors

Posted: Fri Feb 09, 2018 7:29 am
by pincy
Have a look here:

https://github.com/ilpincy/argos3/blob/ ... lor.h#L143

You can either use string constants, or the format "r,g,b,a" where each element is a value between 0 and 255.

Re: How to light movable boxes with custom colors

Posted: Sat Feb 10, 2018 5:46 pm
by Arun_AR
Thank You sir