Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [sumo-user] libsumo GUI

Thanks, Michael. It is now trying to open the GUI.

But I am getting the following error. I am running two parallel instances of sumo.

[xcb] Most likely this is a multi-threaded client and XInitThreads has not been called
[xcb] Aborting, sorry about that.
qsumo: ../../src/xcb_io.c:165: dequeue_pending_request: Assertion `!xcb_xlib_unknown_req_in_deq' failed.
[DAUBQSUMO002:17633] *** Process received signal ***
[DAUBQSUMO002:17633] Signal: Aborted (6)
[DAUBQSUMO002:17633] Signal code:  (-6)
[DAUBQSUMO002:17633] [ 0] /lib/x86_64-linux-gnu/libpthread.so.0(+0x12980)[0x7fd12c732980]
[DAUBQSUMO002:17633] [ 1] /lib/x86_64-linux-gnu/libc.so.6(gsignal+0xc7)[0x7fd12c36de87]
[DAUBQSUMO002:17633] [ 2] /lib/x86_64-linux-gnu/libc.so.6(abort+0x141)[0x7fd12c36f7f1]
[DAUBQSUMO002:17633] [ 3] /lib/x86_64-linux-gnu/libc.so.6(+0x303fa)[0x7fd12c35f3fa]
[DAUBQSUMO002:17633] [ 4] /lib/x86_64-linux-gnu/libc.so.6(+0x30472)[0x7fd12c35f472]
[DAUBQSUMO002:17633] [ 5] /usr/lib/x86_64-linux-gnu/libX11.so.6(+0x3da9c)[0x7fd128462a9c]
[DAUBQSUMO002:17633] [ 6] /usr/lib/x86_64-linux-gnu/libX11.so.6(_XReply+0x28b)[0x7fd12846393b]

Can you please suggest what else is missing at my end?

Thanks

On Tue, Oct 4, 2022 at 10:12 PM Michael Behrisch <oss@xxxxxxxxxxx> wrote:
Hi,
yes please set the environment variable LIBSUMO_GUI or use
Simulation::start with sumo-gui as first argument.
I added this to the docs.

Best regards,
Michael

Am 04.10.22 um 15:29 schrieb Mahima:
> bool
> GUI::load(const std::vector<std::string>& /* cmd */) {
>      if (myWindow != nullptr) {
>          WRITE_ERROR("libsumo.load is not implemented for the GUI.");
>          return true;
>      }
>      return false;
> }
>
> How  "Simulation::load"  will work for GUI? I guess we need to use
> Simulation::start. Do we need to set env "LIBSUMO_GUI"?
>
> Please help....I need it urgently.
>
> On Tue, Oct 4, 2022 at 11:50 AM Mahima <mahima13@xxxxxxxxx
> <mailto:mahima13@xxxxxxxxx>> wrote:
>
>     I can use sumo-gui in the same repository. But, only
>     libsumo::Simulation::load and libsumo::Simulation::step is not
>     launching GUI.
>
>     On Tue, Oct 4, 2022 at 11:30 AM Mahima <mahima13@xxxxxxxxx
>     <mailto:mahima13@xxxxxxxxx>> wrote:
>
>         Just wanted to add that I am trying this on Ubuntu 18.04.6.
>
>         thanks
>
>         On Tue, Oct 4, 2022 at 12:28 AM Mahima <mahima13@xxxxxxxxx
>         <mailto:mahima13@xxxxxxxxx>> wrote:
>
>             I have tried the below test, but no GUI is launching.
>             Definitely, there is something missing. Do we need to enable
>             flags related to FOX?
>
>             #include <iostream>#define HAVE_LIBSUMOGUI // if you are on
>             Windows or have libsumo compiled yourself without GUI you
>             should remove this line#include
>             <libsumo/libsumo.h>usingnamespacelibsumo; int main(int argc,
>             char* argv[]) { Simulation::load({"-c", "test.sumocfg"});
>             for(inti = 0; i < 5; i++) { Simulation::step(); }
>             Simulation::close(); }
>
>             On Mon, Oct 3, 2022 at 10:17 PM Mahima <mahima13@xxxxxxxxx
>             <mailto:mahima13@xxxxxxxxx>> wrote:
>
>                 Please suggest I have followed instructions as per
>                 Libsumo - SUMO Documentation (dlr.de)
>                 <https://sumo.dlr.de/docs/Libsumo.html>
>                 Still I cannot see any GUI running. Is there any other
>                 #define to be enabled too?
>
>                 Thanks
>
>                 On Sun, Oct 2, 2022 at 5:07 PM Mahima
>                 <mahima13@xxxxxxxxx <mailto:mahima13@xxxxxxxxx>> wrote:
>
>                     Thanks, Jakob.
>                     I can see this commit
>                     8d48e88631fed2c6b317a3d5b86374d6c9901e1d.
>
>                     HAVE_LIBSUMOGUI is already defined in the code. On
>                     using the following commands, I cannot see any GUI
>                     being launched.
>                     libsumo::Simulation::load(sumo_options);
>                     libsumo::Simulation::step();
>
>                     What Else do I need to change to view the simulation?
>
>                     Thanks,
>                     Mahima
>
>
>                     On Sun, Oct 2, 2022 at 4:04 PM Jakob Erdmann
>                     <namdre.sumo@xxxxxxxxx
>                     <mailto:namdre.sumo@xxxxxxxxx>> wrote:
>
>                         Yes. But only on Linux.
>
>                         Am So., 2. Okt. 2022 um 12:36 Uhr schrieb Mahima
>                         <mahima13@xxxxxxxxx <mailto:mahima13@xxxxxxxxx>>:
>
>                             Hi,
>                             Do we have libsumo gui support?
>
>                             Thanks
>                             _______________________________________________
>                             sumo-user mailing list
>                             sumo-user@xxxxxxxxxxx
>                             <mailto:sumo-user@xxxxxxxxxxx>
>                             To unsubscribe from this list, visit
>                             https://www.eclipse.org/mailman/listinfo/sumo-user <https://www.eclipse.org/mailman/listinfo/sumo-user>
>
>                         _______________________________________________
>                         sumo-user mailing list
>                         sumo-user@xxxxxxxxxxx <mailto:sumo-user@xxxxxxxxxxx>
>                         To unsubscribe from this list, visit
>                         https://www.eclipse.org/mailman/listinfo/sumo-user <https://www.eclipse.org/mailman/listinfo/sumo-user>
>
>
> _______________________________________________
> sumo-user mailing list
> sumo-user@xxxxxxxxxxx
> To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/sumo-user

_______________________________________________
sumo-user mailing list
sumo-user@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/sumo-user

Back to the top