pointSize

Gets or sets the StyleExpression object used to evaluate the style's pointSize property. Alternatively a string or object defining a point size style can be used. The getter will return the internal Expression or ConditionsExpression, which may differ from the value provided to the setter.

The expression must return a Number.

This expression is only applicable to point features in a Vector tile or a Point Cloud tile.

const style = new Cesium3DTileStyle({
pointSize : '(${Temperature} 90) ? 2.0 : 1.0'
});
style.pointSize.evaluate(feature); // returns a Number
const style = new Cesium3DTileStyle();
// Override pointSize expression with a custom function
style.pointSize = {
evaluate : function(feature) {
return 1.0;
}
};
const style = new Cesium3DTileStyle();
// Override pointSize expression with a number
style.pointSize = 1.0;
const style = new Cesium3DTileStyle();
// Override pointSize expression with a string
style.pointSize = '${height} / 10';
const style = new Cesium3DTileStyle();
// Override pointSize expression with a condition
style.pointSize = {
conditions : [
['${height} 2', '1.0'],
['true', '2.0']
]
};

See also