Cruisers & Sailing Forums (https://www.cruisersforum.com/forums/)
-   OpenCPN (https://www.cruisersforum.com/forums/f134/)
-   -   Colors and symbols for vector charts (https://www.cruisersforum.com/forums/f134/colors-and-symbols-for-vector-charts-246709.html)

erkswede 21-02-2021 02:45

Colors and symbols for vector charts
 
1 Attachment(s)
Greetings

Wanting a more Swedish look and feel of my oeSENC charts I have created a repository with some new symbols, mainly for beacons and buoys, and a few color schemes.

https://github.com/erkswede/colors_and_symbols

Cheers!
/Erik

LennartG 21-02-2021 10:19

Re: Colors and symbols for vector charts
 
Erik, great job!

This is exactly what I wanted to see (although the swedish classic should perhaps be a bit more yellow). Now the symbols etc. are like the INT-1 symbols.

Thanks!

/LennartG

erkswede 21-02-2021 12:01

Re: Colors and symbols for vector charts
 
Thanks Lennart!

It's quite easy to adjust the land color. Just open the chartsymbols.xml in a texteditor, find the line
Code:

<color name="LANDA" r="255" g="255" b="196"/>
and lower the "b" value for a more yellow tone. Google "colorpicker" and you get a simple tool to get the color values right.

/Erik

LennartG 21-02-2021 12:13

Re: Colors and symbols for vector charts
 
Erik, thanks for the reply.
That is exactly what I guessed I should do so I'll play around with it. I'm comparing with e.g. chart 6142 in raster format to get the same color.
Something for tommorrow and I'll let you know.
/LennartG

P_Dub 21-02-2021 12:40

Re: Colors and symbols for vector charts
 
Quote:

Originally Posted by erkswede (Post 3348193)
Thanks Lennart!

It's quite easy to adjust the land color. Just open the chartsymbols.xml in a texteditor, find the line
Code:

<color name="LANDA" r="255" g="255" b="196"/>
and lower the "b" value for a more yellow tone. Google "colorpicker" and you get a simple tool to get the color values right.

/Erik

What would you suggest I have:-
<color name="LANDA" r="201" g="185" b="122"/>
Bye

Hakan 21-02-2021 13:41

Re: Colors and symbols for vector charts
 
Maybe a hint here:
https://opencpn.org/wiki/dokuwiki/do...ctor_palette&s[]=swedish

BlackSea 22-02-2021 00:11

Re: Colors and symbols for vector charts
 
Great Job @erkswede. :thumb:

Thx

LennartG 22-02-2021 01:15

Re: Colors and symbols for vector charts
 
erksweede, trying out various colors my system crashed including loosing the oesenc charts.
I just change one line at a time in the xml-file with restart in between each try so no extra content. I also rotate my logs so I had almost 50 older logs available so I went back to check.
What I got in the log, and that was before I even started my modifications, was lines like:
imagpng.cpp:167 iCCP: known incorrect sRGB profile
imagpng.cpp:167 iCCP: to many profiles

Ever seen that before?
/LennartG

erkswede 22-02-2021 01:52

Re: Colors and symbols for vector charts
 
Lennart,

If you have crashes there is probably something you miss typed in the xml. I've done it many times.

The
Code:

imagpng.cpp:167 iCCP: known incorrect sRGB profile
imagpng.cpp:167 iCCP: to many profiles

seems to be related to color profiles stored in PNG images. These are only warning messages from the graphics library used in OpenCPN and I hope that OpenCPN treats them as such.

/Erik

LennartG 22-02-2021 03:57

Re: Colors and symbols for vector charts
 
erkswede, doubt it was an xml error, but probably a power surge or something alike.
I'm more concerned about the warning messages, you never know when they turn onto a problem.
/LennartG

CarCode 22-02-2021 05:02

Re: Colors and symbols for vector charts
 
Quote:

Originally Posted by LennartG (Post 3348569)
I'm more concerned about the warning messages, you never know when they turn onto a problem.
/LennartG

The warning is coming from libpng.
To fix that, first download and install srgb-icc profiles,

cower -d srgb-icc

When finished installation, convert all images to higher standards,

for x in *png; do convert $x -profile sRGB_v4_ICC_preference.icc $x; done

Voila! Warnings are gone.



You may have a look here:
https://www.color.org/srgbprofiles.xalter


You may also use the convert command from ImageMagick:
convert -strip actual_png_filename new_png_filename

erkswede 22-02-2021 06:34

Re: Colors and symbols for vector charts
 
Thanks @carcode
I removed the color profiles from the png:s and pushed new versions to github.
/Erik

P_Dub 22-02-2021 06:38

Re: Colors and symbols for vector charts
 
It works OK, no crash, the only thing is the yellow color is a little bit too light.
I prefer th original of the Canadian chart color. Anyway, some may like it.
Thanks.

LennartG 22-02-2021 06:54

Re: Colors and symbols for vector charts
 
erksweede and P_Dub, have played around and made these changes to make it look more 'Swedish classic':

<color name "LANDA" r="255" g="255" b="196"/>
to:
<color name "LANDA" r="255" g="239" b="132"/>

<color name "LANDF" r="100" g="100" b="100"/>
to:
<color name "LANDF" r="247" g="239" b="206"/>

<color name "DEPCN" r="100" g="100" b="100"/>
to:
<color name "DEPCN" r="155" g="162" b="252"/>

<color name "DEPMD" r="204" g="236" b="253"/>
to:
<color name "DEPMD" r="198" g="215" b="255"/>

<color name "DEPMS" r="204" g="236" b="253"/>
to:
<color name "DEPMS" r="165" g="186" b="255"/>

<color name "DEPVS" r="150" g="194" b="248"/>
to:
<color name "DEPVS" r="132" g="158" b="255"/>

I'm a good bit closer but have not been able to get contour lines between 'depth categories' to show as expected. Thought it would be 'DEPCN' but that seems not to be the case (or it is overwritten later in the file).
The page that Håkan referenced has however all the contour lines displayed.
Are using the depth settings: Shallow depth = 3.00 meters, Secure depth = 6.00 and Deep water = 10.00, all in meters.
/LennartG

P_Dub 22-02-2021 07:56

Re: Colors and symbols for vector charts
 
Sorry, but not for me with a bluehish color for the sea depth of more than 10 m. The international recongnise white color should be kept. The land might needs a bit of change but not too much, you are still too yellow light.
Bye


All times are GMT -7. The time now is 05:24.

Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2021, vBulletin Solutions, Inc.


ShowCase vBulletin Plugins by Drive Thru Online, Inc.