Modify

Opened 8 years ago

Last modified 3 years ago

#13382 new enhancement

a rasterfilters color inversion/transformation filter seems very useful

Reported by: A_Pirard Owned by: Nipel-Crumple
Priority: normal Milestone:
Component: Plugin rasterfilters Version:
Keywords: Cc:

Description

There is an issue about poor visibility of white background layers over JOSM black background.
Obvious example is that a black line is invisible.
Wouldn't a solution be to make a "color inversion" rasterfilters filter?
And maybe, while we are at it and if it's easy, also specific colors transformations?

Attachments (4)

invert.PNG (91.3 KB ) - added by Nipel-Crumple 8 years ago.
black.png (4.2 KB ) - added by A_Pirard 8 years ago.
on black.png (75.3 KB ) - added by A_Pirard 8 years ago.
on white.png (76.0 KB ) - added by A_Pirard 8 years ago.

Download all attachments as: .zip

Change History (12)

in reply to:  description ; comment:1 by Nipel-Crumple, 8 years ago

Replying to A_Pirard:

There is an issue about poor visibility of white background layers over JOSM black background.
Obvious example is that a black line is invisible.
Wouldn't a solution be to make a "color inversion" rasterfilters filter?
And maybe, while we are at it and if it's easy, also specific colors transformations?

Hello!
I will try to implement one.

in reply to:  1 comment:2 by Nipel-Crumple, 8 years ago

Added one filter which is called "Invert Color" - feel free to use it and leave your feedback here, please. If it is not enough, let's decide what do we want in details.
Thanks a lot!

Last edited 8 years ago by Nipel-Crumple (previous) (diff)

comment:3 by A_Pirard, 8 years ago

Thank you but I see no new plugin update in the distribution nor any new filter in the list.

in reply to:  3 comment:4 by anonymous, 8 years ago

Replying to A_Pirard:

Thank you but I see no new plugin update in the distribution nor any new filter in the list.

That is true, plugin has no update. But with regards to filters - here you can find one new: https://josm.openstreetmap.de/wiki/ImageFilters/InvertColorFilter

by Nipel-Crumple, 8 years ago

Attachment: invert.PNG added

in reply to:  3 comment:5 by Nipel-Crumple, 8 years ago

I'm sorry for unathorized reply.
Also it is available for downloading in Preferences -> Settings for the map projections and ... -> Image Filters tab -> Invert Color

comment:6 by A_Pirard, 8 years ago

I got Invert Color downloaded, but I'm afraid I see no change to the layer when it's added and selected (tick).

Screenshots
black.png: a black line in a transparent layer displayed over a blank JOSM screen (;-))
Following is layer BE 'SPW(allonie) PICC numerical imagery' @ 50.528 5.656
on black.png: over a normal JOSM background: lines are coarse, names are barely readable
on white.png: with canvas { fill-color: #E3E3E3; }: lines are fine, names are OK
but now OSM elements that are whiter are less or barely readable, such as house numbers
You can try the layer alone.
The problem is that that transparent layer is designed to be displayed on a white background.
The idea is that inverting its colors would have it display better on a black background.
Another option would be to invert OSM colors, but rasterfilters is for rasters only.
And, as discussed in the past, JOSM CSS does not provide it.
(I just checked that "filter: invert(100%);" doesn't work)
Thanks.

by A_Pirard, 8 years ago

Attachment: black.png added

by A_Pirard, 8 years ago

Attachment: on black.png added

by A_Pirard, 8 years ago

Attachment: on white.png added

comment:7 by sharcrash, 3 years ago

Hello I'm digging out this issue as I encounter the same problem: no difference between ticked and unticked "Invert Color". This plugin would be a great fix for a useful resource i have though. It's a layer rendering Belgium's terrain surface in grey-scale via LIDAR technology but the colors were inverted giving us the impression that the surface is also inverted. I tried to trick my mind and just apply the opposite for the features i'd like to add, such as cliffs, but it's way harder than what it seems, also because the resolution of the rasterized image is of poor quality.

Also i'd like to add: to access the "Choose Filter dialog" (having the button not greyed out), the layer to be altered needs to be the active layer whereas to edit OSM's data, the "Data Layer" needs to be the active layer. Not a problem though if the invert filter works and stays activated if we put back the "Data Layer" as active layer.

comment:8 by sharcrash, 3 years ago

Today i noticed that the button was not greyed out, weird... So I gave it a try again and it works. Awesome!

I really don't know why it didn't work at first. I'm sure i've had done a reboot of JOSM and i've had gone through the same steps to activate the filter in the window dialog. In the mean time, i think the plugins got updated (unless it was on my laptop on which i contribute occasionally), so if you've done anything, that might be it. Thanks!

Last edited 3 years ago by sharcrash (previous) (diff)

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The owner will remain Nipel-Crumple.
as The resolution will be set. Next status will be 'closed'.
to The owner will be changed from Nipel-Crumple to the specified user.
Next status will be 'needinfo'. The owner will be changed from Nipel-Crumple to A_Pirard.
as duplicate The resolution will be set to duplicate. Next status will be 'closed'. The specified ticket will be cross-referenced with this ticket.
The owner will be changed from Nipel-Crumple to anonymous. Next status will be 'assigned'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.