基本信息
以下是所在類或對象的基本信息。
AMD:
require(["esri/renderers/visualVariables/OpacityVariable"], (OpacityVariable) => { /* code goes here */ });
ESM:
import OpacityVariable from "@arcgis/core/renderers/visualVariables/OpacityVariable";
類:
esri/renderers/visualVariables/OpacityVariable
繼承: OpacityVariable > VisualVariable > Accessor
自從:用於 JavaScript 4.10 的 ArcGIS API
用法說明
例子:
const opacityVisualVariable = {
type: "opacity",
field: "PERCENTAGE",
// maps data values to opacity values
stops: [
{ value: 0, opacity: 0.1 },
{ value: 100, opacity: 1 }
]
};
renderer.visualVariables = [ opacVisVar ];
// opacity visual variable with arcade
const opacityVisualVariable = {
type: "opacity",
// calculate a value to visualize with opacity
valueExpression: "( $feature.TOT_VOTES / $feature.REG_VOTERS ) * 100",
stops: [
{ value: 30, opacity: 0.15 },
{ value: 70, opacity: 0.15 }
]
};
renderer.visualVariables = [ opacityVisVar ];
相關用法
- JavaScript ArcGIS OpacityVariable.clone用法及代碼示例
- JavaScript OpacitySlider.visibleElements用法及代碼示例
- JavaScript OpacitySlider.zoomOptions用法及代碼示例
- JavaScript OpacitySlider.when用法及代碼示例
- JavaScript OpacitySlider.on用法及代碼示例
- JavaScript OpacitySlider.updateFromVisualVariableResult用法及代碼示例
- JavaScript OpacitySlider.syncedSegmentsEnabled用法及代碼示例
- JavaScript OpacitySlider.min用法及代碼示例
- JavaScript OpacitySlider.precision用法及代碼示例
- JavaScript OpacitySlider用法及代碼示例
- JavaScript OpacitySlider.visible用法及代碼示例
- JavaScript OpacitySlider thumb-change事件用法及代碼示例
- JavaScript OpacitySlider segment-drag事件用法及代碼示例
- JavaScript OpacitySlider.inputFormatFunction用法及代碼示例
- JavaScript OpacitySlider.container用法及代碼示例
- JavaScript OpacitySlider.labelFormatFunction用法及代碼示例
- JavaScript OpacitySlider thumb-drag事件用法及代碼示例
- JavaScript OpacitySlider.histogramConfig用法及代碼示例
- JavaScript OpacitySlider.classes用法及代碼示例
- JavaScript OpacitySlider.style用法及代碼示例
- JavaScript OpacitySlider max-change事件用法及代碼示例
- JavaScript OpacitySlider.inputParseFunction用法及代碼示例
- JavaScript OpacitySlider min-change事件用法及代碼示例
- JavaScript OpacitySlider.fromVisualVariableResult用法及代碼示例
- JavaScript ArcGIS OpacityStop.clone用法及代碼示例
注:本文由純淨天空篩選整理自arcgis.com大神的英文原創作品 OpacityVariable。非經特殊聲明,原始代碼版權歸原作者所有,本譯文未經允許或授權,請勿轉載或複製。