[Therion] colour graduation lookup feature - altitude

Bruce Mutton bruce at tomo.co.nz
Sat Jan 6 10:45:43 CET 2018


Stacho

I've had a wee play with colour graduation lookup feature, at least as far
as altitudes go.

 

First thing I noticed is that it does not work if the lookup is defined
inside a layout.

   . LayoutMapThisCave.thc [89] -- unknown option -- lookup altitude -title
"Altitude legend"

But if I put it outside of the layout (effectively, even if not actually),
inside the thconfig file (like a 'text' definition, it works just fine for
altitudes.

 

It feels to me like it should be inside a layout, to be consistent, but
perhaps you have a reason?  Perhaps it does not matter.

 

The framework seems to be very flexible, allowing many pre defined lookup
definitions, and works well for altitudes.  I like it.

If you are happy for me to do so, I will tidy up the wiki entry that I made
on this topic earlier today.

 

*	As below, it seems that if an altitude range is defined, then a
single altitude in the list will break the default text that Therion puts in
the colour legend.  I was attempting to get Therion to produce a constant
colour over altitude ranges, and interpolate colours between those ranges.
As below, I found that it does not work that way.

lookup altitude:banded -title "Altitude legend (banded)"

                [105 150][] "top level"

                90  

                75

                [30 60] [] "lower level"

endlookup

 

It produces the legend below, and a  map that is only partially coloured.
The default legend item texts are incorrect.



 

*	Adding colours to the top and bottom improves things a little.

lookup altitude:banded -title "Altitude legend (banded)"

                [105 150][100 0 0] "top level"

                90  

                75

                [30 60] [0 0 100] "lower level"

endlookup

The colour graduation is correct, but the map produced only colours the
scraps that are within the 'top level' and 'lower level' altitude range.
The others (60m to 105m) are uncoloured.



*	Adding colours to all altitudes does not improve things much.

lookup altitude:banded -title "Altitude legend (banded)"

                [105 150][100 0 0] "top level"

                90       [50 0 0]

                75       [0 0 50]

                [30 60] [0 0 100] "lower level"

endlookup

 

The map is still uncoloured in the middle altitudes (60m to 105m).



*	If I leave out the 90 and 75, the result is similar, again with
uncoloured scraps in the central altitude range.





*	Just to be sure, I attempted three bands.

lookup altitude:banded -title "Altitude legend (banded)"

                [105 150][100 0 0] "top level"

                [60 105] []        "middle level"

                [30 60] [0 0 100]  "lower level"

endlookup

This worked perfectly, colouring all scraps according to their altitude
band.

 



*	And just to finish up, I removed the text overrides.

 

lookup altitude:banded -title "Altitude legend (banded)"

                [105 150][100 0 0] 

                [60 105] []

                [30 60] [0 0 100] 

Endlookup

Again, perfect!  The default text is OK this time.



 

Maybe tomorrow I'll see if I can break dates, maps and scraps!

 

Regards

Bruce

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.speleo.sk/pipermail/therion/attachments/20180106/53c70d79/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.png
Type: image/png
Size: 7535 bytes
Desc: not available
URL: <http://mailman.speleo.sk/pipermail/therion/attachments/20180106/53c70d79/attachment.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image002.png
Type: image/png
Size: 7616 bytes
Desc: not available
URL: <http://mailman.speleo.sk/pipermail/therion/attachments/20180106/53c70d79/attachment-0001.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image012.png
Type: image/png
Size: 6623 bytes
Desc: not available
URL: <http://mailman.speleo.sk/pipermail/therion/attachments/20180106/53c70d79/attachment-0002.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image013.png
Type: image/png
Size: 79323 bytes
Desc: not available
URL: <http://mailman.speleo.sk/pipermail/therion/attachments/20180106/53c70d79/attachment-0003.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image005.jpg
Type: image/jpeg
Size: 6915 bytes
Desc: not available
URL: <http://mailman.speleo.sk/pipermail/therion/attachments/20180106/53c70d79/attachment.jpg>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image007.jpg
Type: image/jpeg
Size: 4235 bytes
Desc: not available
URL: <http://mailman.speleo.sk/pipermail/therion/attachments/20180106/53c70d79/attachment-0001.jpg>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image010.jpg
Type: image/jpeg
Size: 5730 bytes
Desc: not available
URL: <http://mailman.speleo.sk/pipermail/therion/attachments/20180106/53c70d79/attachment-0002.jpg>


More information about the Therion mailing list