Do you also calculate a simulation step afterwards? The screenshot is only taken before the next step (see https://github.com/eclipse/sumo/issues/6153 )
Regards
Mirko
-----Original-Nachricht-----
Betreff: [sumo-user] TraCI GUI Screenshot
Datum: 2019-10-30T14:58:25+0100
Von: "Marcus Müller" <mail4m.mueller@xxxxxxxxx>
An: "Sumo project User discussions" <sumo-user@xxxxxxxxxxx>
Dear Sumo-Experts,
it looks like the TraCI Api for creating a screenshot has changed without the change being documented.
According to
the function still expects the arguments "view ID" and "filename". If I use TraCI4Matlab to send these to Arguments, I receive the error message that a "compound object" is expected by TraCI. Checking the C++ Code unveils that the arguments filename, height and width now seem to be mandatory. I changed the TraCI4Matlab interface in order to send a compound object including all three arguments. Now I don't get an error message anymore and my code runs through, but still no screenshot is created.
Can you please provide an example of how to create a screenshot from Matlab or Python? I am running on a two weeks old nightly build of SUMO.
Many thanks in Advance,
Marcus