[Rock-dev] New feature: vizkit3d debug drawings
Steffen Planthaber
Steffen.Planthaber at dfki.de
Tue Sep 19 10:06:39 CEST 2017
Hi,
Am 18.09.2017 um 18:49 schrieb Sylvain Joyeux:
> IMO, given that vizkit3d will depend on osgviz, then osgviz should be
> in rock-core and not rock-gui.
True
> Friendly piece of advice: don't add debug-only codepaths in your
> components. If you need to visualize debug info, build data structures
> that go on a port and visualize that.
Using data structures and sending them trough ports is already possible,
the visualizer itself is a vizkit3d plugin. So headless mode and
debugging from logfiles is already possible (optional though).
The use of ports is just a change in a single initilization line:
CONFIGURE_DEBUG_DRAWINGS_USE_PORT(RTT::TaskContext* taskContext);
instead of
CONFIGURE_DEBUG_DRAWINGS_STANDALONE();
A port is created with name of the drawing, so:
DRAW_SPHERE("some_pos", pos, 1, vizkit3dDebugDrawings::Color::red);
Will create a port named "some_pos". Of course you can put multiple
primitives to the same drawing to create complex info on a single port.
Steffen
>
> Sylvain
>
> On Mon, Sep 18, 2017 at 12:26 PM, Steffen Planthaber
> <Steffen.Planthaber at dfki.de> wrote:
>> Hi,
>>
>> We (especially Arne) worked on providing an easy way to display 3D debug
>> information using vizkit3d:
>>
>> https://github.com/arneboe/gui-vizkit3d_debug_drawings
>>
>> e.g. draw a circle just by using
>> > base::Vector3d pos(-3, -3, -3);
>> > DRAW_SPHERE("some_pos", pos, 1, vizkit3dDebugDrawings::Color::red);
>> within the Tasks code. (see the repos Readme.md for more information)
>>
>> This macro either can display the sphere in a local window where the
>> task was started or the information sent through a port to be displayed
>> remotely.
>>
>> We think that this is really helpful for debugging and is also ready to
>> be merged into the core.
>>
>> But it relies on an patched version of gui/vizkit3d, that uses the
>> "osgviz" library (providing improved click events, click callbacks, and
>> providing primitives etc.)
>>
>> https://github.com/rock-gui/gui-osgviz-osgviz
>>
>> This is the according diff for vizkit3d:
>> https://github.com/rock-core/gui-vizkit3d/compare/master...envire:osgviz?expand=1
>>
>>
>> The way to get the drawings into the rock core would be:
>>
>> * Add the osgviz library to the rock.core package_set
>> * as it is a dependency of vizkit3d then
>> * Merge the "to be created" PR for vizkit3d (diff above)
>> * Move the vizkit3d_debug_drawings lib to the rock-gui organization
>> * add vizkit3d_debug_drawings to the rock.core package set
>>
>> One open question would be if the osgviz library should stay in
>> rock-gui, or if it should be moved to rock-core?
>>
>> This is why I used this list to ask rather than staring the PR directly
>>
>> Any opinions?
>>
>>
>> Best, Steffen
>>
>>
>>
>> --
>> Steffen Planthaber
>> Weltraumrobotik
>>
>> Besuchsadresse der Nebengeschäftstelle:
>> DFKI GmbH
>> Robotics Innovation Center
>> Robert-Hooke-Straße 5
>> 28359 Bremen, Germany
>>
>> Postadresse der Hauptgeschäftsstelle Standort Bremen:
>> DFKI GmbH
>> Robotics Innovation Center
>> Robert-Hooke-Straße 1
>> 28359 Bremen, Germany
>>
>> Tel.: +49 421 178 45-4125
>> Zentrale: +49 421 178 45-0
>> Fax: +49 421 178 45-4150 (Faxe bitte namentlich kennzeichnen)
>> E-Mail: Steffen.Planthaber at dfki.de
>>
>> Weitere Informationen: http://www.dfki.de/robotik
>> -----------------------------------------------------------------------
>> Deutsches Forschungszentrum fuer Kuenstliche Intelligenz GmbH
>> Firmensitz: Trippstadter Straße 122, D-67663 Kaiserslautern
>> Geschaeftsfuehrung: Prof. Dr. Dr. h.c. mult. Wolfgang Wahlster
>> (Vorsitzender) Dr. Walter Olthoff
>> Vorsitzender des Aufsichtsrats: Prof. Dr. h.c. Hans A. Aukes
>> Amtsgericht Kaiserslautern, HRB 2313
>> Sitz der Gesellschaft: Kaiserslautern (HRB 2313)
>> USt-Id.Nr.: DE 148646973
>> Steuernummer: 19/673/0060/3
>> -----------------------------------------------------------------------
>>
>> _______________________________________________
>> Rock-dev mailing list
>> Rock-dev at dfki.de
>> http://www.dfki.de/mailman/cgi-bin/listinfo/rock-dev
--
Steffen Planthaber
Weltraumrobotik
Besuchsadresse der Nebengeschäftstelle:
DFKI GmbH
Robotics Innovation Center
Robert-Hooke-Straße 5
28359 Bremen, Germany
Postadresse der Hauptgeschäftsstelle Standort Bremen:
DFKI GmbH
Robotics Innovation Center
Robert-Hooke-Straße 1
28359 Bremen, Germany
Tel.: +49 421 178 45-4125
Zentrale: +49 421 178 45-0
Fax: +49 421 178 45-4150 (Faxe bitte namentlich kennzeichnen)
E-Mail: Steffen.Planthaber at dfki.de
Weitere Informationen: http://www.dfki.de/robotik
-----------------------------------------------------------------------
Deutsches Forschungszentrum fuer Kuenstliche Intelligenz GmbH
Firmensitz: Trippstadter Straße 122, D-67663 Kaiserslautern
Geschaeftsfuehrung: Prof. Dr. Dr. h.c. mult. Wolfgang Wahlster
(Vorsitzender) Dr. Walter Olthoff
Vorsitzender des Aufsichtsrats: Prof. Dr. h.c. Hans A. Aukes
Amtsgericht Kaiserslautern, HRB 2313
Sitz der Gesellschaft: Kaiserslautern (HRB 2313)
USt-Id.Nr.: DE 148646973
Steuernummer: 19/673/0060/3
-----------------------------------------------------------------------
More information about the Rock-dev
mailing list