Skip to main content

I try to color features by attribute value. Tried both the FeatureColorSetter and the KML Styler.

 

I have the color in an attributes for each feature both as hex "#FFCC00" and as decimal "255,204,0" but both don't work when i feed them to "Fill Color" in the KMLStyler or FeatureColorSetter.

 

How do I have to format the color values?

The FeatureColor setter expects an FME color if setting via an attribute i.e. 1,0.8,0 (it will let you copy and paste hex and rgb colours via the interface but does the conversion for you and this doesn't work if you set via attribute)

There are custom transformers that will convert hex and rgb colours to fme colours, e.g. ColorCalculator


Thanks


Reply