Task oriented thread:
Reduce rastersymbols-xxxx.png to "fit" in 1024x1024
the raspberry pi graphics hardware supports textures to 2048x2048, however only rectangular (non power of 2) to 1024x1024 or so roughly. So the chart symbols which is 1500x1200 cannot fit and I must allocate 2048x2048 which uses 16mb of video memory instead of the usual 6mb.
My feature request is, could someone rearrange the files in data/s57data like rastersymbols-day.png to "fit" in 1024x1024.? I think it can as there is a lot of space. And a bunch of the icons can be removed because they aren't even used. The chartsymbols.xml would have to be updated as well. This could probably be done with a script which re-packs everything. It will benefit all users with reduced use of graphics memory, faster loading time, and less disk space so also smaller download for opencpn.
could someone rearrange the files in data/s57data like rastersymbols-day.png to "fit" in 1024x1024.? I think it can as there is a lot of space. And a bunch of the icons can be removed because they aren't even used. The chartsymbols.xml would have to be updated as well.
These are all 1500x1200 pixels
Sean wants them to be 1024x1024
and to change the xml file chartsymbols.xml accordingly.
Is there some way I can get a handle on which symbols are not used?
Is there any particular criteria for packing?
Is 2 pixels apart adequate?
Must they be in a certain order (because some of them are larger than the others)
Looks like we can get to 1024 vertical by just cutting off the bottom and moving a few symbols. Compacting horizontally will require moving the last 1/3 of a row into intermediate open space vertically.
I assume the three rastersymbol-day, dusk and dark files should all be arranged identically so that the xml will be identical. This may require editing all three at the same time.
Is there a way to just edit ..day and then create the dusk and dark with a change in colors by color remapping or something?
-- The second type, indexed palettes
, form the colormaps of indexed images
. Each indexed image has its own private indexed palette, defining the set of colors available in the image: the maximum number of colors allowed in an indexed palette is 256. These palettes are called “indexed” because each color is associated with an index number.
-- When you convert an image into indexed mode, a major part of the process is the creation of an indexed palette for the image. How this happens is described in detail in Section 6.6, “Indexed mode”
So we just have to reduce to 1024x1024, the "rastersymbol-day.png" file and then apply the related indexed palette for the other two dusk and dark.