@arcgis/core 4.33.0-next.20250520 → 4.33.0-next.20250521
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Graphic.js +1 -1
- package/arcade/Feature.js +1 -1
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/{91cd29f53f07bc38fe75.js → 14b3c18581b31c93af82.js} +1 -1
- package/assets/esri/core/workers/chunks/{66a1b92358344dd28ee1.js → 571252c9822d73cf7b01.js} +1 -1
- package/assets/esri/core/workers/chunks/{2adf558cd8d8155d07d7.js → 80b596496800e8d60eb8.js} +1 -1
- package/assets/esri/core/workers/chunks/9b610fbfcd47c3dde34d.js +1 -0
- package/assets/esri/core/workers/chunks/a0c35521e677459f6fa3.js +1 -0
- package/assets/esri/core/workers/chunks/{0a4cece5e96fb7e8a57b.js → b893012bff5dc55e542d.js} +1 -1
- package/assets/esri/core/workers/chunks/{2113da9429f6272339d7.js → cc4a6f4000cb6680be48.js} +3 -3
- package/assets/esri/themes/base/_core.scss +2 -0
- package/assets/esri/themes/base/widgets/_OrientedImageryViewer.scss +1 -1
- package/assets/esri/themes/base/widgets/_OrientedImageryViewerNavigationSettingsUI.scss +16 -0
- package/assets/esri/themes/dark/main.css +1 -1
- package/assets/esri/themes/light/main.css +1 -1
- package/assets/esri/themes/light/view.css +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_ar.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_bg.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_bs.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_ca.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_cs.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_da.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_de.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_el.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_es.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_et.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_fi.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_fr.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_he.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_hr.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_hu.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_id.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_it.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_ja.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_ko.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_lt.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_lv.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_nl.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_no.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_pl.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_pt-BR.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_pt-PT.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_ro.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_ru.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_sk.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_sl.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_sr.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_sv.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_th.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_tr.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_uk.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_vi.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_zh-CN.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_zh-HK.json +1 -1
- package/assets/esri/widgets/BasemapLayerList/t9n/BasemapLayerList_zh-TW.json +1 -1
- package/assets/esri/widgets/BatchAttributeForm/t9n/BatchAttributeForm.json +1 -1
- package/assets/esri/widgets/BatchAttributeForm/t9n/BatchAttributeForm_en.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_ar.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_bg.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_bs.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_ca.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_cs.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_da.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_de.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_el.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_es.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_et.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_fi.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_fr.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_he.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_hr.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_hu.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_id.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_it.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_ja.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_ko.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_lt.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_lv.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_nl.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_no.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_pl.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_pt-BR.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_pt-PT.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_ro.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_ru.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_sk.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_sl.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_sr.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_sv.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_th.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_tr.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_uk.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_vi.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_zh-CN.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_zh-HK.json +1 -1
- package/assets/esri/widgets/CatalogLayerList/t9n/CatalogLayerList_zh-TW.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_ar.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_bg.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_bs.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_ca.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_cs.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_da.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_de.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_el.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_es.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_et.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_fi.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_fr.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_he.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_hr.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_hu.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_id.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_it.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_ja.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_ko.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_lt.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_lv.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_nl.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_no.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_pl.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_pt-BR.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_pt-PT.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_ro.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_ru.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_sk.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_sl.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_sr.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_sv.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_th.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_tr.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_uk.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_vi.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_zh-CN.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_zh-HK.json +1 -1
- package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_zh-TW.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_ar.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_bg.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_bs.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_ca.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_cs.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_da.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_de.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_el.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_es.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_et.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_fi.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_fr.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_he.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_hr.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_hu.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_id.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_it.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_ja.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_ko.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_lt.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_lv.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_nl.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_no.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_pl.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_pt-BR.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_pt-PT.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_ro.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_ru.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_sk.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_sl.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_sr.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_sv.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_th.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_tr.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_uk.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_vi.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_zh-CN.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_zh-HK.json +1 -1
- package/assets/esri/widgets/LayerList/t9n/LayerList_zh-TW.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_ar.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_bg.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_bs.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_ca.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_cs.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_da.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_de.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_el.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_en.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_es.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_et.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_fi.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_fr.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_he.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_hr.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_hu.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_id.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_it.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_ja.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_ko.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_lt.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_lv.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_nl.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_no.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_pl.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_pt-BR.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_pt-PT.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_ro.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_ru.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_sk.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_sl.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_sr.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_sv.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_th.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_tr.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_uk.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_vi.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_zh-CN.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_zh-HK.json +1 -1
- package/assets/esri/widgets/OrientedImageryViewer/t9n/OrientedImageryViewer_zh-TW.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_ar.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_bg.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_bs.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_ca.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_cs.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_da.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_de.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_el.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_es.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_et.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_fi.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_fr.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_he.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_hr.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_hu.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_id.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_it.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_ja.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_ko.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_lt.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_lv.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_nl.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_no.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_pl.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_pt-BR.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_pt-PT.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_ro.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_ru.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_sk.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_sl.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_sr.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_sv.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_th.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_tr.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_uk.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_vi.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_zh-CN.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_zh-HK.json +1 -1
- package/assets/esri/widgets/ShadowCast/t9n/ShadowCast_zh-TW.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_ar.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_bg.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_bs.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_ca.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_cs.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_da.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_de.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_el.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_es.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_et.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_fi.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_fr.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_he.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_hr.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_hu.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_id.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_it.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_ja.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_ko.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_lt.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_lv.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_nl.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_no.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_pl.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_pt-BR.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_pt-PT.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_ro.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_ru.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_sk.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_sl.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_sr.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_sv.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_th.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_tr.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_uk.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_vi.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_zh-CN.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_zh-HK.json +1 -1
- package/assets/esri/widgets/TimeSlider/t9n/TimeSlider_zh-TW.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_ar.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_bg.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_bs.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_ca.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_cs.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_da.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_de.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_el.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_es.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_et.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_fi.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_fr.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_he.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_hr.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_hu.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_id.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_it.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_ja.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_ko.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_lt.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_lv.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_nl.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_no.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_pl.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_pt-BR.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_pt-PT.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_ro.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_ru.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_sk.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_sl.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_sr.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_sv.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_th.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_tr.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_uk.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_vi.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_zh-CN.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_zh-HK.json +1 -1
- package/assets/esri/widgets/support/SelectionList/t9n/SelectionList_zh-TW.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_ar.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_bg.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_bs.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_ca.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_cs.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_da.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_de.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_el.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_es.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_et.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_fi.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_fr.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_he.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_hr.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_hu.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_id.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_it.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_ja.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_ko.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_lt.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_lv.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_nl.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_no.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_pl.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_pt-BR.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_pt-PT.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_ro.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_ru.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_sk.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_sl.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_sr.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_sv.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_th.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_tr.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_uk.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_vi.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_zh-CN.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_zh-HK.json +1 -1
- package/assets/esri/widgets/support/SelectionToolbar/t9n/SelectionToolbar_zh-TW.json +1 -1
- package/interfaces.d.ts +59 -3
- package/layers/OrientedImageryLayer.js +1 -1
- package/layers/orientedImagery/core/ExposurePoint.js +1 -1
- package/layers/support/rasterFunctions/clipUtils.js +1 -1
- package/networks/CircuitManager.js +5 -0
- package/package.json +2 -2
- package/request.js +1 -1
- package/rest/networks/circuits/exportCircuits.js +5 -0
- package/rest/networks/circuits/queryCircuits.js +1 -1
- package/rest/networks/circuits/support/ExportCircuitsParameters.js +5 -0
- package/rest/networks/circuits/support/ExportCircuitsResult.js +5 -0
- package/rest/networks/circuits/support/QueryCircuitsParameters.js +1 -1
- package/rest/networks/circuits/support/QueryCircuitsResult.js +1 -1
- package/rest/networks/circuits/support/VerifyCircuitsResult.js +1 -1
- package/support/revision.js +1 -1
- package/views/2d/engine/imagery/RasterBitmap.js +1 -1
- package/views/2d/engine/vectorTiles/VectorTileFeatureIndex.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/heatmap/HeatmapTechnique.js +1 -1
- package/views/3d/FocusAreasView.js +1 -1
- package/views/3d/analysis/AreaMeasurement/support/AreaMeasurementVisualization.js +1 -1
- package/views/3d/analysis/AreaMeasurement/support/MeasurementData.js +1 -1
- package/views/3d/analysis/AreaMeasurementAnalysisView3D.js +1 -1
- package/views/3d/interactive/measurementTools/areaMeasurement3D/AreaMeasurement3DTool.js +1 -1
- package/views/3d/interactive/measurementTools/directLineMeasurement3D/DirectLineMeasurement3DTool.js +1 -1
- package/views/3d/layers/I3SMeshView3D.js +1 -1
- package/views/3d/layers/IntegratedMesh3DTilesLayerView3D.js +1 -1
- package/views/3d/layers/SceneLayerGraphicsView3D.js +1 -1
- package/views/3d/layers/SceneLayerView3D.js +1 -1
- package/views/3d/layers/graphics/Graphics3DCore.js +1 -1
- package/views/3d/layers/i3s/I3SMaterialUtil.js +1 -1
- package/views/3d/terrain/TerrainRenderer.js +1 -1
- package/views/3d/terrain/TileRenderer.js +1 -1
- package/views/3d/webgl-engine/core/FBOCache.js +1 -1
- package/views/3d/webgl-engine/effects/RenderPlugin.js +1 -1
- package/views/3d/webgl-engine/effects/RenderPluginManager.js +1 -1
- package/views/3d/webgl-engine/effects/focusArea/FocusAreaColorNode.js +1 -1
- package/views/3d/webgl-engine/effects/focusArea/FocusAreaMaskNode.js +1 -1
- package/views/3d/webgl-engine/effects/geometry/RenderOccludedRenderNode.js +1 -1
- package/views/3d/webgl-engine/lib/Material.js +1 -1
- package/views/3d/webgl-engine/lib/Renderer.js +1 -1
- package/views/3d/webgl-engine/lib/ShadowMap.js +1 -1
- package/views/3d/webgl-engine/lib/SortedRenderGeometryRenderer.js +1 -1
- package/views/3d/webgl-engine/lib/Texture.js +1 -1
- package/views/3d/webgl-engine/materials/renderers/MergedRenderer.js +1 -1
- package/views/FocusArea.js +1 -1
- package/views/FocusAreaOutline.js +1 -1
- package/views/FocusAreaOutlineItem.js +1 -1
- package/views/support/LayerLayerViewInfo.js +1 -1
- package/views/support/LayerViewManager.js +1 -1
- package/views/support/TextureCompressionWorker.js +1 -1
- package/views/support/TextureCompressionWorkerHandle.js +1 -1
- package/views/webgl/RenderingContext.js +1 -1
- package/views/webgl/Texture.js +1 -1
- package/views/webgl/rasterUtils.js +1 -1
- package/widgets/AreaMeasurement3D/AreaMeasurement3DViewModel.js +1 -1
- package/widgets/BatchAttributeForm/BatchAttributeFormViewModel.js +1 -1
- package/widgets/BatchAttributeForm.js +1 -1
- package/widgets/DirectLineMeasurement3D/DirectLineMeasurement3DViewModel.js +1 -1
- package/widgets/LineOfSight/LineOfSightViewModel.js +1 -1
- package/widgets/NavigationToggle/NavigationToggleViewModel.js +1 -1
- package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
- package/widgets/OrientedImageryViewer/components/Alert.js +5 -0
- package/widgets/OrientedImageryViewer/components/ImageViewer.js +1 -1
- package/widgets/OrientedImageryViewer/components/NavigationActions.js +5 -0
- package/widgets/OrientedImageryViewer/components/NavigationSettings.js +5 -0
- package/widgets/OrientedImageryViewer/components/NavigationUI.js +1 -1
- package/widgets/OrientedImageryViewer/components/SequentialNavigationUI.js +5 -0
- package/widgets/OrientedImageryViewer/css.js +1 -1
- package/widgets/OrientedImageryViewer/imageMeasurementUtils.js +1 -1
- package/widgets/OrientedImageryViewer/navigation/NavigationManager.js +1 -1
- package/widgets/OrientedImageryViewer/navigation/errors.js +1 -1
- package/widgets/OrientedImageryViewer/navigation/queries.js +1 -1
- package/widgets/OrientedImageryViewer.js +1 -1
- package/widgets/PanoramicViewer.js +1 -1
- package/widgets/Slice/SliceViewModel.js +1 -1
- package/widgets/Weather/WeatherViewModel.js +1 -1
- package/assets/esri/core/workers/chunks/47fe2379f2214bf50036.js +0 -1
- package/assets/esri/core/workers/chunks/7a9a0383f27f4967bcfa.js +0 -1
package/support/revision.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
const
|
|
5
|
+
const a="20250521",b="e816a3d979e596a30a15bfdb4eb8fa66a68b330b";export{a as buildDate,b as commitHash};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{disposeMaybe as
|
|
5
|
+
import{disposeMaybe as t}from"../../../../core/maybe.js";import{identity as e,translate as s,rotate as r,scaleByVec2 as i,multiply as a}from"../../../../core/libs/gl-matrix-2/math/mat3.js";import{create as o}from"../../../../core/libs/gl-matrix-2/factories/mat3f32.js";import{fromValues as h}from"../../../../core/libs/gl-matrix-2/factories/vec2f32.js";import{DisplayObject as u}from"../DisplayObject.js";import{TextureSamplingMode as n}from"../../../webgl/enums.js";import{createTransformTexture as d,createRasterTexture as l,createColormapTexture as c}from"../../../webgl/rasterUtils.js";const x={bandCount:3,minOutput:0,maxOutput:1,minCutOff:[0,0,0],maxCutOff:[255,255,255],factor:[1/255,1/255,1/255],useGamma:!1,gamma:[1,1,1],gammaCorrection:[1,1,1],colormap:null,colormapOffset:null,stretchType:"none",type:"stretch"};class _ extends u{constructor(t=null,e=null,s=null){super(),this._textureInvalidated=!0,this._colormapTextureInvalidated=!0,this._rasterTexture=null,this._rasterTextureBandIds=null,this._transformGridTexture=null,this._colormapTexture=null,this._colormap=null,this._supportsBilinearTexture=!0,this._processedTexture=null,this.functionTextures=[],this.projected=!1,this.stencilRef=0,this.coordScale=[1,1],this._processed=!1,this._symbolizerParameters=null,this.height=null,this.isRendereredSource=!1,this.pixelRatio=1,this.resolution=0,this.rotation=0,this._source=null,this.rawPixelData=null,this._suspended=!1,this._bandIds=null,this._interpolation=null,this._transformGrid=null,this.width=null,this.x=0,this.y=0,this.source=t,this.transformGrid=e,this.interpolation=s}destroy(){this._disposeTextures()}get processedTexture(){return this._processedTexture}set processedTexture(t){this._processedTexture!==t&&(this._disposeTextures(!0),this._processedTexture=t)}get rasterTexture(){return this._rasterTexture}set rasterTexture(t){this._rasterTexture!==t&&(this._rasterTexture?.dispose(),this._rasterTexture=t),null==t&&(this.projected=!1)}get processed(){return this._processed}set processed(e){this._processed=e,e||(this.processedTexture=t(this.processedTexture),this.invalidateTexture())}get symbolizerParameters(){return this._symbolizerParameters||x}set symbolizerParameters(t){this._symbolizerParameters!==t&&(this._symbolizerParameters=t,this._colormapTextureInvalidated=!0)}get source(){return this._source}set source(e){this._source!==e&&(this._source=e,this._rasterTexture&&(this._rasterTexture=t(this._rasterTexture),this._rasterTextureBandIds=null),this.projected=!1,this.invalidateTexture())}get suspended(){return this._suspended}set suspended(t){this._suspended&&!t&&this.stage&&(this.ready(),this.requestRender()),this._suspended=t}get bandIds(){return this._bandIds}set bandIds(t){this._bandIds=t,this._isBandIdsChanged(t)&&(this.projected=!1,this.invalidateTexture())}get interpolation(){return this._interpolation||"nearest"}set interpolation(t){this._interpolation=t,this._rasterTexture&&this._rasterTexture.setSamplingMode("bilinear"===this._getTextureSamplingMethod(t||"nearest")?n.LINEAR:n.NEAREST)}get transformGrid(){return this._transformGrid}set transformGrid(e){this._transformGrid!==e&&(this._transformGrid=e,this._transformGridTexture=t(this._transformGridTexture))}invalidateTexture(){this._textureInvalidated||(this._textureInvalidated=!0,this.requestRender())}getRasterTextureSize(t=!1){const e=t||this.projected;return[e?this.width:this.source?.width||this.width,e?this.height:this.source?.height||this.height]}getRasterCellSize(){const t=this.rawPixelData?.srcPixelSize,{projected:e,resolution:s}=this;return t&&!e?[t.x,t.y]:[s,s]}_createTransforms(){return{displayViewScreenMat3:o()}}setTransform(t){const o=e(this.transforms.displayViewScreenMat3),[u,n]=t.toScreenNoRotation([0,0],[this.x,this.y]),d=this.resolution/this.pixelRatio/t.resolution,l=d*this.width,c=d*this.height,x=Math.PI*this.rotation/180;s(o,o,h(u,n)),s(o,o,h(l/2,c/2)),r(o,o,-x),s(o,o,h(-l/2,-c/2)),i(o,o,h(l,c)),a(this.transforms.displayViewScreenMat3,t.displayViewMat3,o)}getTextures({forProcessing:t=!1,useProcessedTexture:e=!1}={}){const s=e?this._processedTexture??this._rasterTexture:this._rasterTexture,r=[],i=[];return s?(this._transformGridTexture&&!this.projected&&(i.push(this._transformGridTexture),r.push("u_transformGrid")),i.push(s),r.push("u_image"),!this._colormapTexture||!e&&t||(i.push(this._colormapTexture),r.push("u_colormap")),{names:r,textures:i}):{names:r,textures:i}}onAttach(){this.invalidateTexture()}onDetach(){this.invalidateTexture()}updateTexture({context:t}){if(!this.stage)return void this._disposeTextures();const e=this._isValidSource(this.source);e&&this._colormapTextureInvalidated&&(this._colormapTextureInvalidated=!1,this._updateColormapTexture(t)),this._textureInvalidated&&(this._textureInvalidated=!1,this._createOrDestroyRasterTexture(t),this._rasterTexture&&(e?this.transformGrid&&!this._transformGridTexture&&(this._transformGridTexture=d(t,this.transformGrid)):this._rasterTexture.setData(null)),this.suspended||(this.ready(),this.requestRender()))}updateProcessedTexture(){const{functionTextures:t}=this;0!==t.length&&(this.processedTexture=t.shift(),t.forEach((t=>t?.dispose())),t.length=0,this.processed=!!this.processedTexture)}_createOrDestroyRasterTexture(e){const s=this.source?.extractBands(this.bandIds);if(!this._isValidSource(s))return void(this._rasterTexture&&(this._rasterTexture=t(this._rasterTexture),this._rasterTextureBandIds=null));const r=!this._isBandIdsChanged(this.bandIds);if(this._rasterTexture){if(r)return;this._rasterTexture=t(this._rasterTexture),this._rasterTextureBandIds=null}this._supportsBilinearTexture=!!e.capabilities.textureFloatLinear;const i=this._getTextureSamplingMethod(this.interpolation),a=this.isRendereredSource;this._rasterTexture=l(e,s,i,a),this.projected=!1,this._processed=!1,this._rasterTextureBandIds=this.bandIds?[...this.bandIds]:null}_isBandIdsChanged(t){const e=this._rasterTextureBandIds;return!(null==e&&null==t||e&&t&&e.join("")===t.join(""))}_isValidSource(t){return null!=t&&t.pixels?.length>0}_getTextureSamplingMethod(t){const{type:e}=this.symbolizerParameters,s="lut"===e&&!this.symbolizerParameters.isClassBreaks||"hillshade"===e||"stretch"===e&&1===this.symbolizerParameters.bandCount;return!this._supportsBilinearTexture||s||"bilinear"!==t&&"cubic"!==t?"nearest":"bilinear"}_updateColormapTexture(e){const s=this._colormap,r=this.symbolizerParameters.colormap;return r?s?r.length!==s.length||r.some(((t,e)=>t!==s[e]))?(this._colormapTexture&&(this._colormapTexture=t(this._colormapTexture)),this._colormapTexture=c(e,r),void(this._colormap=r)):void 0:(this._colormapTexture=c(e,r),void(this._colormap=r)):(this._colormapTexture&&(this._colormapTexture=t(this._colormapTexture)),void(this._colormap=null))}_disposeTextures(e=!1){e?this.projected&&(this._transformGridTexture=t(this._transformGridTexture)):(this._rasterTexture=t(this._rasterTexture),this._colormapTexture=t(this._colormapTexture),this._transformGridTexture=t(this._transformGridTexture),this._rasterTextureBandIds=null,this._colormap=null,this._colormapTextureInvalidated=!0),this._processedTexture=t(this._processedTexture)}}class p extends _{get source(){return this._source}}function m(t){return null!=t.source}export{_ as RasterBitmap,p as RasterBitmapWithSource,m as hasSource};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import e from"../../../../Graphic.js";import{getOrCreateMapValue as t}from"../../../../core/MapUtils.js";import s from"../../../../core/pbf.js";import{PooledRBush as r}from"../../../../core/libs/rbush/PooledRBush.js";import{tilePixelSize as i,tileCoordSize as o,tilePixelRatio as l}from"./constants.js";import{BucketType as n}from"./enums.js";import a from"./Feature.js";import{getTileMargins as y}from"./GeometryUtils.js";import c from"./SourceLayerData.js";import{IndexItem as u}from"./style/StyleLayer.js";const h=(e,t)=>{const s=e.vtlSymbol.sourceTile,r=t.vtlSymbol.sourceTile;return s.level!==r.level?s.level-r.level:s.row!==r.row?s.row-r.row:s.col!==r.col?s.col-r.col:e.styleLayerUID-t.styleLayerUID};class
|
|
5
|
+
import e from"../../../../Graphic.js";import{getOrCreateMapValue as t}from"../../../../core/MapUtils.js";import s from"../../../../core/pbf.js";import{PooledRBush as r}from"../../../../core/libs/rbush/PooledRBush.js";import{tilePixelSize as i,tileCoordSize as o,tilePixelRatio as l}from"./constants.js";import{BucketType as n}from"./enums.js";import a from"./Feature.js";import{getTileMargins as y}from"./GeometryUtils.js";import c from"./SourceLayerData.js";import{IndexItem as u}from"./style/StyleLayer.js";const h=(e,t)=>{const s=e.vtlSymbol.sourceTile,r=t.vtlSymbol.sourceTile;return s.level!==r.level?s.level-r.level:s.row!==r.row?s.row-r.row:s.col!==r.col?s.col-r.col:e.styleLayerUID-t.styleLayerUID};class m{constructor(e,t,s,r,i){this.tileKey=e,this._tileLayerData=t,this._styleRepository=s,this._tileHandler=r,this._parentLayer=i,this._index=null,this._tileKeyToPBF=new Map}static create(e,t,s,r,i){return new m(e,t,s,r,i)}clear(){this._index?.clear(),this._tileKeyToPBF.clear()}async queryAttributes(e,t,s,i,o){if(0===this._tileLayerData.size||!this._styleRepository||!this._tileHandler)return[];null===this._index&&(this._index=new r(100,d),await this._indexLayers());const l=[];return this._queryIndex(l,e,t,s,this.tileKey.level,i),o&&o?.length>0&&await this._getSymbolsAttributes(l,o),l}async _indexLayers(){const e=this.tileKey,t=this._styleRepository.layers,s=await this._getTilePayload(e);for(const[r,i]of this._tileLayerData){const o=t[r],l=s.find((e=>e.sourceName===o.source));if(!l)continue;const{protobuff:a,key:y}=l;if(i.type!==n.SYMBOL){const t=1<<e.level-y.level,s=e.row-y.row*t,r=e.col-y.col*t;this._indexLayer(o,a,e.level,t,s,r)}}}_indexLayer(e,t,r,l,n,h){const m=e.sourceLayer,d=e.getFeatureFilter(),f=r,_=r+1,p=y(f),g=new s(new Uint8Array(t),new DataView(t));for(;g.next();)switch(g.tag()){case 3:{const t=g.getMessage(),s=new c(t);if(t.release(),s.name!==m)continue;const y=s.getData(),w=s.extent/l,b=w*h-p,x=w*n-p,L=b+w+2*p,v=x+w+2*p,I=w/i,D=o/w,T=w*h,S=w*n;for(;y.nextTag(2);){const t=y.getMessage(),i=new a(t,s);if(t.release(),d&&!d.filter(i,r))continue;const o=i.values||{},l=o._minzoom,n=o._maxzoom;if(l&&l>=10*_||n&&n<=10*f)continue;const c=e.getFeatureInflatedBounds(i,f,s.extent,I);null==c||c[0]>L||c[1]>v||c[2]<b||c[3]<x||(c[0]=(c[0]-T)*D,c[1]=(c[1]-S)*D,c[2]=(c[2]-T)*D,c[3]=(c[3]-S)*D,this._index.insert(new u(e,i,c,D,T,S)))}break}default:g.skip()}g.release()}async _getSymbolsAttributes(e,t){if(!t||0===t.length)return e;const s=[];if(t.sort(h),t.length>0){let e=0,{styleLayerUID:r}=t[0];for(let o=1;o<t.length;o++){const{styleLayerUID:i}=t[o];i!==r&&(s.push({from:e,to:o,styleLayerUID:r,sourceTileKey:t[o-1].vtlSymbol.sourceTile}),e=o,r=i)}const i=t.length-1;s.push({from:e,to:t.length,styleLayerUID:r,sourceTileKey:t[i].vtlSymbol.sourceTile})}const r=this._styleRepository.layers;for(const i of s){const s=await this._getTilePayload(i.sourceTileKey),o=r[i.styleLayerUID],l=!!o&&s.find((e=>e.sourceName===o.source));l&&this._addSymbolsAttributes(e,t.slice(i.from,i.to).map((e=>e.vtlSymbol.featureIndex)),i.styleLayerUID,l)}return e}_addSymbolsAttributes(t,s,r,i){const o=this._styleRepository.layers,l=i.key,n=this.tileKey,a=1<<n.level-l.level,y=n.row-l.row*a,c=n.col-l.col*a;this._getSymbolAttributes(i.protobuff,s,r,a,y,c).forEach((s=>{const{attributes:i,tilePoint:l}=s;t.push({layerId:o[r].id,layerIndex:r,graphic:new e({attributes:i,origin:{type:"vector-tile",layerId:o[r].id,layerIndex:r,layer:this._parentLayer}}),tilePoint:l})}))}_getSymbolAttributes(e,t,r,i,l,n){const y=[],u=this._styleRepository.layers;let h=0;t.sort(((e,t)=>e-t));const m=new s(new Uint8Array(e),new DataView(e));for(;m.next();)switch(m.tag()){case 3:{const e=m.getMessage(),s=new c(e);if(e.release(),s.name!==u[r].sourceLayer)continue;const d=s.getData(),f=s.extent/i,_=o/f,p=f*n,g=f*l;let w=0;for(;d.nextTag(2);){const e=d.getMessage();if(w++===t[h]){const t=new a(e,s),r=t.values,i=t.getGeometry(),o=null!=i?[_*(i[0][0].x-p),_*(i[0][0].y-g)]:null;y.push({attributes:r,tilePoint:o}),h++}if(e.release(),h===t.length)return y}break}default:m.skip()}return m.release(),y}_queryIndex(t,s,r,i,o,n){const a=l*i*(window.devicePixelRatio||1);return this._index?.search({minX:s-a,minY:r-a,maxX:s+a,maxY:r+a},(l=>{const{layer:a,feature:y}=l;a.isIntersectingFeature(s,r,i,y,o,n,l)&&t.push({layerId:a.id,layerIndex:a.uid,tilePoint:null,graphic:new e({attributes:y.values,origin:{type:"vector-tile",layerId:l.layer.id,layerIndex:l.layer.uid,layer:this._parentLayer}})})})),t}async _getTilePayload(e){return t(this._tileKeyToPBF,e.id,(()=>this._tileHandler.fetchTilePBFs(e))).then((e=>e))}}const d=e=>({minX:e.bounds[0],minY:e.bounds[1],maxX:e.bounds[2],maxY:e.bounds[3]});export{m as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{WGLDrawPhase as e}from"../../../enums.js";import{FeatureTechnique as t}from"../FeatureTechnique.js";import{isHittest as r,getSelectionDefines as s,getFeatureUniforms as i}from"../featureTechniqueUtils.js";import{TechniqueType as n}from"../TechniqueType.js";import{HeatmapResources as o}from"./HeatmapResources.js";import{HeatmapAccumulateShader as u}from"../shaders/HeatmapAccumulateShader.js";import{HeatmapResolveShader as a}from"../shaders/HeatmapResolveShader.js";import{StencilOperation as
|
|
5
|
+
import{WGLDrawPhase as e}from"../../../enums.js";import{FeatureTechnique as t}from"../FeatureTechnique.js";import{isHittest as r,getSelectionDefines as s,getFeatureUniforms as i}from"../featureTechniqueUtils.js";import{TechniqueType as n}from"../TechniqueType.js";import{HeatmapResources as o}from"./HeatmapResources.js";import{HeatmapAccumulateShader as u}from"../shaders/HeatmapAccumulateShader.js";import{HeatmapResolveShader as a}from"../shaders/HeatmapResolveShader.js";import{StencilOperation as l,CompareFunction as d,FramebufferBit as c}from"../../../../../../webgl/enums.js";class h extends t{constructor(){super(...arguments),this.type=n.Heatmap,this.drawPhase=e.MAP|e.HITTEST|e.DEBUG,this.shaders={accumulate:new u,resolve:new a},this._isBound=!1,this._resources=new Map}shutdown(e){super.shutdown(e),this._resources.get(e)?.destroy(),this._resources.delete(e),this._prevFBO=null,this._unbind()}render(e,t){const{context:n,painter:o,state:u}=e,a=t.instance.getInput(),{isFieldActive:l}=a.uniforms,d=this._getOrCreateResourcesRecord(n),c=d.loadQualityProfile(n);r(e)||this._bind(e,d,a),o.setShader({shader:this.shaders.accumulate,uniforms:{...i(e,t.target),kernelControls:{radius:b(a,u),isFieldActive:l?1:0}},defines:{...s(e),...c.defines},optionalAttributes:{},useComputeBuffer:r(e)});const h=r(e)?_:f;o.setPipelineState(h),o.submitDraw(e,t)}getStencilReference(e){return m(e)}renderResolvePass(e,t){if(r(e))return;const{context:s,painter:i}=e,n=this._resources.get(s);if(null==this._prevFBO||null==this._prevViewport||!n?.initialized)return;const{defines:o}=n.loadQualityProfile(s),{minDensity:u,maxDensity:a,radius:l}=t.getInput().uniforms,d=8,c=9,h=n.accumulateFramebuffer,p=n.resolveGradientTexture,m={shader:this.shaders.resolve,uniforms:{accumulatedDensity:{texture:{unit:d,texture:h.colorTexture},minAndInvRange:[u,1/(a-u)],normalization:3/(l*l*Math.PI)},gradient:{texture:{unit:c,texture:p}}},defines:o,optionalAttributes:{},useComputeBuffer:!1};s.bindFramebuffer(this._prevFBO),s.setViewport(0,0,this._prevViewport.width,this._prevViewport.height),s.bindTexture(h.colorTexture,d),s.bindTexture(p,c),i.setPipelineState(w),i.submitDrawMesh(s,m,i.quadMesh),this._unbind()}_getOrCreateResourcesRecord(e){let t=this._resources.get(e);return null==t&&(t=new o,this._resources.set(e,t)),t}_unbind(){this._prevFBO=null,this._prevViewport=null,this._isBound=!1}_bind(e,t,r){if(this._isBound)return;const{context:s,state:i,pixelRatio:n}=e,o=s.getBoundFramebufferObject(),u=s.getViewport();this._prevFBO=o,this._prevViewport=u;const{gradient:a,gradientHash:l}=r.uniforms;t.ensureResolveGradientTexture(s,l,a);const{width:d,height:h}=u,m=p(b(r,i),n),f=d*m,_=h*m,w=t.ensureAccumulateFBO(s,f,_);s.blitFramebuffer(o,w,c.STENCIL),s.bindFramebuffer(w),s.setViewport(0,0,w.width,w.height),s.setColorMask(!0,!0,!0,!0),s.setClearColor(0,0,0,0),s.clear(c.COLOR),this._isBound=!0}}function p(e,t){const r=t>1.5?.25:.5;return e<1/(2*r)?1:r}function m(e){return e.key.level+1}const f={color:{write:[!0,!0,!0,!0],blendMode:"additive"},depth:!1,stencil:{write:!1,test:{ref:m,compare:d.GEQUAL,mask:255,op:{fail:l.KEEP,zFail:l.KEEP,zPass:l.REPLACE}}}},_={...f,stencil:!1},w={color:{write:[!0,!0,!0,!0],blendMode:"composite"},depth:!1,stencil:!1};function b(e,t){const{referenceScale:r,radius:s}=e.uniforms;return s*(0!==r?r/t.scale:1)}export{h as HeatmapTechnique};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as e}from"../../chunks/tslib.es6.js";import o from"../../core/Accessor.js";import{equals as s}from"../../core/arrayUtils.js";import r from"../../core/Collection.js";import{mapCollection as t}from"../../core/mapCollectionUtils.js";import{destroyMaybe as i}from"../../core/maybe.js";import{watch as n,syncAndInitial as a}from"../../core/reactiveUtils.js";import{property as l}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import{subclass as m}from"../../core/accessorSupport/decorators/subclass.js";import{e as c}from"../../chunks/earcut.js";import{create as p}from"../../core/libs/gl-matrix-2/factories/mat4f64.js";import{create as d}from"../../core/libs/gl-matrix-2/factories/vec3f64.js";import{getReferenceEllipsoid as u}from"../../geometry/ellipsoidUtils.js";import h from"../../geometry/Point.js";import{e as f}from"../../chunks/densifyOperator.js";import{computeTranslationToOriginAndRotation as y}from"../../geometry/projection/computeTranslationToOriginAndRotation.js";import{newDoubleArray as g}from"../../geometry/support/DoubleArray.js";import{earth as v}from"../../geometry/support/Ellipsoid.js";import{newIndexArray as w}from"../../geometry/support/Indices.js";import{t as j}from"../../chunks/vec3.js";import{FocusAreaOutlineItem as _}from"../FocusAreaOutlineItem.js";import{ViewingMode as A}from"../ViewingMode.js";import{ElevationContext as R}from"./layers/graphics/ElevationContext.js";import{extrudePolygon as b}from"./layers/graphics/Graphics3DExtrudeSymbolLayer.js";import{computeCentroid as C}from"./layers/graphics/graphicUtils.js";import{geometryToRenderInfo as N}from"./support/renderInfoUtils/polygon.js";import{FocusAreaColorNode as x}from"./webgl-engine/effects/focusArea/FocusAreaColorNode.js";import{FocusAreaGeometry as k,FocusAreaMaskNode as H}from"./webgl-engine/effects/focusArea/FocusAreaMaskNode.js";const M=-2e4,U=65e5;let P=class extends o{constructor(e){super(e),this._volumes=new Map,this._elevationContext=new R,this._outlineMap=new r}initialize(){this.addHandles([n((()=>this.areas?.style??"none"),(e=>this._ensureRenderNodes(e)),a)]),this.addHandles([n((()=>this.polygons),(e=>this._updateVolumes(e)),a)]),this._outlineMap=t((()=>this.areas?.areas),(e=>new _({area:e,view:this.view})),{recycleItems:!0})}destroy(){this.removeAllHandles(),this._outlineMap.
|
|
5
|
+
import{_ as e}from"../../chunks/tslib.es6.js";import o from"../../core/Accessor.js";import{equals as s}from"../../core/arrayUtils.js";import r from"../../core/Collection.js";import{mapCollection as t}from"../../core/mapCollectionUtils.js";import{destroyMaybe as i}from"../../core/maybe.js";import{watch as n,syncAndInitial as a}from"../../core/reactiveUtils.js";import{property as l}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import{subclass as m}from"../../core/accessorSupport/decorators/subclass.js";import{e as c}from"../../chunks/earcut.js";import{create as p}from"../../core/libs/gl-matrix-2/factories/mat4f64.js";import{create as d}from"../../core/libs/gl-matrix-2/factories/vec3f64.js";import{getReferenceEllipsoid as u}from"../../geometry/ellipsoidUtils.js";import h from"../../geometry/Point.js";import{e as f}from"../../chunks/densifyOperator.js";import{computeTranslationToOriginAndRotation as y}from"../../geometry/projection/computeTranslationToOriginAndRotation.js";import{newDoubleArray as g}from"../../geometry/support/DoubleArray.js";import{earth as v}from"../../geometry/support/Ellipsoid.js";import{newIndexArray as w}from"../../geometry/support/Indices.js";import{t as j}from"../../chunks/vec3.js";import{FocusAreaOutlineItem as _}from"../FocusAreaOutlineItem.js";import{ViewingMode as A}from"../ViewingMode.js";import{ElevationContext as R}from"./layers/graphics/ElevationContext.js";import{extrudePolygon as b}from"./layers/graphics/Graphics3DExtrudeSymbolLayer.js";import{computeCentroid as C}from"./layers/graphics/graphicUtils.js";import{geometryToRenderInfo as N}from"./support/renderInfoUtils/polygon.js";import{FocusAreaColorNode as x}from"./webgl-engine/effects/focusArea/FocusAreaColorNode.js";import{FocusAreaGeometry as k,FocusAreaMaskNode as H}from"./webgl-engine/effects/focusArea/FocusAreaMaskNode.js";const M=-2e4,U=65e5;let P=class extends o{constructor(e){super(e),this._volumes=new Map,this._elevationContext=new R,this._outlineMap=new r}initialize(){this.addHandles([n((()=>this.areas?.style??"none"),(e=>this._ensureRenderNodes(e)),a)]),this.addHandles([n((()=>this.polygons),(e=>this._updateVolumes(e)),a)]),this._outlineMap=t((()=>this.areas?.areas),(e=>new _({area:e,view:this.view})),{recycleItems:!0})}destroy(){this.removeAllHandles(),this._outlineMap.destroy()}get areas(){return this.view.map?.focusAreas}get enabledAreas(){return this.areas?.areas.toArray().filter((({enabled:e})=>e))??[]}get style(){return this.areas?.style??"none"}get polygons(){return this.enabledAreas.reduce(((e,o)=>e.concat(o.geometries.toArray())),new Array)}containsGeometry(e){if(0===this.polygons.length)return!0;const o=new h(e);return this.polygons.some((e=>e.contains(o)))}_updateVolumes(e){this._extrude(e),this._ensureRenderNodes(this.style)}_extrude(e){if(!this.view.renderCoordsHelper||s(Array.from(this._volumes.keys()),e))return;const o=U-M,r=d(),t=this.view.renderCoordsHelper.viewingMode===A.Global,i=p(),n=p();t||this.view.renderCoordsHelper.worldUpAtPosition([0,0,0],r);const a=new Map;for(const s of e){const e=this._volumes.get(s);if(e){a.set(s,e);continue}const l=C(s);if(null==l)continue;const m=f(s,u(this.view.spatialReference).radius/v.radius*5e5,{unit:"meters"});y(m.spatialReference,[l.x,l.y,0],i,this.view.renderCoordsHelper.spatialReference);const p=this.view.renderCoordsHelper.worldUpAtPosition([i[12],i[13],i[14]],V);n[12]=-i[12],n[13]=-i[13],n[14]=-i[14];const d=N(m,this.view.elevationProvider,this.view.renderCoordsHelper,this._elevationContext),{polygons:h,mapPositions:_,position:A}=d,R=new Array;for(const s of h){const e=s.count,a=c(s.mapPositions,s.holeIndices,3);if(0===a.length)continue;const l=a.length,m=6*e,d=w(m+l),u=w(l),h=g(3*m);b(A,_,a,s,h,null,null,null,d,u,o,r,t),j(h,h,n);const f=new k(h,u,d,o,[i[12]+M*p[0],i[13]+M*p[1],i[14]+M*p[2]]);R.push(f)}a.set(s,R)}this._volumes=a,this._maskRenderNode?.updateGeometries()}_ensureRenderNodes(e){this.view.stage&&("none"===e||0===this.volumes.size?(this._maskRenderNode=i(this._maskRenderNode),this._colorRenderNode=i(this._colorRenderNode)):(this._maskRenderNode??=new H({focusAreasView:this}),this._colorRenderNode??=new x({focusAreasView:this})))}get volumes(){return this._volumes}};e([l()],P.prototype,"_volumes",void 0),e([l({constructOnly:!0})],P.prototype,"view",void 0),P=e([m("esri.views.3d.FocusAreasView")],P);const V=d();export{P as FocusAreasView};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as e}from"../../../../../chunks/tslib.es6.js";import"../../../../../intl.js";import t from"../../../../../core/Accessor.js";import{unitRGBAFromColor as i,multiplyOpacityToUnitRGBA as s,getContrast as r,BrightnessThreshold as n,multiplyOpacity as a}from"../../../../../core/colorUtils.js";import"../../../../../core/has.js";import{nextHighestPowerOfTen as o}from"../../../../../core/mathUtils.js";import{destroyMaybe as l}from"../../../../../core/maybe.js";import{formatDecimal as h}from"../../../../../core/quantityFormatUtils.js";import{watch as m,syncAndInitial as c,initial as p}from"../../../../../core/reactiveUtils.js";import{lengthUnitFromSpatialReference as d,convertUnit as u,adaptiveAreaUnit as g}from"../../../../../core/unitUtils.js";import{property as _}from"../../../../../core/accessorSupport/decorators/property.js";import"../../../../../core/Logger.js";import"../../../../../core/RandomLCG.js";import{subclass as L}from"../../../../../core/accessorSupport/decorators/subclass.js";import{fromTranslation as v}from"../../../../../core/libs/gl-matrix-2/math/mat4.js";import{create as b}from"../../../../../core/libs/gl-matrix-2/factories/mat4f64.js";import{d as f}from"../../../../../chunks/vec32.js";import{create as w}from"../../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{toPreferredAreaUnit as S,preferredLengthUnit as y}from"./utils.js";import{LabelVisualElement as j}from"../../../interactive/visualElements/LabelVisualElement.js";import{LineVisualElement as C}from"../../../interactive/visualElements/LineVisualElement.js";import{MeasurementAreaVisualElement as A}from"../../../interactive/visualElements/MeasurementAreaVisualElement.js";import{GeodesicSegment as D,EuclideanSegment as M}from"../../../interactive/visualElements/support/Segment.js";import{midpoint3d as V}from"../../../support/mathUtils.js";import{RenderOccludedFlag as x}from"../../../webgl-engine/lib/Material.js";import{createStipplePatternSimple as P}from"../../../webgl-engine/materials/lineStippleUtils.js";import{onLocaleChange as O}from"../../../../../intl/locale.js";import{fetchMessageBundle as R}from"../../../../../intl/messages.js";let F=class extends t{get _parameters(){const{accentColor:e,textColor:t}=this.view.effectiveTheme,o=i(e),l=s(e,.5),h=s(r(e),.5),m=r(t,n.Low);return{accentColor:o,transparentAccentColor:l,transparentContrastColor:h,intersectingLineColor:[1,.2,0,1],textColor:t,textBackgroundColor:a(m,.6),textCalloutColor:a(m,.5),pathLineWidth:3,perimeterLineWidth:2,projectionLineWidth:2,projectionLineStippleSize:5,labelDistance:25}}get visible(){return this.analysisViewData.visible}get _renderUnits(){const e=this.view.renderCoordsHelper.spatialReference;return d(e)??"meters"}get testData(){}constructor(e){super(e),this._path=null,this._intersectedPath=null,this._perimeter=null,this._intersectedPerimeter=null,this._projectionLines=null,this._measurementArea=null,this._areaLabel=null,this._perimeterLengthLabel=null,this._pathSegments=[],this._perimeterSegments=[],this._origin=w(),this._originTransform=b(),this.messages=null,this.viewData=W,this.areaLabel=null,this.perimeterLengthLabel=null,this.loadingMessages=!0}initialize(){const{analysisViewData:e,_parameters:t,view:i}=this;this._path=new C({view:i,attached:!0,width:t.pathLineWidth,polygonOffset:!0,renderOccluded:x.OccludeAndTransparent,isDecoration:!0}),this._intersectedPath=new C({view:i,attached:!0,width:t.pathLineWidth,polygonOffset:!0,renderOccluded:x.OccludeAndTransparent,isDecoration:!0}),this._perimeter=new C({view:i,attached:!0,width:t.perimeterLineWidth,polygonOffset:!0,renderOccluded:x.OccludeAndTransparent,isDecoration:!0}),this._intersectedPerimeter=new C({view:i,attached:!0,width:t.perimeterLineWidth,color:t.intersectingLineColor,polygonOffset:!0,renderOccluded:x.OccludeAndTransparent,isDecoration:!0}),this._projectionLines=new C({view:i,attached:!0,width:t.projectionLineWidth,stipplePattern:P(t.projectionLineStippleSize),polygonOffset:!0,renderOccluded:x.OccludeAndTransparent,isDecoration:!0}),this._measurementArea=new A({view:i,attached:!0,isDecoration:!0});const s={attached:!0,view:i,isDecoration:!0};this._areaLabel=new j({...s,fontSize:k.Large}),this._perimeterLengthLabel=new j({...s,fontSize:k.Small}),this.addHandles([m((()=>[e.mode,this.visible,e.unit,e.measurementData,e.stagedPoint]),(()=>this._update()),c),m((()=>i.state?.camera),(()=>this._updateLabels()),c),O((()=>this._updateMessageBundle())),m((()=>this._parameters),(({accentColor:e,transparentAccentColor:t,transparentContrastColor:i,textColor:s,textBackgroundColor:r,textCalloutColor:n})=>{const{_path:a,_intersectedPath:o,_perimeter:l,_projectionLines:h,_measurementArea:m,_areaLabel:c,_perimeterLengthLabel:p}=this;a.color=e,o.color=e,l.color=e,h.color=e,m.color1=t,m.color2=i,c.textColor=s,c.backgroundColor=r,c.calloutColor=n,p.textColor=s,p.backgroundColor=r,p.calloutColor=n}),p)]),this._updateMessageBundle()}destroy(){this._measurementArea=l(this._measurementArea),this._path=l(this._path),this._intersectedPath=l(this._intersectedPath),this._perimeter=l(this._perimeter),this._intersectedPerimeter=l(this._intersectedPerimeter),this._areaLabel=l(this._areaLabel),this._perimeterLengthLabel=l(this._perimeterLengthLabel),this._projectionLines=l(this._projectionLines),this.set("view",null)}_update(){if(this.destroyed||!this.view.ready||!this.view.renderCoordsHelper)return;const{analysisViewData:{measurementData:e},analysisViewData:t}=this;null!=e&&(this._updateViewData(e,t.path),this._updateOrigin(),this._updatePathSegments(),this._updatePerimeterSegments(),this._updateArea(),this._updateProjectionLines(),this._updateLabels())}_updateViewData(e,t){const i=e.validMeasurement,s="geodesic"===e.actualMeasurementMode,r=s?e.geodesicArea:e.area;let n=1;if(r){const e=S(r,this.analysisViewData.unit);n=o(Math.sqrt(e.value)/Math.sqrt(300)),n*=Math.sqrt(u(1,e.unit,"square-meters")),n=u(n,"meters",this._renderUnits)}const a={validMeasurement:i,numVertices:e.numVertices,hasStagedVertex:e.hasStagedVertex,path:t,mode:e.actualMeasurementMode,positionsRender:e.positionsRender,positionsFittedWorld:e.positionsFittedWorld,positionsFittedRender:e.positionsFittedRender,intersectingSegments:s?e.geodesicIntersectingSegments:e.intersectingSegments,triangleIndices:s?e.geodesicTriangleIndices:e.triangleIndices,areaCentroid:s?e.geodesicAreaCentroidRenderCoords:e.areaCentroidRenderCoords,perimeterLengthLabelSegmentIndex:0,area:s?e.geodesicArea:e.area,pathLength:s?e.geodesicPathLength:e.pathLength,perimeterLength:e.perimeterLength,checkerSize:n};this._set("viewData",a)}_updateOrigin(){const e=this.viewData;V(e.positionsRender,this._origin),v(this._originTransform,this._origin),this._measurementArea.transform=this._originTransform,this._projectionLines.transform=this._originTransform}_createSegments(e){const t=this.viewData,i=this.view.renderCoordsHelper.spatialReference,s=t.mode,r=[],n=[],a=[],o=t.numVertices,l=t.validMeasurement?o:o-1;for(let m=0;m<l;++m){const l=t[e][m],h=t[e][(m+1)%o];let c=null;switch(s){case"euclidean":c=new M(l,h);break;case"geodesic":c=new D(l,h,i)}t.intersectingSegments.has(m)?a.push(c):n.push(c),r.push(c)}let h=null;return t.validMeasurement&&t.hasStagedVertex&&l>=2?h=r[r.length-2]:t.hasStagedVertex&&l>=1&&(h=r[r.length-1]),{all:r,nonIntersecting:n,intersecting:a,stagedSegment:h}}_updatePathSegments(){const{visible:e}=this,t=this._createSegments("positionsRender");this._path.setGeometryFromSegments(t.nonIntersecting,this._origin),this._path.visible=e,this._intersectedPath.setGeometryFromSegments(t.intersecting,this._origin),this._intersectedPath.visible=e,this._pathSegments=t.all}_updatePerimeterSegments(){const e=this.visible&&"euclidean"===this.viewData.mode,t=this._createSegments("positionsFittedRender");this._perimeter.setGeometryFromSegments(t.nonIntersecting,this._origin),this._perimeter.visible=e,this._intersectedPerimeter.setGeometryFromSegments(t.intersecting,this._origin),this._intersectedPerimeter.visible=e,this._perimeterSegments=t.all}_updateArea(){const e=this.viewData;switch(e.mode){case"euclidean":this._updateAreaEuclidean(e);break;case"geodesic":this._updateAreaGeodesic()}}_updateAreaEuclidean(e){const t=this.visible;e.validMeasurement&&0===e.intersectingSegments.size&&e.triangleIndices?(this._measurementArea.geometry={uv:e.positionsFittedWorld,position:e.positionsFittedRender,triangleIndices:e.triangleIndices},this._measurementArea.size=[e.checkerSize,e.checkerSize],this._measurementArea.visible=t):this._measurementArea.visible=!1}_updateAreaGeodesic(){this._measurementArea.visible=!1}_updateProjectionLines(){const e=this.viewData,t=this.visible,i=e.mode,s=e.numVertices;if(s>0&&e.validMeasurement&&"euclidean"===i){const i=[];for(let t=0;t<s;++t){const s=w();f(s,e.positionsRender[t],this._origin);const r=w();f(r,e.positionsFittedRender[t],this._origin),i.push([s,r])}this._projectionLines.geometry=i,this._projectionLines.visible=t}else this._projectionLines.geometry=null,this._projectionLines.visible=!1}_updateLabels(){if(this.destroyed)return;const{viewData:e}=this,{area:t,path:i}=e;if(!i)return;const s=this.visible,r=z(this.messages,t,this.analysisViewData.unit);if(null!=r?(this._areaLabel.geometry={type:"point",point:e.areaCentroid},this._areaLabel.text=r,this._areaLabel.visible=e.validMeasurement&&0===e.intersectingSegments.size&&s):this._areaLabel.visible=!1,this._set("areaLabel",r),e.validMeasurement&&0===e.intersectingSegments.size){const t="geodesic"===e.mode||!e.validMeasurement,i=t?e.pathLength:e.perimeterLength,r=I(this.messages,i,this.analysisViewData.unit);this._set("perimeterLengthLabel",r),this._perimeterLengthLabel.distance=this._parameters.labelDistance,this._perimeterLengthLabel.anchor="top",this._perimeterLengthLabel.text=r,this._perimeterLengthLabel.visible=!0;let n=!0;for(let s=0;s<e.numVertices;++s){const i=(e.perimeterLengthLabelSegmentIndex+s)%e.numVertices,r=t?this._pathSegments[i]:this._perimeterSegments[i];if(n=!0,this._perimeterLengthLabel.geometry={type:"segment",segment:r,sampleLocation:"center"},!this._perimeterLengthLabel.overlaps(this._areaLabel))break;n=!1}this._perimeterLengthLabel.visible=n&&s}else this._perimeterLengthLabel.visible=!1}_updateMessageBundle(){this.loadingMessages=!0,R("esri/core/t9n/Units").then((e=>{this.messages=e,this.view&&this._update()})).finally((()=>{this.loadingMessages=!1}))}};function z(e,t,i){return e&&t&&h(e,t,g(t.value,t.unit,i))}function I(e,t,i){return e&&t&&h(e,t,y(t,i))}var k;e([_()],F.prototype,"_parameters",null),e([_()],F.prototype,"view",void 0),e([_()],F.prototype,"messages",void 0),e([_()],F.prototype,"analysis",void 0),e([_()],F.prototype,"viewData",void 0),e([_()],F.prototype,"analysisViewData",void 0),e([_({readOnly:!0})],F.prototype,"areaLabel",void 0),e([_({readOnly:!0})],F.prototype,"perimeterLengthLabel",void 0),e([_()],F.prototype,"loadingMessages",void 0),e([_()],F.prototype,"visible",null),e([_()],F.prototype,"_renderUnits",null),F=e([L("esri.views.3d.analysis.AreaMeasurement.support.AreaMeasurementVisualization")],F),function(e){e[e.Small=12]="Small",e[e.Large=16]="Large"}(k||(k={}));const W={validMeasurement:!1,numVertices:0,hasStagedVertex:!1,path:null,mode:null,positionsRender:null,positionsFittedWorld:null,positionsFittedRender:null,intersectingSegments:null,triangleIndices:null,areaCentroid:null,perimeterLengthLabelSegmentIndex:null,checkerSize:null,area:null,pathLength:null,perimeterLength:null};export{F as AreaMeasurementVisualization};
|
|
5
|
+
import{_ as e}from"../../../../../chunks/tslib.es6.js";import"../../../../../intl.js";import t from"../../../../../core/Accessor.js";import{unitRGBAFromColor as i,multiplyOpacityToUnitRGBA as s,getContrast as r,BrightnessThreshold as n,multiplyOpacity as a}from"../../../../../core/colorUtils.js";import"../../../../../core/has.js";import{nextHighestPowerOfTen as o}from"../../../../../core/mathUtils.js";import{destroyMaybe as l}from"../../../../../core/maybe.js";import{formatDecimal as h}from"../../../../../core/quantityFormatUtils.js";import{watch as c,syncAndInitial as m,initial as d}from"../../../../../core/reactiveUtils.js";import{lengthUnitFromSpatialReference as p,convertUnit as u,adaptiveAreaUnit as g}from"../../../../../core/unitUtils.js";import{property as _}from"../../../../../core/accessorSupport/decorators/property.js";import"../../../../../core/Logger.js";import"../../../../../core/RandomLCG.js";import{subclass as v}from"../../../../../core/accessorSupport/decorators/subclass.js";import{fromTranslation as L}from"../../../../../core/libs/gl-matrix-2/math/mat4.js";import{create as b}from"../../../../../core/libs/gl-matrix-2/factories/mat4f64.js";import{d as f}from"../../../../../chunks/vec32.js";import{create as w}from"../../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{toPreferredAreaUnit as S,preferredLengthUnit as y}from"./utils.js";import{LabelVisualElement as j}from"../../../interactive/visualElements/LabelVisualElement.js";import{LineVisualElement as C}from"../../../interactive/visualElements/LineVisualElement.js";import{MeasurementAreaVisualElement as D}from"../../../interactive/visualElements/MeasurementAreaVisualElement.js";import{GeodesicSegment as A,EuclideanSegment as M}from"../../../interactive/visualElements/support/Segment.js";import{midpoint3d as V}from"../../../support/mathUtils.js";import{RenderOccludedFlag as x}from"../../../webgl-engine/lib/Material.js";import{createStipplePatternSimple as P}from"../../../webgl-engine/materials/lineStippleUtils.js";import{onLocaleChange as O}from"../../../../../intl/locale.js";import{fetchMessageBundle as R}from"../../../../../intl/messages.js";let F=class extends t{get _parameters(){const{accentColor:e,textColor:t}=this.view.effectiveTheme,o=i(e),l=s(e,.5),h=s(r(e),.5),c=r(t,n.Low);return{accentColor:o,transparentAccentColor:l,transparentContrastColor:h,intersectingLineColor:[1,.2,0,1],textColor:t,textBackgroundColor:a(c,.6),textCalloutColor:a(c,.5),pathLineWidth:3,perimeterLineWidth:2,projectionLineWidth:2,projectionLineStippleSize:5,labelDistance:25}}get visible(){return this.analysisViewData.visible}get _renderUnits(){const e=this.view.renderCoordsHelper.spatialReference;return p(e)??"meters"}get testData(){}constructor(e){super(e),this._path=null,this._intersectedPath=null,this._perimeter=null,this._intersectedPerimeter=null,this._projectionLines=null,this._measurementArea=null,this._areaLabel=null,this._perimeterLengthLabel=null,this._pathSegments=[],this._perimeterSegments=[],this._origin=w(),this._originTransform=b(),this.messages=null,this.viewData=W,this.areaLabel=null,this.perimeterLengthLabel=null,this.loadingMessages=!0}initialize(){const{analysisViewData:e,_parameters:t,view:i}=this;this._path=new C({view:i,attached:!0,width:t.pathLineWidth,polygonOffset:!0,renderOccluded:x.OccludeAndTransparent,isDecoration:!0}),this._intersectedPath=new C({view:i,attached:!0,width:t.pathLineWidth,polygonOffset:!0,renderOccluded:x.OccludeAndTransparent,isDecoration:!0}),this._perimeter=new C({view:i,attached:!0,width:t.perimeterLineWidth,polygonOffset:!0,renderOccluded:x.OccludeAndTransparent,isDecoration:!0}),this._intersectedPerimeter=new C({view:i,attached:!0,width:t.perimeterLineWidth,color:t.intersectingLineColor,polygonOffset:!0,renderOccluded:x.OccludeAndTransparent,isDecoration:!0}),this._projectionLines=new C({view:i,attached:!0,width:t.projectionLineWidth,stipplePattern:P(t.projectionLineStippleSize),polygonOffset:!0,renderOccluded:x.OccludeAndTransparent,isDecoration:!0}),this._measurementArea=new D({view:i,attached:!0,isDecoration:!0});const s={attached:!0,view:i,isDecoration:!0};this._areaLabel=new j({...s,fontSize:k.Large}),this._perimeterLengthLabel=new j({...s,fontSize:k.Small}),this.addHandles([c((()=>[e.mode,this.visible,e.unit,e.measurementData,e.stagedPoint]),(()=>this._update()),m),c((()=>i.state?.camera),(()=>this._updateLabels()),m),O((()=>this._updateMessageBundle())),c((()=>this._parameters),(({accentColor:e,transparentAccentColor:t,transparentContrastColor:i,textColor:s,textBackgroundColor:r,textCalloutColor:n})=>{const{_path:a,_intersectedPath:o,_perimeter:l,_projectionLines:h,_measurementArea:c,_areaLabel:m,_perimeterLengthLabel:d}=this;a.color=e,o.color=e,l.color=e,h.color=e,c.color1=t,c.color2=i,m.textColor=s,m.backgroundColor=r,m.calloutColor=n,d.textColor=s,d.backgroundColor=r,d.calloutColor=n}),d)]),this._updateMessageBundle()}destroy(){this._measurementArea=l(this._measurementArea),this._path=l(this._path),this._intersectedPath=l(this._intersectedPath),this._perimeter=l(this._perimeter),this._intersectedPerimeter=l(this._intersectedPerimeter),this._areaLabel=l(this._areaLabel),this._perimeterLengthLabel=l(this._perimeterLengthLabel),this._projectionLines=l(this._projectionLines),this.set("view",null)}_update(){if(this.destroyed||!this.view.ready||!this.view.renderCoordsHelper)return;const{analysisViewData:{measurementData:e},analysisViewData:t}=this;null!=e&&(this._updateViewData(e,t.path),this._updateOrigin(),this._updatePathSegments(),this._updatePerimeterSegments(),this._updateArea(),this._updateProjectionLines(),this._updateLabels())}_updateViewData(e,t){const i=e.validMeasurement,s="geodesic"===e.actualMeasurementMode,r=s?e.geodesicArea:e.area;let n=1;if(r){const e=S(r,this.analysisViewData.unit);n=o(Math.sqrt(e.value)/Math.sqrt(300)),n*=Math.sqrt(u(1,e.unit,"square-meters")),n=u(n,"meters",this._renderUnits)}const a={validMeasurement:i,numVertices:e.numVertices,hasStagedVertex:e.hasStagedVertex,path:t,mode:e.actualMeasurementMode,positionsRender:e.positionsRender,positionsFittedWorld:e.positionsFittedWorld,positionsFittedRender:e.positionsFittedRender,intersectingSegments:s?e.geodesicIntersectingSegments:e.intersectingSegments,triangleIndices:s?e.geodesicTriangleIndices:e.triangleIndices,areaCentroid:s?e.geodesicAreaCentroidRenderCoords:e.areaCentroidRenderCoords,perimeterLengthLabelSegmentIndex:0,area:s?e.geodesicArea:e.area,pathLength:s?e.geodesicPathLength:e.pathLength,perimeterLength:e.perimeterLength,checkerSize:n};this._set("viewData",a)}_updateOrigin(){const e=this.viewData;V(e.positionsRender,this._origin),L(this._originTransform,this._origin),this._measurementArea.transform=this._originTransform,this._projectionLines.transform=this._originTransform}_createSegments(e){const t=this.viewData,i=this.view.renderCoordsHelper.spatialReference,s=t.mode,r=[],n=[],a=[],o=t.numVertices,l=t.validMeasurement?o:o-1;for(let c=0;c<l;++c){const l=t[e][c],h=t[e][(c+1)%o];let m=null;switch(s){case"euclidean":m=new M(l,h);break;case"geodesic":m=new A(l,h,i)}t.intersectingSegments.has(c)?a.push(m):n.push(m),r.push(m)}let h=null;return t.validMeasurement&&t.hasStagedVertex&&l>=2?h=r[r.length-2]:t.hasStagedVertex&&l>=1&&(h=r[r.length-1]),{all:r,nonIntersecting:n,intersecting:a,stagedSegment:h}}_updatePathSegments(){const{visible:e}=this,t=this._createSegments("positionsRender");this._path.setGeometryFromSegments(t.nonIntersecting,this._origin),this._path.visible=e,this._intersectedPath.setGeometryFromSegments(t.intersecting,this._origin),this._intersectedPath.visible=e,this._pathSegments=t.all}_updatePerimeterSegments(){const e=this.visible&&"euclidean"===this.viewData.mode&&this.viewData.path.numVertices>2,t=this._createSegments("positionsFittedRender");this._perimeter.setGeometryFromSegments(t.nonIntersecting,this._origin),this._perimeter.visible=e,this._intersectedPerimeter.setGeometryFromSegments(t.intersecting,this._origin),this._intersectedPerimeter.visible=e,this._perimeterSegments=t.all}_updateArea(){const e=this.viewData;switch(e.mode){case"euclidean":this._updateAreaEuclidean(e);break;case"geodesic":this._updateAreaGeodesic()}}_updateAreaEuclidean(e){const t=this.visible;e.validMeasurement&&0===e.intersectingSegments.size&&e.triangleIndices?(this._measurementArea.geometry={uv:e.positionsFittedWorld,position:e.positionsFittedRender,triangleIndices:e.triangleIndices},this._measurementArea.size=[e.checkerSize,e.checkerSize],this._measurementArea.visible=t):this._measurementArea.visible=!1}_updateAreaGeodesic(){this._measurementArea.visible=!1}_updateProjectionLines(){const e=this.viewData,t=this.visible,i=e.mode,s=e.numVertices;if(s>0&&e.validMeasurement&&"euclidean"===i){const i=[];for(let t=0;t<s;++t){const s=w();f(s,e.positionsRender[t],this._origin);const r=w();f(r,e.positionsFittedRender[t],this._origin),i.push([s,r])}this._projectionLines.geometry=i,this._projectionLines.visible=t}else this._projectionLines.geometry=null,this._projectionLines.visible=!1}_updateLabels(){if(this.destroyed)return;const{viewData:e}=this,{area:t,path:i}=e;if(!i)return;const s=this.visible,r=this._areaLabel,n=this._perimeterLengthLabel,a=e.validMeasurement;r.visible=!0,n.visible=!0;let o=!1;const l=z(this.messages,t,this.analysisViewData.unit);if(null!=l&&s&&(r.geometry={type:"point",point:e.areaCentroid},r.text=l,o=e.validMeasurement&&0===e.intersectingSegments.size),this._set("areaLabel",l),s&&a&&0===e.intersectingSegments.size){const t="geodesic"===e.mode,i=t?e.pathLength:e.perimeterLength,s=I(this.messages,i,this.analysisViewData.unit);this._set("perimeterLengthLabel",s),n.distance=this._parameters.labelDistance,n.anchor="top",n.text=s;let r=!0;for(let a=0;a<e.numVertices;++a){const i=(e.perimeterLengthLabelSegmentIndex+a)%e.numVertices,s=t?this._pathSegments[i]:this._perimeterSegments[i];if(r=!0,n.geometry={type:"segment",segment:s,sampleLocation:"center"},!n.overlaps(this._areaLabel))break;r=!1}n.visible=r}else n.visible=!1;r.visible=o}_updateMessageBundle(){this.loadingMessages=!0,R("esri/core/t9n/Units").then((e=>{this.messages=e,this.view&&this._update()})).finally((()=>{this.loadingMessages=!1}))}};function z(e,t,i){return e&&t&&h(e,t,g(t.value,t.unit,i))}function I(e,t,i){return e&&t&&h(e,t,y(t,i))}var k;e([_()],F.prototype,"_parameters",null),e([_()],F.prototype,"view",void 0),e([_()],F.prototype,"messages",void 0),e([_()],F.prototype,"analysis",void 0),e([_()],F.prototype,"viewData",void 0),e([_()],F.prototype,"analysisViewData",void 0),e([_({readOnly:!0})],F.prototype,"areaLabel",void 0),e([_({readOnly:!0})],F.prototype,"perimeterLengthLabel",void 0),e([_()],F.prototype,"loadingMessages",void 0),e([_()],F.prototype,"visible",null),e([_()],F.prototype,"_renderUnits",null),F=e([v("esri.views.3d.analysis.AreaMeasurement.support.AreaMeasurementVisualization")],F),function(e){e[e.Small=12]="Small",e[e.Large=16]="Large"}(k||(k={}));const W={validMeasurement:!1,numVertices:0,hasStagedVertex:!1,path:null,mode:null,positionsRender:null,positionsFittedWorld:null,positionsFittedRender:null,intersectingSegments:null,triangleIndices:null,areaCentroid:null,perimeterLengthLabelSegmentIndex:null,checkerSize:null,area:null,pathLength:null,perimeterLength:null};export{F as AreaMeasurementVisualization};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{deg2rad as e}from"../../../../../core/mathUtils.js";import{createLength as t,toUnit as s,createArea as i}from"../../../../../core/quantityUtils.js";import{lengthUnitFromSpatialReference as o,areaUnitFromSpatialReference as n}from"../../../../../core/unitUtils.js";import{set as r,distance as h}from"../../../../../core/libs/gl-matrix-2/math/vec2.js";import{create as a}from"../../../../../core/libs/gl-matrix-2/factories/vec2f64.js";import{j as l,c as d,h as g,u as c,d as p,e as m,g as u,f as _,n as f}from"../../../../../chunks/vec32.js";import{create as S}from"../../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{create as L}from"../../../../../core/libs/gl-matrix-2/factories/vec4f64.js";import{getReferenceEllipsoid as M}from"../../../../../geometry/ellipsoidUtils.js";import{canProjectWithoutEngine as C}from"../../../../../geometry/projection.js";import{getSphericalPCPF as P}from"../../../../../geometry/spatialReferenceEllipsoidUtils.js";import{projectDirection as j}from"../../../../../geometry/projection/projectDirection.js";import{projectPointToVector as R}from"../../../../../geometry/projection/projectPointToVector.js";import{projectVectorToVector as U}from"../../../../../geometry/projection/projectVectorToVector.js";import{Axis as A}from"../../../../../geometry/support/Axis.js";import{compactIndices as v}from"../../../../../geometry/support/Indices.js";import{segmentIntersects as V}from"../../../../../geometry/support/intersectsBase.js";import{c as I}from"../../../../../chunks/sphere.js";import{areaPoints2d as w}from"../../../../../geometry/support/triangle.js";import{MeasurementMode as W}from"../../interfaces.js";import{bestFitPlane as F,fitHemisphere as y,triangleAreaGeodesic as G,planePointDistance as x,boundingSphere as T}from"../../support/measurementUtils.js";import{getElevationAtPoint as z}from"../../../support/ElevationProvider.js";import{midpoint3d as b,makeOrthonormal as q,tangentFrame as E}from"../../../support/mathUtils.js";import{triangulate as D}from"../../../../support/euclideanAreaMeasurementUtils.js";import{euclideanDistanceBetweenPoints as B}from"../../../../support/euclideanLengthMeasurementUtils.js";import{supportsGeodesicMeasurement as k}from"../../../../support/geodesicMeasurementUtils.js";import{computeEuclideanMeasurementSR as H}from"../../../../support/measurementUtils.js";class X{get numVertices(){return this._length}get hasStagedVertex(){return this._hasCursorPoint}constructor(e,t,s){this._sceneView=e,this._geodesicAreaMeasurementUtils=t,this._geodesicLengthMeasurementUtils=s,this.validMeasurement=!1,this.positionsWorld=[],this.positionsRender=[],this.positionsFittedWorld=[],this.positionsFittedRender=[],this.positionsGeodesic=[],this.positionsSpherical=[],this.positionsStereographic=[],this.pathSegmentLengths=[],this.geodesicPathSegmentLengths=[],this.perimeterSegmentLengths=[],this.intersectingSegments=new Set,this.geodesicIntersectingSegments=new Set,this.triangleIndices=null,this.geodesicTriangleIndices=null,this.areaCentroidWorldCoords=S(),this.areaCentroidRenderCoords=S(),this.geodesicAreaCentroidRenderCoords=S(),this.fittingMode=null,this.area=null,this.geodesicArea=null,this.pathLength=null,this.geodesicPathLength=null,this.perimeterLength=null,this._length=0,this._centroidRenderCoords=S(),this._planeWorldCoords=L(),this._worldUp=S(),this._worldTangent=S(),this._frame=[S(),S(),S()],this._pathVersion=-1,this._hasCursorPoint=!1,this._mode=null,this._tempU=S(),this._tempV=S(),this._tempVec3=S(),this._tempSphere=I();const i=H(e.spatialReference);this._measurementSR=i,this._lengthMeasurementUnit=o(i)??"meters",this._areaMeasurementUnit=n(i)??"square-meters"}update(e,t,s,i,o,n){const r=null!=t,h=this._pathVersion===e.version,a=this._hasCursorPoint===r,l=this._mode===o;return!(h&&!n&&a&&l&&e.isValidPolygon)&&(this._pathVersion=e.version,this._hasCursorPoint=r,this._updateCursorSegmentLength(e,t),this._update(e,t,s,i,o),!0)}_update(e,s,i,o,n){const r=this._sceneView.renderSpatialReference,h=this._measurementSR,a=i.spatialReference;let l=e.numVertices;const d=!(null==s||s.equals(e.lastPoint)||l>2&&s.equals(e.firstPoint));d&&(l+=1);const g=!e.polygonIsClosed&&l>2,c=e.polygonIsClosed||g;this._resize(l);const p=P(a),m=null!=a&&k(a)?a:null,u=null!=m&&C(a,p),{positionsGeodesic:_,positionsWorld:S,positionsRender:L,positionsSpherical:M}=this,j=(e,t)=>{Z(i.elevationProvider,e),R(e,S[t],h),R(e,L[t],r),u&&(R(e,_[t],m),R(e,M[t],p),f(M[t],M[t]))};e.forEachVertexPosition(((e,t)=>j(e,t))),d&&j(s,l-1);const U=this._updatePathLengths(c);if(this.pathLength=this._length>1?t(U,this._lengthMeasurementUnit):null,u){const e=this._updateGeodesicPathLengths(c,m);this.geodesicPathLength=null!=e&&this._length>1?e:null}else this.geodesicPathLength=null;if(this._updateMode(n),!c)return this.area=null,this.geodesicArea=null,this.perimeterLength=null,this.triangleIndices=null,this.geodesicTriangleIndices=null,this.intersectingSegments.clear(),this.geodesicIntersectingSegments.clear(),void(this.validMeasurement=!1);this._updateAreaAndPerimeterLength(i,r,h,o),u&&this._updateGeodesicArea(i,m),this.validMeasurement=!0}getData(){return{validMeasurement:this.validMeasurement,numVertices:this.numVertices,hasStagedVertex:this.hasStagedVertex,positionsRender:this.positionsRender,positionsFittedWorld:this.positionsFittedWorld,positionsFittedRender:this.positionsFittedRender,intersectingSegments:this.intersectingSegments,geodesicIntersectingSegments:this.geodesicIntersectingSegments,triangleIndices:this.triangleIndices,geodesicTriangleIndices:this.geodesicTriangleIndices,areaCentroidRenderCoords:this.areaCentroidRenderCoords,geodesicAreaCentroidRenderCoords:this.geodesicAreaCentroidRenderCoords,area:this.area,geodesicArea:this.geodesicArea,pathLength:this.pathLength,geodesicPathLength:this.geodesicPathLength,perimeterLength:this.perimeterLength,actualMeasurementMode:this.actualMeasurementMode}}_resize(e){for(e<this._length&&(this.positionsWorld.length=e,this.positionsRender.length=e,this.positionsFittedWorld.length=e,this.positionsFittedRender.length=e,this.positionsGeodesic.length=e,this.positionsSpherical.length=e,this.positionsStereographic.length=e,this.pathSegmentLengths.length=e,this.geodesicPathSegmentLengths.length=e,this.perimeterSegmentLengths.length=e,this._length=e);this._length<e;)this.positionsWorld.push(S()),this.positionsRender.push(S()),this.positionsFittedWorld.push(a()),this.positionsFittedRender.push(S()),this.positionsGeodesic.push(S()),this.positionsSpherical.push(S()),this.positionsStereographic.push(a()),this.pathSegmentLengths.push(0),this.geodesicPathSegmentLengths.push(0),this.perimeterSegmentLengths.push(0),++this._length}_updatePathLengths(e){const t=this.positionsWorld,s=this.pathSegmentLengths;let i=0;const o=this._length;for(let n=0;n<o;++n){const r=s[n]=l(t[n],t[(n+1)%o]);(n<o-1||e)&&(i+=r)}return i}_updateGeodesicPathLengths(e,i){const o=this.positionsGeodesic,n=this.geodesicPathSegmentLengths;let r=0;const h=this._length;for(let t=0;t<h;++t){const a=this._geodesicLengthMeasurementUtils.geodesicDistance(o[t],o[(t+1)%h],i);if(null==a)return null;const l=s(a,"meters").value,d=n[t]=l;(t<h-1||e)&&(r+=d)}return t(r,"meters")}_updateAreaAndPerimeterLength(e,t,s,i){const o=e.renderCoordsHelper,n=this.positionsWorld,h=this.positionsRender,a=this.positionsFittedWorld,l=this.positionsFittedRender,f=this._planeWorldCoords,S=this._centroidRenderCoords;b(h,S),o.worldUpAtPosition(S,this._worldUp),o.worldBasisAtPosition(S,A.X,this._worldTangent),j(S,this._worldUp,t,this._worldUp,s),j(S,this._worldTangent,t,this._worldTangent,s),n.length>2&&F(n,f),this.fittingMode=this._selectFittingMode(f,n,this._worldUp,i);let L=0;if("horizontal"===this.fittingMode){let e=-1/0;h.forEach(((t,s)=>{const i=o.getAltitude(h[s]);i>e&&(e=i,L=s)}))}const M=n[L];let C=f,P=this._worldTangent;"horizontal"===this.fittingMode?C=this._worldUp:"vertical"===this.fittingMode&&(C=this._tempVec3,P=this._worldUp,q(f,this._worldUp,C)),d(this._frame[2],C),q(P,C,this._frame[0]),g(this._frame[1],this._frame[0],this._frame[2]),c(this._frame[1],this._frame[1]);const R=this._tempVec3,v=this._tempU,V=this._tempV;for(let d=0;d<this._length;++d){const e=a[d],i=l[d];p(R,n[d],M),r(e,m(this._frame[0],R),m(this._frame[1],R)),u(v,this._frame[0],e[0]),u(V,this._frame[1],e[1]),_(R,v,V),_(R,R,M),U(R,s,i,t)}this.perimeterLength=this._length>0?this._updatePerimeterLengths():null,b(l,this.areaCentroidRenderCoords),U(this.areaCentroidRenderCoords,t,this.areaCentroidWorldCoords,s),this._updateIntersectingSegments(),this.area=0===this.intersectingSegments.size?this._computeArea():null}_updateGeodesicArea(e,t){const{renderCoordsHelper:s,spatialReference:i}=e,{positionsSpherical:o,positionsStereographic:n}=this,h=this._tempVec3,a=y(o,h);if(!a)return void(this.geodesicArea=null);const l=this._tempU,d=this._tempV;E(h,l,d);for(let g=0;g<this._length;++g){const e=m(o[g],l),t=m(o[g],d),s=m(o[g],h);r(n[g],e/s,t/s)}u(h,h,M(i).radius),s.toRenderCoords(h,P(i),this.geodesicAreaCentroidRenderCoords),this._updateGeodesicIntersectingSegments(),this.geodesicArea=a&&0===this.geodesicIntersectingSegments.size?this._computeGeodesicArea(t):null}_updatePerimeterLengths(){const e=this.positionsFittedWorld,s=this.perimeterSegmentLengths;let i=0;for(let t=0;t<this._length;++t){i+=s[t]=h(e[t],e[(t+1)%this._length])}return t(i,this._lengthMeasurementUnit)}_updateIntersectingSegments(){const e=this.positionsFittedWorld,t=this.intersectingSegments;t.clear();for(let s=0;s<this._length;++s)for(let i=s+2;i<this._length;++i){if((i+1)%this._length===s)continue;const o=e[s],n=e[(s+1)%this._length],r=e[i],h=e[(i+1)%this._length];V(o,n,r,h)&&(t.add(s),t.add(i))}}_computeArea(){const e=this.positionsFittedWorld,t=this.triangleIndices=v(D(e));let s=0;for(let i=0;i<t.length;i+=3)s+=w(e[t[i]],e[t[i+1]],e[t[i+2]]);return i(s,this._areaMeasurementUnit)}_updateGeodesicIntersectingSegments(){const e=this.positionsStereographic,t=this.geodesicIntersectingSegments;t.clear();for(let s=0;s<this._length;++s)for(let i=s+2;i<this._length;++i){if((i+1)%this._length===s)continue;const o=e[s],n=e[(s+1)%this._length],r=e[i],h=e[(i+1)%this._length];V(o,n,r,h)&&(t.add(s),t.add(i))}}_computeGeodesicArea(e){const t=this.positionsGeodesic,o=this.positionsStereographic,n=this.geodesicTriangleIndices=v(D(o));let r=0;for(let i=0;i<n.length;i+=3){const o=G(t[n[i]],t[n[i+1]],t[n[i+2]],e,this._geodesicAreaMeasurementUtils);if(null==o)return null;r+=s(o,"square-meters").value}return i(r,"square-meters")}_selectFittingMode(t,s,i,o){const n=s.map((e=>Math.abs(x(t,e)))).reduce(((e,t)=>Math.max(e,t)),0);T(s,this._tempSphere);const r=n/(2*this._tempSphere[3]),h=r<o.maxRelativeErrorCoplanar,a=r<o.maxRelativeErrorAlmostCoplanar;let l="horizontal";if(h)l="oblique";else if(a){l=Math.abs(m(i,t))>Math.cos(e(o.verticalAngleThreshold))?"horizontal":"vertical"}return l}_updateCursorSegmentLength(e,t){const s=e.lastPoint;e.isValidPolygon||null==s||null==t?(this.geodesicStagedSegmentLength=null,this.stagedSegmentLength=null):(this.geodesicStagedSegmentLength=this._geodesicLengthMeasurementUtils.geodesicDistanceBetweenPoints(s,t),this.stagedSegmentLength=B(s,t)?.direct)}_updateMode(e){if(e===W.Auto){this.actualMeasurementMode="euclidean";let e=0;null!=this.geodesicPathLength&&(e+=this.geodesicPathLength.value),e>J&&(this.actualMeasurementMode="geodesic")}else this.actualMeasurementMode=e===W.Euclidean?"euclidean":"geodesic";null==this.geodesicPathLength&&(this.actualMeasurementMode="euclidean"),this._mode=e}}function Z(e,t){t.hasZ||(t.z=z(e,t,"ground")??0)}const J=1e5;export{X as MeasurementDataManager};
|
|
5
|
+
import{deg2rad as e}from"../../../../../core/mathUtils.js";import{createLength as t,toUnit as s,createArea as i}from"../../../../../core/quantityUtils.js";import{lengthUnitFromSpatialReference as o,areaUnitFromSpatialReference as n}from"../../../../../core/unitUtils.js";import{set as r,distance as h}from"../../../../../core/libs/gl-matrix-2/math/vec2.js";import{create as a}from"../../../../../core/libs/gl-matrix-2/factories/vec2f64.js";import{j as l,c as d,h as g,u as c,d as p,e as m,g as u,f as _,n as f}from"../../../../../chunks/vec32.js";import{create as S}from"../../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{create as L}from"../../../../../core/libs/gl-matrix-2/factories/vec4f64.js";import{getReferenceEllipsoid as M}from"../../../../../geometry/ellipsoidUtils.js";import{canProjectWithoutEngine as C}from"../../../../../geometry/projection.js";import{getSphericalPCPF as P}from"../../../../../geometry/spatialReferenceEllipsoidUtils.js";import{projectDirection as j}from"../../../../../geometry/projection/projectDirection.js";import{projectPointToVector as R}from"../../../../../geometry/projection/projectPointToVector.js";import{projectVectorToVector as U}from"../../../../../geometry/projection/projectVectorToVector.js";import{Axis as A}from"../../../../../geometry/support/Axis.js";import{compactIndices as v}from"../../../../../geometry/support/Indices.js";import{segmentIntersects as I}from"../../../../../geometry/support/intersectsBase.js";import{c as V}from"../../../../../chunks/sphere.js";import{areaPoints2d as w}from"../../../../../geometry/support/triangle.js";import{MeasurementMode as W}from"../../interfaces.js";import{bestFitPlane as F,fitHemisphere as y,triangleAreaGeodesic as G,planePointDistance as x,boundingSphere as T}from"../../support/measurementUtils.js";import{getElevationAtPoint as z}from"../../../support/ElevationProvider.js";import{midpoint3d as q,makeOrthonormal as b,tangentFrame as E}from"../../../support/mathUtils.js";import{triangulate as D}from"../../../../support/euclideanAreaMeasurementUtils.js";import{euclideanDistanceBetweenPoints as B}from"../../../../support/euclideanLengthMeasurementUtils.js";import{supportsGeodesicMeasurement as k}from"../../../../support/geodesicMeasurementUtils.js";import{computeEuclideanMeasurementSR as H}from"../../../../support/measurementUtils.js";class X{get numVertices(){return this._length}get hasStagedVertex(){return null!=this._lastCursorPoint}constructor(e,t,s){this._sceneView=e,this._geodesicAreaMeasurementUtils=t,this._geodesicLengthMeasurementUtils=s,this.validMeasurement=!1,this.positionsWorld=[],this.positionsRender=[],this.positionsFittedWorld=[],this.positionsFittedRender=[],this.positionsGeodesic=[],this.positionsSpherical=[],this.positionsStereographic=[],this.pathSegmentLengths=[],this.geodesicPathSegmentLengths=[],this.perimeterSegmentLengths=[],this.intersectingSegments=new Set,this.geodesicIntersectingSegments=new Set,this.triangleIndices=null,this.geodesicTriangleIndices=null,this.areaCentroidWorldCoords=S(),this.areaCentroidRenderCoords=S(),this.geodesicAreaCentroidRenderCoords=S(),this.fittingMode=null,this.area=null,this.geodesicArea=null,this.pathLength=null,this.geodesicPathLength=null,this.perimeterLength=null,this._length=0,this._centroidRenderCoords=S(),this._planeWorldCoords=L(),this._worldUp=S(),this._worldTangent=S(),this._frame=[S(),S(),S()],this._lastPathVersion=-1,this._lastCursorPoint=null,this._mode=null,this._tempU=S(),this._tempV=S(),this._tempVec3=S(),this._tempSphere=V();const i=H(e.spatialReference);this._measurementSR=i,this._lengthMeasurementUnit=o(i)??"meters",this._areaMeasurementUnit=n(i)??"square-meters"}update(e,t,s,i,o,n){const r=this._lastPathVersion===e.version,h=t?t.equals(this._lastCursorPoint):null==this._lastCursorPoint,a=this._mode===o;return!(r&&!n&&a&&h)&&(this._lastPathVersion=e.version,this._lastCursorPoint=t,this._updateCursorSegmentLength(e,t),this._update(e,t,s,i,o),!0)}_update(e,s,i,o,n){const r=this._sceneView.renderSpatialReference,h=this._measurementSR,a=i.spatialReference;let l=e.numVertices;const d=!(null==s||s.equals(e.lastPoint)||l>2&&s.equals(e.firstPoint)||e.polygonIsClosed);d&&(l+=1);const g=!e.polygonIsClosed&&l>2,c=e.polygonIsClosed||g;this._resize(l);const p=P(a),m=null!=a&&k(a)?a:null,u=null!=m&&C(a,p),{positionsGeodesic:_,positionsWorld:S,positionsRender:L,positionsSpherical:M}=this,j=(e,t)=>{Z(i.elevationProvider,e),R(e,S[t],h),R(e,L[t],r),u&&(R(e,_[t],m),R(e,M[t],p),f(M[t],M[t]))};e.forEachVertexPosition(((e,t)=>j(e,t))),d&&j(s,l-1);const U=this._updatePathLengths(c);if(this.pathLength=this._length>1?t(U,this._lengthMeasurementUnit):null,u){const e=this._updateGeodesicPathLengths(c,m);this.geodesicPathLength=null!=e&&this._length>1?e:null}else this.geodesicPathLength=null;if(this._updateMode(n),!c)return this.area=null,this.geodesicArea=null,this.perimeterLength=null,this.triangleIndices=null,this.geodesicTriangleIndices=null,this.intersectingSegments.clear(),this.geodesicIntersectingSegments.clear(),void(this.validMeasurement=!1);this._updateAreaAndPerimeterLength(i,r,h,o),u&&this._updateGeodesicArea(i,m),this.validMeasurement=!0}getData(){return{validMeasurement:this.validMeasurement,numVertices:this.numVertices,hasStagedVertex:this.hasStagedVertex,positionsRender:this.positionsRender,positionsFittedWorld:this.positionsFittedWorld,positionsFittedRender:this.positionsFittedRender,intersectingSegments:this.intersectingSegments,geodesicIntersectingSegments:this.geodesicIntersectingSegments,triangleIndices:this.triangleIndices,geodesicTriangleIndices:this.geodesicTriangleIndices,areaCentroidRenderCoords:this.areaCentroidRenderCoords,geodesicAreaCentroidRenderCoords:this.geodesicAreaCentroidRenderCoords,area:this.area,geodesicArea:this.geodesicArea,pathLength:this.pathLength,geodesicPathLength:this.geodesicPathLength,perimeterLength:this.perimeterLength,actualMeasurementMode:this.actualMeasurementMode}}_resize(e){for(e<this._length&&(this.positionsWorld.length=e,this.positionsRender.length=e,this.positionsFittedWorld.length=e,this.positionsFittedRender.length=e,this.positionsGeodesic.length=e,this.positionsSpherical.length=e,this.positionsStereographic.length=e,this.pathSegmentLengths.length=e,this.geodesicPathSegmentLengths.length=e,this.perimeterSegmentLengths.length=e,this._length=e);this._length<e;)this.positionsWorld.push(S()),this.positionsRender.push(S()),this.positionsFittedWorld.push(a()),this.positionsFittedRender.push(S()),this.positionsGeodesic.push(S()),this.positionsSpherical.push(S()),this.positionsStereographic.push(a()),this.pathSegmentLengths.push(0),this.geodesicPathSegmentLengths.push(0),this.perimeterSegmentLengths.push(0),++this._length}_updatePathLengths(e){const t=this.positionsWorld,s=this.pathSegmentLengths;let i=0;const o=this._length;for(let n=0;n<o;++n){const r=s[n]=l(t[n],t[(n+1)%o]);(n<o-1||e)&&(i+=r)}return i}_updateGeodesicPathLengths(e,i){const o=this.positionsGeodesic,n=this.geodesicPathSegmentLengths;let r=0;const h=this._length;for(let t=0;t<h;++t){const a=this._geodesicLengthMeasurementUtils.geodesicDistance(o[t],o[(t+1)%h],i);if(null==a)return null;const l=s(a,"meters").value,d=n[t]=l;(t<h-1||e)&&(r+=d)}return t(r,"meters")}_updateAreaAndPerimeterLength(e,t,s,i){const o=e.renderCoordsHelper,n=this.positionsWorld,h=this.positionsRender,a=this.positionsFittedWorld,l=this.positionsFittedRender,f=this._planeWorldCoords,S=this._centroidRenderCoords;q(h,S),o.worldUpAtPosition(S,this._worldUp),o.worldBasisAtPosition(S,A.X,this._worldTangent),j(S,this._worldUp,t,this._worldUp,s),j(S,this._worldTangent,t,this._worldTangent,s),n.length>2&&F(n,f),this.fittingMode=this._selectFittingMode(f,n,this._worldUp,i);let L=0;if("horizontal"===this.fittingMode){let e=-1/0;h.forEach(((t,s)=>{const i=o.getAltitude(h[s]);i>e&&(e=i,L=s)}))}const M=n[L];let C=f,P=this._worldTangent;"horizontal"===this.fittingMode?C=this._worldUp:"vertical"===this.fittingMode&&(C=this._tempVec3,P=this._worldUp,b(f,this._worldUp,C)),d(this._frame[2],C),b(P,C,this._frame[0]),g(this._frame[1],this._frame[0],this._frame[2]),c(this._frame[1],this._frame[1]);const R=this._tempVec3,v=this._tempU,I=this._tempV;for(let d=0;d<this._length;++d){const e=a[d],i=l[d];p(R,n[d],M),r(e,m(this._frame[0],R),m(this._frame[1],R)),u(v,this._frame[0],e[0]),u(I,this._frame[1],e[1]),_(R,v,I),_(R,R,M),U(R,s,i,t)}this.perimeterLength=this._length>0?this._updatePerimeterLengths():null,q(l,this.areaCentroidRenderCoords),U(this.areaCentroidRenderCoords,t,this.areaCentroidWorldCoords,s),this._updateIntersectingSegments(),this.area=0===this.intersectingSegments.size?this._computeArea():null}_updateGeodesicArea(e,t){const{renderCoordsHelper:s,spatialReference:i}=e,{positionsSpherical:o,positionsStereographic:n}=this,h=this._tempVec3,a=y(o,h);if(!a)return void(this.geodesicArea=null);const l=this._tempU,d=this._tempV;E(h,l,d);for(let g=0;g<this._length;++g){const e=m(o[g],l),t=m(o[g],d),s=m(o[g],h);r(n[g],e/s,t/s)}u(h,h,M(i).radius),s.toRenderCoords(h,P(i),this.geodesicAreaCentroidRenderCoords),this._updateGeodesicIntersectingSegments(),this.geodesicArea=a&&0===this.geodesicIntersectingSegments.size?this._computeGeodesicArea(t):null}_updatePerimeterLengths(){const e=this.positionsFittedWorld,s=this.perimeterSegmentLengths;let i=0;for(let t=0;t<this._length;++t){i+=s[t]=h(e[t],e[(t+1)%this._length])}return t(i,this._lengthMeasurementUnit)}_updateIntersectingSegments(){const e=this.positionsFittedWorld,t=this.intersectingSegments;t.clear();for(let s=0;s<this._length;++s)for(let i=s+2;i<this._length;++i){if((i+1)%this._length===s)continue;const o=e[s],n=e[(s+1)%this._length],r=e[i],h=e[(i+1)%this._length];I(o,n,r,h)&&(t.add(s),t.add(i))}}_computeArea(){const e=this.positionsFittedWorld,t=this.triangleIndices=v(D(e));let s=0;for(let i=0;i<t.length;i+=3)s+=w(e[t[i]],e[t[i+1]],e[t[i+2]]);return i(s,this._areaMeasurementUnit)}_updateGeodesicIntersectingSegments(){const e=this.positionsStereographic,t=this.geodesicIntersectingSegments;t.clear();for(let s=0;s<this._length;++s)for(let i=s+2;i<this._length;++i){if((i+1)%this._length===s)continue;const o=e[s],n=e[(s+1)%this._length],r=e[i],h=e[(i+1)%this._length];I(o,n,r,h)&&(t.add(s),t.add(i))}}_computeGeodesicArea(e){const t=this.positionsGeodesic,o=this.positionsStereographic,n=this.geodesicTriangleIndices=v(D(o));let r=0;for(let i=0;i<n.length;i+=3){const o=G(t[n[i]],t[n[i+1]],t[n[i+2]],e,this._geodesicAreaMeasurementUtils);if(null==o)return null;r+=s(o,"square-meters").value}return i(r,"square-meters")}_selectFittingMode(t,s,i,o){const n=s.map((e=>Math.abs(x(t,e)))).reduce(((e,t)=>Math.max(e,t)),0);T(s,this._tempSphere);const r=n/(2*this._tempSphere[3]),h=r<o.maxRelativeErrorCoplanar,a=r<o.maxRelativeErrorAlmostCoplanar;let l="horizontal";if(h)l="oblique";else if(a){l=Math.abs(m(i,t))>Math.cos(e(o.verticalAngleThreshold))?"horizontal":"vertical"}return l}_updateCursorSegmentLength(e,t){const s=e.lastPoint;e.isValidPolygon||null==s||null==t?(this.geodesicStagedSegmentLength=null,this.stagedSegmentLength=null):(this.geodesicStagedSegmentLength=this._geodesicLengthMeasurementUtils.geodesicDistanceBetweenPoints(s,t),this.stagedSegmentLength=B(s,t)?.direct)}_updateMode(e){if(e===W.Auto){this.actualMeasurementMode="euclidean";let e=0;null!=this.geodesicPathLength&&(e+=this.geodesicPathLength.value),e>J&&(this.actualMeasurementMode="geodesic")}else this.actualMeasurementMode=e===W.Euclidean?"euclidean":"geodesic";null==this.geodesicPathLength&&(this.actualMeasurementMode="euclidean"),this._mode=e}}function Z(e,t){t.hasZ||(t.z=z(e,t,"ground")??0)}const J=1e5;export{X as MeasurementDataManager};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as e}from"../../../chunks/tslib.es6.js";import t from"../../../core/Accessor.js";import
|
|
5
|
+
import{_ as e}from"../../../chunks/tslib.es6.js";import t from"../../../core/Accessor.js";import"../../../core/has.js";import{abortMaybe as s,destroyMaybe as r}from"../../../core/maybe.js";import{property as a}from"../../../core/accessorSupport/decorators/property.js";import"../../../core/Logger.js";import"../../../core/RandomLCG.js";import{subclass as i}from"../../../core/accessorSupport/decorators/subclass.js";import{getDefaultUnitForView as o}from"../../../support/getDefaultUnitForView.js";import{AnalysisView3D as n}from"./AnalysisView3D.js";import{MeasurementMode as l}from"./interfaces.js";import{AreaMeasurementController as u}from"./AreaMeasurement/support/AreaMeasurementController.js";import{AreaMeasurement3DPathHelper as p}from"./AreaMeasurement/support/AreaMeasurementPathHelper.js";import{AreaMeasurementVisualization as m}from"./AreaMeasurement/support/AreaMeasurementVisualization.js";import{toPreferredLengthUnit as d,toPreferredAreaUnit as h}from"./AreaMeasurement/support/utils.js";import y from"../interactive/measurementTools/areaMeasurement3D/AreaMeasurement3DTool.js";import{connectAnalysisViewToTool as c,removeAnalysisViewTool as g,startExclusiveInteractiveOperation as v}from"../../analysis/analysisViewUtils.js";import{loadGeodesicAreaMeasurementUtils as f}from"../../support/geodesicAreaMeasurementUtils.js";import{loadGeodesicLengthMeasurementUtils as j}from"../../support/geodesicLengthMeasurementUtils.js";let M=class extends(n(t)){constructor(e){super(e),this.type="area-measurement-view-3d",this.analysis=null,this.measurementData=null,this.lastDraggedVertex=null,this.stagedPoint=null,this.mode=l.Auto,this.tool=null,this.userOperation=null}initialize(){const{analysis:e,view:t}=this;this.path=new p({view:t,areaMeasurement:e}),this._analysisVisualization=new m({view:t,analysis:e,analysisViewData:this}),this.addResolvingPromise(Promise.all([f(),j()]).then((([s,r])=>{this.destroyed||(this._analysisController=new u({view:t,analysis:e,analysisViewData:this,geodesicAreaMeasurementUtils:s,geodesicLengthMeasurementUtils:r}))}))),this.addHandles(c(this,y))}destroy(){g(this),this.userOperation=s(this.userOperation),this._analysisController=r(this._analysisController),this._analysisVisualization=r(this._analysisVisualization),this.path.destroy()}get updating(){return!!this._analysisVisualization?.loadingMessages}get result(){const{measurementData:e}=this;if(null==e)return{area:null,mode:null,perimeter:null};const{unit:t}=this;if("euclidean"===e.actualMeasurementMode){const{area:s,perimeterLength:r}=e;return{area:null!=s?h(s,t):null,perimeter:null!=r?d(r,t):null,mode:"euclidean"}}const{geodesicArea:s,pathLength:r}=e;return{area:null!=s?h(s,t):null,perimeter:null!=r?d(r,t):null,mode:"geodesic"}}get viewData(){return this._analysisVisualization.viewData}get areaLabel(){return this._analysisVisualization.areaLabel}get perimeterLengthLabel(){return this._analysisVisualization.perimeterLengthLabel}get validMeasurement(){return this.path.isValidPolygon}get unit(){return this.analysis.unit??o(this.view)}get testData(){}place(e){return v(this,{abortOptions:e,shouldRejectOnCancel:()=>!0})}};e([a()],M.prototype,"_analysisVisualization",void 0),e([a()],M.prototype,"_analysisController",void 0),e([a({readOnly:!0})],M.prototype,"type",void 0),e([a({constructOnly:!0,nonNullable:!0})],M.prototype,"analysis",void 0),e([a()],M.prototype,"updating",null),e([a()],M.prototype,"result",null),e([a()],M.prototype,"measurementData",void 0),e([a()],M.prototype,"viewData",null),e([a()],M.prototype,"areaLabel",null),e([a()],M.prototype,"perimeterLengthLabel",null),e([a()],M.prototype,"validMeasurement",null),e([a()],M.prototype,"path",void 0),e([a()],M.prototype,"lastDraggedVertex",void 0),e([a()],M.prototype,"stagedPoint",void 0),e([a()],M.prototype,"mode",void 0),e([a()],M.prototype,"unit",null),e([a()],M.prototype,"tool",void 0),e([a()],M.prototype,"userOperation",void 0),M=e([i("esri.views.3d.analysis.AreaMeasurementAnalysisView3D")],M);const w=M;export{w as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as t}from"../../../../../chunks/tslib.es6.js";import"../../../../../core/has.js";import{destroyMaybe as e}from"../../../../../core/maybe.js";import{memoize as i}from"../../../../../core/memoize.js";import{ignoreAbortErrors as a}from"../../../../../core/promiseUtils.js";import{syncAndInitial as n,when as s}from"../../../../../core/reactiveUtils.js";import{property as o}from"../../../../../core/accessorSupport/decorators/property.js";import"../../../../../core/Logger.js";import"../../../../../core/RandomLCG.js";import{subclass as r}from"../../../../../core/accessorSupport/decorators/subclass.js";import{UpdatingHandles as p}from"../../../../../core/support/UpdatingHandles.js";import l from"../../../../../geometry/Point.js";import{clonePoint as
|
|
5
|
+
import{_ as t}from"../../../../../chunks/tslib.es6.js";import"../../../../../core/has.js";import{destroyMaybe as e}from"../../../../../core/maybe.js";import{memoize as i}from"../../../../../core/memoize.js";import{ignoreAbortErrors as a}from"../../../../../core/promiseUtils.js";import{syncAndInitial as n,when as s}from"../../../../../core/reactiveUtils.js";import{property as o}from"../../../../../core/accessorSupport/decorators/property.js";import"../../../../../core/Logger.js";import"../../../../../core/RandomLCG.js";import{subclass as r}from"../../../../../core/accessorSupport/decorators/subclass.js";import{UpdatingHandles as p}from"../../../../../core/support/UpdatingHandles.js";import l from"../../../../../geometry/Point.js";import{clonePoint as h}from"../../../../../layers/graphics/hydratedFeatures.js";import{isPrimaryPointerAction as g}from"../../../analysis/support/measurementUtils.js";import{SnappingVisualizer3D as m}from"../../SnappingVisualizer3D.js";import{hideManipulatorWhileDragging as d,screenToMap3D as u}from"../../editingTools/dragEventPipeline3D.js";import c from"./AreaMeasurement3DView.js";import{PickRequest as y}from"../support/PickRequest.js";import{AnalysisToolBase as v}from"../../../../interactive/AnalysisToolBase.js";import{createCoordinateHelper as w}from"../../../../interactive/coordinateHelper.js";import{createManipulatorDragEventPipeline as _}from"../../../../interactive/dragEventPipeline.js";import{sketchKeys as f}from"../../../../interactive/keybindings.js";import{ManipulatorCollection as S}from"../../../../interactive/ManipulatorCollection.js";import{EditGeometry as P}from"../../../../interactive/editGeometry/EditGeometry.js";import{EditGeometryOperations as V}from"../../../../interactive/editGeometry/EditGeometryOperations.js";import{SnappingContext as D}from"../../../../interactive/snapping/SnappingContext.js";import{createSnapDragEventPipelineStep as j}from"../../../../interactive/snapping/SnappingDragPipelineStep.js";import{acquire as M}from"../../../../interactive/snapping/SnappingManagerPool.js";import{SnappingOperation as x}from"../../../../interactive/snapping/SnappingOperation.js";import{setupSnappingToggleHandles as k}from"../../../../interactive/snapping/snappingUtils.js";import{createScreenPointFromEvent as O}from"../../../../support/screenUtils.js";let b=class extends v{constructor(t){super(t),this._updatingHandles=new p,this.polygonState="initial",this.removeIncompleteOnCancel=!1,this.manipulators=new S,this._getSnappingContext=i((t=>new D({elevationInfo:{mode:"absolute-height",offset:0},pointer:t,editGeometryOperations:new V(new P("point",w(!0,!1,this.view.spatialReference)),this.view.state.viewingMode),visualizer:new m})))}initialize(){const{view:t,analysisViewData:e,manipulators:i,visible:o}=this;this.measurementView=new c({view:t,analysisViewData:e,toolState:this,manipulators:i,visible:o});const r=M(t);this._snappingManagerResult=r,this.addHandles(r),this._snappingOperation=new x({view:t}),this._updatingHandles.add((()=>this.stagedPoint),(t=>{this.analysisViewData.stagedPoint=null!=t?h(t,new l):null}),n),k(this,(()=>{const t=this.view.inputManager.latestPointerType??"mouse",e=this._getSnappingContext(t);this._updatingHandles.addPromise(a(this._snappingOperation.snapAgainNearPreviousMapPoint(this._snappingManager,e)))})),this._setupManipulators(),this.addHandles([s((()=>"measured"===this.state),(()=>this.finishToolCreation()),n),this.analysisViewData.path.on("change",(()=>{const t=this.analysisViewData.path;"initial"!==this.polygonState||t.isEmptyPolygon||(t.isValidPolygon?this.polygonState="measured":this.polygonState="drawing")}))])}destroy(){this.measurementView.destroy(),this._set("measurementView",null),this._updatingHandles=e(this._updatingHandles)}get _snappingManager(){return this._snappingManagerResult.snappingManager}get state(){return 0===this.analysisViewData.path.numVertices?"ready":this.analysisViewData.path.isValidPolygon&&"editing"!==this.polygonState?"measured":"measuring"}get cursor(){return this.active&&"measured"!==this.polygonState?"crosshair":null}get updating(){return this._updatingHandles.updating||this._snappingManager.updating}get stagedPoint(){return this._snappingOperation.stagedPoint}set stagedPoint(t){this._snappingOperation.stagedPoint=t}get snappingOptions(){return this._snappingManager.options}finishMeasurement(){const{path:t}=this.analysisViewData;t.numVertices<=2||(t.close(),this.polygonState="measured",this._resetSnappingState(),this.active&&(this.view.activeTool=null))}resetCreated(){super.resetCreated(),this._resetSnappingState(),this.polygonState="initial","measured"===this.state&&this.finishToolCreation()}onShow(){this.measurementView.show()}onHide(){this.measurementView.hide()}onDeactivate(){this._resetSnappingState()}onInputEvent(t){switch(t.type){case"immediate-double-click":this._handleImmediateDoubleClick(t);break;case"immediate-click":this._handleImmediateClick(t);break;case"pointer-move":this._handlePointerMove(t);break;case"drag":this._handleDrag(t);break;case"key-down":this._handleKeyDown(t)}}_setupManipulators(){const t=t=>t.events.on("grab-changed",(()=>{if(this.analysisViewData.path.isValidPolygon){const t=this.manipulators.some((t=>t.manipulator.grabbing));this.polygonState=t?"editing":"measured"}})),e=e=>{this.addHandles([_(e,((t,e,i,a)=>{const n=d(t),s=t.metadata,o=this._snappingManager,r=this._getSnappingContext(a),p=this._updatingHandles,{snappingStep:l,cancelSnapping:g}=j({snappingManager:o,snappingContext:r,updatingHandles:p});i=i.next(n).next((e=>(this.analysisViewData.lastDraggedVertex=null,this.analysisViewData.path.setVertexPosition(s,m),t.location=m,e))).next(g),e.next(n).next(u(this.view)).next(...l).next((e=>{t.location=e.mapEnd,this.analysisViewData.lastDraggedVertex="end"===e.action?null:s,this.analysisViewData.path.setVertexPosition(s,h(e.mapEnd))}));const m=h(this.analysisViewData.path.getVertexPositionAsPoint(s))})),t(e)],e)};this.manipulators.forEach((({manipulator:t})=>{e(t)})),this.addHandles([this.manipulators.on("after-add",(({item:{manipulator:t}})=>{e(t)})),this.manipulators.on("after-remove",(({item:{manipulator:t}})=>this.removeHandles(t)))])}_handleImmediateDoubleClick(t){g(t)&&("drawing"===this.polygonState&&this.finishMeasurement(),t.stopPropagation())}_handleDrag(t){"editing"===this.polygonState&&t.stopPropagation()}_handleImmediateClick(t){if(!g(t))return;const e=O(t),{pointerType:i}=t;if(this.active)switch(this.polygonState){case"initial":if(this._addVertexAt(e,i))return this.stagedPoint=null,this.polygonState="drawing",void t.stopPropagation();break;case"drawing":{const a=this.measurementView.vertexHandleAt(e,i);if(null==a){if(this._addVertexAt(e,i))return this.stagedPoint=null,void t.stopPropagation()}else 0===a.index&&(this.finishMeasurement(),t.stopPropagation());break}}"mouse"===t.pointerType&&this._hoverAt(e)}_handlePointerMove(t){if("mouse"===t.pointerType){const e=O(t);this._hoverAt(e)}}_handleKeyDown(t){const{path:e}=this.analysisViewData;t.key===f.complete&&"drawing"===this.polygonState&&e.numVertices>=3&&(this.stagedPoint=null,this.finishMeasurement(),t.stopPropagation())}_hoverAt(t){const{polygonState:e}=this;if(this.active&&("initial"===e||"drawing"===e)){const e=this._pick(t);if(null!=e?.mapPoint){const t=this._getSnappingContext("mouse");this._updatingHandles.addPromise(a(this._snappingOperation.snap({point:e.mapPoint},this._snappingManager,t)))}}else this.stagedPoint=null}_addVertexAt(t,e){const i=this._pick(t),a=i?.mapPoint;if(null==a)return!1;this.analysis.valid&&"initial"===this.polygonState&&(this.analysis.clear(),this._set("created",!1),this.polygonState="initial");const n=this._getSnappingContext(e),s=this._snappingOperation.update({point:a},this._snappingManager,n),o=h(s,new l);return this.analysisViewData.path.add(o),!0}_pick(t){const e=new y(t);return this.measurementView.pick(e)}_resetSnappingState(){this._snappingManager.doneSnapping(),this._snappingOperation.abort(),this._snappingOperation.stagedPoint=null}get test(){}};t([o({readOnly:!0})],b.prototype,"state",null),t([o()],b.prototype,"polygonState",void 0),t([o({readOnly:!0})],b.prototype,"cursor",null),t([o()],b.prototype,"measurementView",void 0),t([o()],b.prototype,"removeIncompleteOnCancel",void 0),t([o({constructOnly:!0})],b.prototype,"view",void 0),t([o({constructOnly:!0})],b.prototype,"analysis",void 0),t([o({constructOnly:!0})],b.prototype,"analysisViewData",void 0),t([o({readOnly:!0})],b.prototype,"manipulators",void 0),t([o()],b.prototype,"updating",null),t([o()],b.prototype,"stagedPoint",null),t([o()],b.prototype,"snappingOptions",null),b=t([r("esri.views.3d.interactive.measurementTools.areaMeasurement3D.AreaMeasurement3DTool")],b);export{b as default};
|
package/views/3d/interactive/measurementTools/directLineMeasurement3D/DirectLineMeasurement3DTool.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as t}from"../../../../../chunks/tslib.es6.js";import"../../../../../core/has.js";import{destroyMaybe as e}from"../../../../../core/maybe.js";import{memoize as i}from"../../../../../core/memoize.js";import{when as n,watch as a,syncAndInitial as s}from"../../../../../core/reactiveUtils.js";import{property as r}from"../../../../../core/accessorSupport/decorators/property.js";import"../../../../../core/Logger.js";import"../../../../../core/RandomLCG.js";import{subclass as o}from"../../../../../core/accessorSupport/decorators/subclass.js";import{UpdatingHandles as l}from"../../../../../core/support/UpdatingHandles.js";import u from"../../../../../geometry/Point.js";import{clonePoint as p}from"../../../../../layers/graphics/hydratedFeatures.js";import{isPrimaryPointerAction as c}from"../../../analysis/support/measurementUtils.js";import{SnappingVisualizer3D as d}from"../../SnappingVisualizer3D.js";import{SurfaceType as h,hideManipulatorWhileDragging as m,screenToMap3D as g}from"../../editingTools/dragEventPipeline3D.js";import{DirectLineMeasurement3DView as v}from"./DirectLineMeasurement3DView.js";import{getElevationAtPoint as P}from"../../../support/ElevationProvider.js";import{AnalysisToolBase as f}from"../../../../interactive/AnalysisToolBase.js";import{createCoordinateHelper as y}from"../../../../interactive/coordinateHelper.js";import{createManipulatorDragEventPipeline as w,resetProperties as S}from"../../../../interactive/dragEventPipeline.js";import{EditGeometry as _}from"../../../../interactive/editGeometry/EditGeometry.js";import{EditGeometryOperations as M}from"../../../../interactive/editGeometry/EditGeometryOperations.js";import{SnappingContext as D}from"../../../../interactive/snapping/SnappingContext.js";import{createSnapDragEventPipelineStep as j}from"../../../../interactive/snapping/SnappingDragPipelineStep.js";import{acquire as b}from"../../../../interactive/snapping/SnappingManagerPool.js";import{setupSnappingToggleHandles as L}from"../../../../interactive/snapping/snappingUtils.js";import{createScreenPointFromEvent as x}from"../../../../support/screenUtils.js";let V=class extends f{constructor(t){super(t),this._updatingHandles=new l,this._emulatedDrag=null,this.lineState="initial",this.removeIncompleteOnCancel=!1,this.startPointSurfaceLocation=null,this.endPointSurfaceLocation=null,this.cursorPointSurfaceLocation=null,this.startManipulator=null,this.endManipulator=null,this.cursorManipulator=null,this._getSnappingContext=i((t=>new D({elevationInfo:{mode:"absolute-height",offset:0},pointer:t,editGeometryOperations:new M(new _("point",y(!0,!1,this.view.spatialReference)),this.view.state.viewingMode),visualizer:new d})))}initialize(){const{view:t,analysis:e,analysisViewData:i,visible:r}=this;this.measurementView=new v({toolState:this,view:t,analysis:e,analysisViewData:i,visible:r});const o=b(t);this._snappingManagerResult=o,this.addHandles(o);const{start:l,end:c,cursor:d}=this.measurementView.createManipulators(),h=(t,e,i)=>w(t,((t,n,a,s)=>{const r=m(t),o=this._snappingManager,l=this._getSnappingContext(s),c=this._updatingHandles,{lineState:d}=this;a=a.next(r).next(S(this,[i,e])).next((i=>{if("cursorPoint"!==e){const i=this.analysis[e];null!=i&&(t.location=i)}return i}));const h=g(this.view),v=t=>{const n=h(t);return n||"drawing"!==this.lineState&&"initial"!==this.lineState||(this[e]=null,this[i]=null),n};let P=n.next(r).next(v);if("touch"!==s||"editing"===d){const{snappingStep:t,cancelSnapping:e}=j({snappingManager:o,snappingContext:l,updatingHandles:c});a=a.next(e),P=P.next(...t)}P.next((t=>"start"!==t.action?t:null)).next((n=>{const a=p(n.mapEnd,new u);this[e]=a,t.location=a,this[i]=this._surfaceLocation(a,n.surfaceType)}))})),P=t=>t.events.on("grab-changed",(()=>{const t=l.grabbing||c.grabbing;this.lineState=t?"editing":"measured"}));this.addHandles([h(l,"startPoint","startPointSurfaceLocation"),h(c,"endPoint","endPointSurfaceLocation"),h(d,"cursorPoint","cursorPointSurfaceLocation"),P(l),P(c)]),this.manipulators.add(l),this.manipulators.add(c),this.manipulators.add(d),this.startManipulator=l,this.endManipulator=c,this.cursorManipulator=d,this.addHandles([n((()=>"measured"===this.state),(()=>{this.finishToolCreation(),this.active&&(this.view.activeTool=null)}),s),a((()=>({startPointAvailable:null!=this.startPoint,endPointAvailable:null!=this.endPoint})),(({startPointAvailable:t,endPointAvailable:e})=>{this.startManipulator.available=t,this.endManipulator.available=e}),s)]),L(this)}destroy(){this._updatingHandles=e(this._updatingHandles),this.measurementView=e(this.measurementView)}get _snappingManager(){return this._snappingManagerResult.snappingManager}get state(){const{analysis:t}=this;if(null==t.startPoint&&null==t.endPoint)return"ready";const{lineState:e}=this;return this.validMeasurement&&"editing"!==e&&"drawing"!==e?"measured":"measuring"}get cursor(){return!this.active||"ready"!==this.state&&"measured"===this.lineState?null:"crosshair"}get startPoint(){return this.analysis.startPoint}set startPoint(t){this.analysis.startPoint=t}get endPoint(){return this.analysis.endPoint}set endPoint(t){this.analysis.endPoint=t}get cursorPoint(){return this.measurementView.cursorPoint}set cursorPoint(t){this.measurementView.cursorPoint=t}get snappingOptions(){return this._snappingManager.options}get validMeasurement(){return null!=this.analysis.startPoint&&null!=this.analysis.endPoint}get updating(){return this._updatingHandles.updating||this._snappingManager.updating}resetCreated(){super.resetCreated(),this.lineState="initial",this.cursorPoint=null}onShow(){this.measurementView.show()}onHide(){this.measurementView.hide()}
|
|
5
|
+
import{_ as t}from"../../../../../chunks/tslib.es6.js";import"../../../../../core/has.js";import{destroyMaybe as e}from"../../../../../core/maybe.js";import{memoize as i}from"../../../../../core/memoize.js";import{when as n,watch as a,syncAndInitial as s}from"../../../../../core/reactiveUtils.js";import{property as r}from"../../../../../core/accessorSupport/decorators/property.js";import"../../../../../core/Logger.js";import"../../../../../core/RandomLCG.js";import{subclass as o}from"../../../../../core/accessorSupport/decorators/subclass.js";import{UpdatingHandles as l}from"../../../../../core/support/UpdatingHandles.js";import u from"../../../../../geometry/Point.js";import{clonePoint as p}from"../../../../../layers/graphics/hydratedFeatures.js";import{isPrimaryPointerAction as c}from"../../../analysis/support/measurementUtils.js";import{SnappingVisualizer3D as d}from"../../SnappingVisualizer3D.js";import{SurfaceType as h,hideManipulatorWhileDragging as m,screenToMap3D as g}from"../../editingTools/dragEventPipeline3D.js";import{DirectLineMeasurement3DView as v}from"./DirectLineMeasurement3DView.js";import{getElevationAtPoint as P}from"../../../support/ElevationProvider.js";import{AnalysisToolBase as f}from"../../../../interactive/AnalysisToolBase.js";import{createCoordinateHelper as y}from"../../../../interactive/coordinateHelper.js";import{createManipulatorDragEventPipeline as w,resetProperties as S}from"../../../../interactive/dragEventPipeline.js";import{EditGeometry as _}from"../../../../interactive/editGeometry/EditGeometry.js";import{EditGeometryOperations as M}from"../../../../interactive/editGeometry/EditGeometryOperations.js";import{SnappingContext as D}from"../../../../interactive/snapping/SnappingContext.js";import{createSnapDragEventPipelineStep as j}from"../../../../interactive/snapping/SnappingDragPipelineStep.js";import{acquire as b}from"../../../../interactive/snapping/SnappingManagerPool.js";import{setupSnappingToggleHandles as L}from"../../../../interactive/snapping/snappingUtils.js";import{createScreenPointFromEvent as x}from"../../../../support/screenUtils.js";let V=class extends f{constructor(t){super(t),this._updatingHandles=new l,this._emulatedDrag=null,this.lineState="initial",this.removeIncompleteOnCancel=!1,this.startPointSurfaceLocation=null,this.endPointSurfaceLocation=null,this.cursorPointSurfaceLocation=null,this.startManipulator=null,this.endManipulator=null,this.cursorManipulator=null,this._getSnappingContext=i((t=>new D({elevationInfo:{mode:"absolute-height",offset:0},pointer:t,editGeometryOperations:new M(new _("point",y(!0,!1,this.view.spatialReference)),this.view.state.viewingMode),visualizer:new d})))}initialize(){const{view:t,analysis:e,analysisViewData:i,visible:r}=this;this.measurementView=new v({toolState:this,view:t,analysis:e,analysisViewData:i,visible:r});const o=b(t);this._snappingManagerResult=o,this.addHandles(o);const{start:l,end:c,cursor:d}=this.measurementView.createManipulators(),h=(t,e,i)=>w(t,((t,n,a,s)=>{const r=m(t),o=this._snappingManager,l=this._getSnappingContext(s),c=this._updatingHandles,{lineState:d}=this;a=a.next(r).next(S(this,[i,e])).next((i=>{if("cursorPoint"!==e){const i=this.analysis[e];null!=i&&(t.location=i)}return i}));const h=g(this.view),v=t=>{const n=h(t);return n||"drawing"!==this.lineState&&"initial"!==this.lineState||(this[e]=null,this[i]=null),n};let P=n.next(r).next(v);if("touch"!==s||"editing"===d){const{snappingStep:t,cancelSnapping:e}=j({snappingManager:o,snappingContext:l,updatingHandles:c});a=a.next(e),P=P.next(...t)}P.next((t=>"start"!==t.action?t:null)).next((n=>{const a=p(n.mapEnd,new u);this[e]=a,t.location=a,this[i]=this._surfaceLocation(a,n.surfaceType)}))})),P=t=>t.events.on("grab-changed",(()=>{const t=l.grabbing||c.grabbing;this.lineState=t?"editing":"measured"}));this.addHandles([h(l,"startPoint","startPointSurfaceLocation"),h(c,"endPoint","endPointSurfaceLocation"),h(d,"cursorPoint","cursorPointSurfaceLocation"),P(l),P(c)]),this.manipulators.add(l),this.manipulators.add(c),this.manipulators.add(d),this.startManipulator=l,this.endManipulator=c,this.cursorManipulator=d,this.addHandles([n((()=>"measured"===this.state),(()=>{this.finishToolCreation(),this.active&&(this.view.activeTool=null)}),s),a((()=>({startPointAvailable:null!=this.startPoint,endPointAvailable:null!=this.endPoint})),(({startPointAvailable:t,endPointAvailable:e})=>{this.startManipulator.available=t,this.endManipulator.available=e}),s)]),L(this)}destroy(){this._updatingHandles=e(this._updatingHandles),this.measurementView=e(this.measurementView)}get _snappingManager(){return this._snappingManagerResult.snappingManager}get state(){const{analysis:t}=this;if(null==t.startPoint&&null==t.endPoint)return"ready";const{lineState:e}=this;return this.validMeasurement&&"editing"!==e&&"drawing"!==e?"measured":"measuring"}get cursor(){return!this.active||"ready"!==this.state&&"measured"===this.lineState?null:"crosshair"}get startPoint(){return this.analysis.startPoint}set startPoint(t){this.analysis.startPoint=t}get endPoint(){return this.analysis.endPoint}set endPoint(t){this.analysis.endPoint=t}get cursorPoint(){return this.measurementView.cursorPoint}set cursorPoint(t){this.measurementView.cursorPoint=t}get snappingOptions(){return this._snappingManager.options}get validMeasurement(){return null!=this.analysis.startPoint&&null!=this.analysis.endPoint}get updating(){return this._updatingHandles.updating||this._snappingManager.updating}resetCreated(){super.resetCreated(),this.lineState="initial",this.cursorPoint=null,"measured"===this.state&&this.finishToolCreation()}onShow(){this.measurementView.show()}onHide(){this.measurementView.hide()}onDeactivate(){this._emulatedDrag?.cancel(),this._emulatedDrag=null}onInputEvent(t){switch(t.type){case"immediate-click":this._handleImmediateClick(t);break;case"pointer-move":this._handlePointerMove(t)}}_handlePointerMove(t){if(!this.active||this.view.navigating)return;if("measured"===this.state&&"initial"===this.lineState)return;const{pointerType:e}=t;if("mouse"!==e)return;const i=x(t),{lineState:n,cursorManipulator:a,endManipulator:s}=this;let r=!1;null==this.cursorPoint&&(this._emulatedDrag?.cancel(),this._emulatedDrag=C(a,e,i),r=!0),"initial"===n&&(this._emulatedDrag?.update(i),r=!0),"drawing"===n&&(s.events.emit("drag",{action:"update",start:i,screenPoint:i}),r=!0),r&&t.stopPropagation()}_handleImmediateClick(t){if(!this.active||!c(t))return;const e=x(t),{pointerType:i}=t,{cursorManipulator:n,startManipulator:a,endManipulator:s,lineState:r}=this;let o=!1;switch(null==this.cursorPoint&&(this._emulatedDrag?.cancel(),this._emulatedDrag=C(n,i,e)),r){case"initial":if(this._emulatedDrag?.update(e),null!=this.cursorPoint){this._emulatedDrag?.end(e),this._emulatedDrag=null,this.endPoint=null;const{cursorPoint:t}=this;this.startPoint=t,this.startPointSurfaceLocation=this.cursorPointSurfaceLocation,a.location=t,a.interactive=!1,s.interactive=!1,this.lineState="drawing",this._emulatedDrag=C(s,i,e),o=!0}break;case"drawing":this._emulatedDrag?.update(e),null!=this.endPoint&&(this._emulatedDrag?.end(e),this._emulatedDrag=null,a.interactive=!0,s.interactive=!0,this.lineState="measured",o=!0)}o&&t.stopPropagation()}_surfaceLocation(t,e){return e===h.GROUND?"on-the-surface":(t.z??0)>=this._getElevation(t)?"above-the-surface":"below-the-surface"}_getElevation(t){return this.view.basemapTerrain.ready?P(this.view.elevationProvider,t)??0:0}get test(){}};function C(t,e,i){return t.events.emit("drag",{action:"start",pointerType:e,start:i,screenPoint:i}),{update:e=>t.events.emit("drag",{action:"update",start:e,screenPoint:e}),end:e=>t.events.emit("drag",{action:"end",start:e,screenPoint:e}),cancel:()=>t.events.emit("drag",{action:"cancel"})}}t([r({readOnly:!0})],V.prototype,"state",null),t([r()],V.prototype,"lineState",void 0),t([r({readOnly:!0})],V.prototype,"cursor",null),t([r()],V.prototype,"startPoint",null),t([r()],V.prototype,"endPoint",null),t([r()],V.prototype,"cursorPoint",null),t([r({constructOnly:!0})],V.prototype,"analysis",void 0),t([r({constructOnly:!0})],V.prototype,"analysisViewData",void 0),t([r()],V.prototype,"measurementView",void 0),t([r()],V.prototype,"removeIncompleteOnCancel",void 0),t([r({constructOnly:!0})],V.prototype,"view",void 0),t([r({readOnly:!0})],V.prototype,"validMeasurement",null),t([r({value:null})],V.prototype,"startPointSurfaceLocation",void 0),t([r({value:null})],V.prototype,"endPointSurfaceLocation",void 0),t([r({value:null})],V.prototype,"cursorPointSurfaceLocation",void 0),t([r()],V.prototype,"updating",null),V=t([o("esri.views.3d.interactive.measurementTools.directLineMeasurement3D.DirectLineMeasurement3DTool")],V);export{V as default};
|