Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [sumo-user] background decals

The issue with offsets should be fixed now (https://github.com/eclipse-sumo/sumo/issues/16895)
There was an inconsistency between netedit (which you are using for decals) and sumo-gui (which I was using for testing your decals).
The new policy is to attempt interpretation of decals as WGS84 and then fall back to interpretation as raw UTM (only subtracting the offset) if the values are not interpretable as lon,lat.

As to the gamma issue. I am now able to reproduce it: https://github.com/eclipse-sumo/sumo/issues/16896

regards,
Jakob


Am Di., 15. Juli 2025 um 05:24 Uhr schrieb Petr Chytil <PetrChytil@xxxxxxxxx>:
1) Lately I've been using versions from 1.18 to 1.23, 64-bit zip with all extras.
I don't get any warnings when uploading decals.
The nature of the problem is that when I upload an image in UTM projection, the absolute coordinates from the jgw file are used. If the offset from the net.xml network is subtracted from these coordinates, the image is placed in the correct position. I have a script that I use to edit jgw files, but if it worked directly in SUMO, it would probably be more correct.

2) I guess I've always seen it that way. I currently know of about 4 computers and it behaves the same everywhere. I tried looking in the graphics card settings, etc. The only solution was a global gamma setting, but that's not suitable for other applications. I'll stick with doing gamma correction on the images.

Thanks,
satisfied SUMO user,
Petr


---------- Původní e-mail ----------
Od: Jakob Erdmann <namdre.sumo@xxxxxxxxx>
Komu: Petr Chytil <PetrChytil@xxxxxxxxx>
Kopie: Sumo project User discussions <sumo-user@xxxxxxxxxxx>
Datum: 14. 7. 2025 13:55:12
Předmět: Re: [sumo-user] background decals
for 1) there is a qualification: when loading an image with a world file, the projection of the .net.xml file (from the projParameter of the <location> element) is applied to the parameters of the world file. If you have been using a world file with UTM offset and the network had no associated projection then it would have worked.

When I'm loading your tile as a decal this is the warning I see:

Warning: Invalid longitude 4733.23
Warning: Could not convert coordinates in /localdata/1/debug/petr_decal/decals/Tile_008_009.jpg.

This warning reflects the attempt to transform the input coordinates from WGS84 to UTM (your network projParameter is "+proj=utm +zone=33 +ellps=WGS84 +datum=WGS84 +      units=m +no_defs").

Maybe I'm misunderstanding the nature of your problem.
Do you see a similar warning?
What SUMO version are you using?
Does your SUMO show "GDAL" in the feature list (F12 in sumo-gui)?
There might also be a difference between our platforms due to different GDAL library versions.

For 2) can you check whether the gamma problem appears on different computers?

regards,
Jakob

Am Mo., 14. Juli 2025 um 11:48 Uhr schrieb Petr Chytil <PetrChytil@xxxxxxxxx>:
Ad 1) Its funny, because I have been using SUMO longer then 10 years and I've always used UTM decals in metric system without problems (only the origin).
ad 2) Yes, when I change global gamma settings to 0.45, the images looks good, but its not solution for me.

Thanks for support,
Petr

---------- Původní e-mail ----------
Od: Jakob Erdmann <namdre.sumo@xxxxxxxxx>
Komu: Petr Chytil <PetrChytil@xxxxxxxxx>
Kopie: Sumo project User discussions <sumo-user@xxxxxxxxxxx>
Datum: 14. 7. 2025 10:40:55
Předmět: Re: [sumo-user] background decals
1. SUMO only supports jgw files in WGS84 (so the offset must be something in lon,lat and the pixels size must be in degrees). Your world file contains projected UTM data instead.
2. I cannot replicate the gamma-bias. The loaded image in sumo-gui has the same color as in an image view for me. This might be a graphics driver issue.

regards,
Jakob

Am Mo., 14. Juli 2025 um 07:19 Uhr schrieb Petr Chytil <PetrChytil@xxxxxxxxx>:
Hi Jacob,
I attached simple example. The folder contains:

network.net.xml - simple sumo network
Tile_008_009.jpg/jgw - background image in original color
Tile_009_009.jpg/jgw - background image in darker color (linear color space to sRGB)
Tile_009_009_original_offset.jpg/jgw - background image translated to network origin
jgw_offset.jpg - jgw files compare
img_compare.jpg - compare bacground images in photohop and netedit/sumo_gui

Thanks,
Petr

---------- Původní e-mail ----------
Od: Jakob Erdmann via sumo-user <sumo-user@xxxxxxxxxxx>
Komu: Sumo project User discussions <sumo-user@xxxxxxxxxxx>
Kopie: Jakob Erdmann <namdre.sumo@xxxxxxxxx>
Datum: 9. 7. 2025 9:06:03
Předmět: Re: [sumo-user] background decals
can you provide minimal example inputs?

Am Mi., 9. Juli 2025 um 08:36 Uhr schrieb Petr Chytil via sumo-user <sumo-user@xxxxxxxxxxx>:
Hi, 
I'm using georeferenced jpg files as decals and I have two problems.
1 - The position from the .jgw file is taken as absolute. It would be enough to subtract the offset that is written in the opened .net.xml
2 - Gamma correction is applied to the images, I need to have a darkened image as input so that it is displayed in the editor in the correct colors

Regards, Petr
_______________________________________________
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