Redmine Implementing a missing symbol - nohal/OpenCPN GitHub Wiki

Implementing a missing symbol

This tutorial copes with the common situation of a symbol missing from the rasterization rules

While wandering around you come to a place where a symbol should be looking better
The object query confirms that
You start the RleEditor, load the RLE file and start your contribution to the best navigation system ever...
While looking at the available bitmap symbols, you discover, that the correct symbol doesn't exist yet, so you have to create it.
The best way to do that is cloning a similar existing symbol
You need different colors so, while cloning, aside from changing the symbol's name and it's description to the new values you like, you also modify the palette, changing the existing colors to save you some work and adding new ones if they are needed
Now you repaint what's needed in the pixel editor
The symbol's ready and you can create the missing symbolization instruction. It's pretty likely, that something very similar already exists, so cloning is usually the fast and easy way as well... To fill in the info, use what you have learned in the object query window above. What to fill? Depends. Usually just the shape and color pattern is enough. It takes some experience to know. Browse the lookup tables before starting your own work to see what the existing rules use. The rules that use more parameters have precedence before the more general ones when the presentation library considers them. In this particular case we cloned a northern cardinal mark of different shape as the only things that have to be changed are the BOYSHP value and the symbol used in the SY part of the rule.
Don't forget to sort the lookup table so the rules are in a correct order. If you don't do that, the rules won't work as expected :(
Save your changes and relaunch OpenCPN to see what you've just done and check it's correct.
Wow! Now you just have to export your changes and post them to make the others benefit from your work. The best place? Hard to say as we currently have zero contributors and the amount of traffic is hard to predict... To keep things small and simple to maintain, the best is to export individual symbols separately and the lookup tables you modified as well and post them to a thread that should be created on the forum. Announcing what you are going to do in advance would be great as well as we have no naming/numbering conventions for the symbol colors and still we should avoid having for example BOYSPR89 and BOYSPR93 with the same symbol...

Attachments (see https://github.com/nohal/ocpn-redmine-archive):

ss1missingsymbol.png (4.41 KB) Pavel Kalian, 04/27/2010 03:26 pm

ss2objectquery.png (14.2 KB) Pavel Kalian, 04/27/2010 03:26 pm

ss6cloningbitmap.png (18 KB) Pavel Kalian, 04/27/2010 03:26 pm

ss7editingbitmap.png (28.8 KB) Pavel Kalian, 04/27/2010 03:26 pm

ss8newrule.png (7.44 KB) Pavel Kalian, 04/27/2010 03:50 pm

ss9sortlupt.png (12.9 KB) Pavel Kalian, 04/27/2010 03:50 pm

ss10result.png (3.65 KB) Pavel Kalian, 04/27/2010 03:50 pm