react-native-cesium 1.0.6 → 1.2.0
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/README.md +64 -11
- package/ReactNativeCesium.podspec +1 -1
- package/android/CMakeLists.txt +5 -3
- package/android/src/main/cpp/CesiumBridgeAndroid.cpp +197 -227
- package/android/src/main/cpp/CesiumBridgeAndroid.h +48 -49
- package/android/src/main/cpp/cpp-adapter.cpp +2 -2
- package/android/src/main/cpp/vulkan/VulkanBackend.cpp +1010 -569
- package/android/src/main/cpp/vulkan/VulkanBackend.h +121 -12
- package/android/src/main/cpp/vulkan/shaders/sky.frag +20 -10
- package/android/src/main/java/com/margelo/nitro/reactnativecesium/CesiumBridgeJNI.kt +28 -0
- package/android/src/main/java/com/margelo/nitro/reactnativecesium/HybridCesiumView.kt +295 -58
- package/cpp/engine/CameraSmoother.cpp +99 -0
- package/cpp/engine/CameraSmoother.hpp +29 -0
- package/cpp/engine/CameraTargetState.cpp +49 -0
- package/cpp/engine/CameraTargetState.hpp +121 -0
- package/cpp/engine/CesiumEngine.cpp +206 -60
- package/cpp/engine/CesiumEngine.hpp +77 -10
- package/cpp/engine/EngineTunables.hpp +79 -0
- package/cpp/engine/GeoidConverter.cpp +36 -0
- package/cpp/engine/GeoidConverter.hpp +10 -0
- package/cpp/engine/GlobeCamera.cpp +7 -2
- package/cpp/engine/MetricsAggregator.cpp +71 -0
- package/cpp/engine/MetricsAggregator.hpp +54 -0
- package/cpp/engine/TileLifecycleManager.cpp +0 -12
- package/cpp/engine/TileLifecycleManager.hpp +0 -3
- package/cpp/third_party/egm96/EGM96.c +289 -0
- package/cpp/third_party/egm96/EGM96.h +45 -0
- package/cpp/third_party/egm96/EGM96_data.h +65372 -0
- package/ios/CesiumBridge.h +24 -5
- package/ios/CesiumBridge.mm +149 -271
- package/ios/HybridCesiumView.swift +197 -40
- package/ios/metal/MetalBackend.mm +72 -23
- package/lib/typescript/src/specs/cesium-view.nitro.d.ts +26 -0
- package/lib/typescript/src/specs/cesium-view.nitro.d.ts.map +1 -1
- package/nitrogen/generated/android/c++/JCesiumMetrics.hpp +5 -1
- package/nitrogen/generated/android/c++/JHybridCesiumViewSpec.cpp +109 -1
- package/nitrogen/generated/android/c++/JHybridCesiumViewSpec.hpp +24 -0
- package/nitrogen/generated/android/c++/views/JHybridCesiumViewStateUpdater.cpp +48 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativecesium/CameraState.kt +25 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativecesium/CesiumMetrics.kt +32 -2
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativecesium/HybridCesiumViewSpec.kt +72 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativecesium/Quaternion.kt +19 -0
- package/nitrogen/generated/ios/ReactNativeCesium-Swift-Cxx-Bridge.hpp +30 -0
- package/nitrogen/generated/ios/c++/HybridCesiumViewSpecSwift.hpp +85 -1
- package/nitrogen/generated/ios/c++/views/HybridCesiumViewComponent.mm +60 -0
- package/nitrogen/generated/ios/swift/CesiumMetrics.swift +7 -2
- package/nitrogen/generated/ios/swift/HybridCesiumViewSpec.swift +12 -0
- package/nitrogen/generated/ios/swift/HybridCesiumViewSpec_cxx.swift +288 -0
- package/nitrogen/generated/shared/c++/CesiumMetrics.hpp +5 -1
- package/nitrogen/generated/shared/c++/HybridCesiumViewSpec.cpp +24 -0
- package/nitrogen/generated/shared/c++/HybridCesiumViewSpec.hpp +25 -1
- package/nitrogen/generated/shared/c++/views/HybridCesiumViewComponent.cpp +132 -0
- package/nitrogen/generated/shared/c++/views/HybridCesiumViewComponent.hpp +13 -1
- package/nitrogen/generated/shared/json/CesiumViewConfig.json +12 -0
- package/package.json +4 -4
- package/scripts/cesium/clone.mjs +1 -1
- package/src/specs/cesium-view.nitro.ts +29 -0
- package/cpp/engine/DeletionQueue.cpp +0 -28
- package/cpp/engine/DeletionQueue.hpp +0 -28
|
@@ -17,9 +17,9 @@ namespace margelo::nitro::reactnativecesium { struct Quaternion; }
|
|
|
17
17
|
#include <string>
|
|
18
18
|
#include "CameraState.hpp"
|
|
19
19
|
#include "JCameraState.hpp"
|
|
20
|
+
#include <optional>
|
|
20
21
|
#include "CesiumMetrics.hpp"
|
|
21
22
|
#include <functional>
|
|
22
|
-
#include <optional>
|
|
23
23
|
#include "JFunc_void_CesiumMetrics.hpp"
|
|
24
24
|
#include <NitroModules/JNICallable.hpp>
|
|
25
25
|
#include "JCesiumMetrics.hpp"
|
|
@@ -139,6 +139,114 @@ namespace margelo::nitro::reactnativecesium {
|
|
|
139
139
|
static const auto method = _javaPart->javaClassStatic()->getMethod<void(double /* ionImageryAssetId */)>("setIonImageryAssetId");
|
|
140
140
|
method(_javaPart, ionImageryAssetId);
|
|
141
141
|
}
|
|
142
|
+
std::optional<double> JHybridCesiumViewSpec::getMaximumCachedMiB() {
|
|
143
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<jni::local_ref<jni::JDouble>()>("getMaximumCachedMiB");
|
|
144
|
+
auto __result = method(_javaPart);
|
|
145
|
+
return __result != nullptr ? std::make_optional(__result->value()) : std::nullopt;
|
|
146
|
+
}
|
|
147
|
+
void JHybridCesiumViewSpec::setMaximumCachedMiB(std::optional<double> maximumCachedMiB) {
|
|
148
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<void(jni::alias_ref<jni::JDouble> /* maximumCachedMiB */)>("setMaximumCachedMiB");
|
|
149
|
+
method(_javaPart, maximumCachedMiB.has_value() ? jni::JDouble::valueOf(maximumCachedMiB.value()) : nullptr);
|
|
150
|
+
}
|
|
151
|
+
std::optional<bool> JHybridCesiumViewSpec::getPreloadAncestors() {
|
|
152
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<jni::local_ref<jni::JBoolean>()>("getPreloadAncestors");
|
|
153
|
+
auto __result = method(_javaPart);
|
|
154
|
+
return __result != nullptr ? std::make_optional(static_cast<bool>(__result->value())) : std::nullopt;
|
|
155
|
+
}
|
|
156
|
+
void JHybridCesiumViewSpec::setPreloadAncestors(std::optional<bool> preloadAncestors) {
|
|
157
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<void(jni::alias_ref<jni::JBoolean> /* preloadAncestors */)>("setPreloadAncestors");
|
|
158
|
+
method(_javaPart, preloadAncestors.has_value() ? jni::JBoolean::valueOf(preloadAncestors.value()) : nullptr);
|
|
159
|
+
}
|
|
160
|
+
std::optional<bool> JHybridCesiumViewSpec::getPreloadSiblings() {
|
|
161
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<jni::local_ref<jni::JBoolean>()>("getPreloadSiblings");
|
|
162
|
+
auto __result = method(_javaPart);
|
|
163
|
+
return __result != nullptr ? std::make_optional(static_cast<bool>(__result->value())) : std::nullopt;
|
|
164
|
+
}
|
|
165
|
+
void JHybridCesiumViewSpec::setPreloadSiblings(std::optional<bool> preloadSiblings) {
|
|
166
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<void(jni::alias_ref<jni::JBoolean> /* preloadSiblings */)>("setPreloadSiblings");
|
|
167
|
+
method(_javaPart, preloadSiblings.has_value() ? jni::JBoolean::valueOf(preloadSiblings.value()) : nullptr);
|
|
168
|
+
}
|
|
169
|
+
std::optional<bool> JHybridCesiumViewSpec::getForbidHoles() {
|
|
170
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<jni::local_ref<jni::JBoolean>()>("getForbidHoles");
|
|
171
|
+
auto __result = method(_javaPart);
|
|
172
|
+
return __result != nullptr ? std::make_optional(static_cast<bool>(__result->value())) : std::nullopt;
|
|
173
|
+
}
|
|
174
|
+
void JHybridCesiumViewSpec::setForbidHoles(std::optional<bool> forbidHoles) {
|
|
175
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<void(jni::alias_ref<jni::JBoolean> /* forbidHoles */)>("setForbidHoles");
|
|
176
|
+
method(_javaPart, forbidHoles.has_value() ? jni::JBoolean::valueOf(forbidHoles.value()) : nullptr);
|
|
177
|
+
}
|
|
178
|
+
std::optional<bool> JHybridCesiumViewSpec::getEnableWaterMask() {
|
|
179
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<jni::local_ref<jni::JBoolean>()>("getEnableWaterMask");
|
|
180
|
+
auto __result = method(_javaPart);
|
|
181
|
+
return __result != nullptr ? std::make_optional(static_cast<bool>(__result->value())) : std::nullopt;
|
|
182
|
+
}
|
|
183
|
+
void JHybridCesiumViewSpec::setEnableWaterMask(std::optional<bool> enableWaterMask) {
|
|
184
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<void(jni::alias_ref<jni::JBoolean> /* enableWaterMask */)>("setEnableWaterMask");
|
|
185
|
+
method(_javaPart, enableWaterMask.has_value() ? jni::JBoolean::valueOf(enableWaterMask.value()) : nullptr);
|
|
186
|
+
}
|
|
187
|
+
std::optional<bool> JHybridCesiumViewSpec::getEnableFogCulling() {
|
|
188
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<jni::local_ref<jni::JBoolean>()>("getEnableFogCulling");
|
|
189
|
+
auto __result = method(_javaPart);
|
|
190
|
+
return __result != nullptr ? std::make_optional(static_cast<bool>(__result->value())) : std::nullopt;
|
|
191
|
+
}
|
|
192
|
+
void JHybridCesiumViewSpec::setEnableFogCulling(std::optional<bool> enableFogCulling) {
|
|
193
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<void(jni::alias_ref<jni::JBoolean> /* enableFogCulling */)>("setEnableFogCulling");
|
|
194
|
+
method(_javaPart, enableFogCulling.has_value() ? jni::JBoolean::valueOf(enableFogCulling.value()) : nullptr);
|
|
195
|
+
}
|
|
196
|
+
std::optional<bool> JHybridCesiumViewSpec::getEnforceCulledScreenSpaceError() {
|
|
197
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<jni::local_ref<jni::JBoolean>()>("getEnforceCulledScreenSpaceError");
|
|
198
|
+
auto __result = method(_javaPart);
|
|
199
|
+
return __result != nullptr ? std::make_optional(static_cast<bool>(__result->value())) : std::nullopt;
|
|
200
|
+
}
|
|
201
|
+
void JHybridCesiumViewSpec::setEnforceCulledScreenSpaceError(std::optional<bool> enforceCulledScreenSpaceError) {
|
|
202
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<void(jni::alias_ref<jni::JBoolean> /* enforceCulledScreenSpaceError */)>("setEnforceCulledScreenSpaceError");
|
|
203
|
+
method(_javaPart, enforceCulledScreenSpaceError.has_value() ? jni::JBoolean::valueOf(enforceCulledScreenSpaceError.value()) : nullptr);
|
|
204
|
+
}
|
|
205
|
+
std::optional<double> JHybridCesiumViewSpec::getCulledScreenSpaceError() {
|
|
206
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<jni::local_ref<jni::JDouble>()>("getCulledScreenSpaceError");
|
|
207
|
+
auto __result = method(_javaPart);
|
|
208
|
+
return __result != nullptr ? std::make_optional(__result->value()) : std::nullopt;
|
|
209
|
+
}
|
|
210
|
+
void JHybridCesiumViewSpec::setCulledScreenSpaceError(std::optional<double> culledScreenSpaceError) {
|
|
211
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<void(jni::alias_ref<jni::JDouble> /* culledScreenSpaceError */)>("setCulledScreenSpaceError");
|
|
212
|
+
method(_javaPart, culledScreenSpaceError.has_value() ? jni::JDouble::valueOf(culledScreenSpaceError.value()) : nullptr);
|
|
213
|
+
}
|
|
214
|
+
std::optional<bool> JHybridCesiumViewSpec::getEnableLodTransitionPeriod() {
|
|
215
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<jni::local_ref<jni::JBoolean>()>("getEnableLodTransitionPeriod");
|
|
216
|
+
auto __result = method(_javaPart);
|
|
217
|
+
return __result != nullptr ? std::make_optional(static_cast<bool>(__result->value())) : std::nullopt;
|
|
218
|
+
}
|
|
219
|
+
void JHybridCesiumViewSpec::setEnableLodTransitionPeriod(std::optional<bool> enableLodTransitionPeriod) {
|
|
220
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<void(jni::alias_ref<jni::JBoolean> /* enableLodTransitionPeriod */)>("setEnableLodTransitionPeriod");
|
|
221
|
+
method(_javaPart, enableLodTransitionPeriod.has_value() ? jni::JBoolean::valueOf(enableLodTransitionPeriod.value()) : nullptr);
|
|
222
|
+
}
|
|
223
|
+
std::optional<double> JHybridCesiumViewSpec::getLodTransitionLength() {
|
|
224
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<jni::local_ref<jni::JDouble>()>("getLodTransitionLength");
|
|
225
|
+
auto __result = method(_javaPart);
|
|
226
|
+
return __result != nullptr ? std::make_optional(__result->value()) : std::nullopt;
|
|
227
|
+
}
|
|
228
|
+
void JHybridCesiumViewSpec::setLodTransitionLength(std::optional<double> lodTransitionLength) {
|
|
229
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<void(jni::alias_ref<jni::JDouble> /* lodTransitionLength */)>("setLodTransitionLength");
|
|
230
|
+
method(_javaPart, lodTransitionLength.has_value() ? jni::JDouble::valueOf(lodTransitionLength.value()) : nullptr);
|
|
231
|
+
}
|
|
232
|
+
std::optional<double> JHybridCesiumViewSpec::getSqliteCacheMaxRows() {
|
|
233
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<jni::local_ref<jni::JDouble>()>("getSqliteCacheMaxRows");
|
|
234
|
+
auto __result = method(_javaPart);
|
|
235
|
+
return __result != nullptr ? std::make_optional(__result->value()) : std::nullopt;
|
|
236
|
+
}
|
|
237
|
+
void JHybridCesiumViewSpec::setSqliteCacheMaxRows(std::optional<double> sqliteCacheMaxRows) {
|
|
238
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<void(jni::alias_ref<jni::JDouble> /* sqliteCacheMaxRows */)>("setSqliteCacheMaxRows");
|
|
239
|
+
method(_javaPart, sqliteCacheMaxRows.has_value() ? jni::JDouble::valueOf(sqliteCacheMaxRows.value()) : nullptr);
|
|
240
|
+
}
|
|
241
|
+
std::optional<double> JHybridCesiumViewSpec::getTaskProcessorThreads() {
|
|
242
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<jni::local_ref<jni::JDouble>()>("getTaskProcessorThreads");
|
|
243
|
+
auto __result = method(_javaPart);
|
|
244
|
+
return __result != nullptr ? std::make_optional(__result->value()) : std::nullopt;
|
|
245
|
+
}
|
|
246
|
+
void JHybridCesiumViewSpec::setTaskProcessorThreads(std::optional<double> taskProcessorThreads) {
|
|
247
|
+
static const auto method = _javaPart->javaClassStatic()->getMethod<void(jni::alias_ref<jni::JDouble> /* taskProcessorThreads */)>("setTaskProcessorThreads");
|
|
248
|
+
method(_javaPart, taskProcessorThreads.has_value() ? jni::JDouble::valueOf(taskProcessorThreads.value()) : nullptr);
|
|
249
|
+
}
|
|
142
250
|
std::optional<std::function<void(const CesiumMetrics& /* metrics */)>> JHybridCesiumViewSpec::getOnMetrics() {
|
|
143
251
|
static const auto method = _javaPart->javaClassStatic()->getMethod<jni::local_ref<JFunc_void_CesiumMetrics::javaobject>()>("getOnMetrics_cxx");
|
|
144
252
|
auto __result = method(_javaPart);
|
|
@@ -68,6 +68,30 @@ namespace margelo::nitro::reactnativecesium {
|
|
|
68
68
|
void setMsaaSampleCount(double msaaSampleCount) override;
|
|
69
69
|
double getIonImageryAssetId() override;
|
|
70
70
|
void setIonImageryAssetId(double ionImageryAssetId) override;
|
|
71
|
+
std::optional<double> getMaximumCachedMiB() override;
|
|
72
|
+
void setMaximumCachedMiB(std::optional<double> maximumCachedMiB) override;
|
|
73
|
+
std::optional<bool> getPreloadAncestors() override;
|
|
74
|
+
void setPreloadAncestors(std::optional<bool> preloadAncestors) override;
|
|
75
|
+
std::optional<bool> getPreloadSiblings() override;
|
|
76
|
+
void setPreloadSiblings(std::optional<bool> preloadSiblings) override;
|
|
77
|
+
std::optional<bool> getForbidHoles() override;
|
|
78
|
+
void setForbidHoles(std::optional<bool> forbidHoles) override;
|
|
79
|
+
std::optional<bool> getEnableWaterMask() override;
|
|
80
|
+
void setEnableWaterMask(std::optional<bool> enableWaterMask) override;
|
|
81
|
+
std::optional<bool> getEnableFogCulling() override;
|
|
82
|
+
void setEnableFogCulling(std::optional<bool> enableFogCulling) override;
|
|
83
|
+
std::optional<bool> getEnforceCulledScreenSpaceError() override;
|
|
84
|
+
void setEnforceCulledScreenSpaceError(std::optional<bool> enforceCulledScreenSpaceError) override;
|
|
85
|
+
std::optional<double> getCulledScreenSpaceError() override;
|
|
86
|
+
void setCulledScreenSpaceError(std::optional<double> culledScreenSpaceError) override;
|
|
87
|
+
std::optional<bool> getEnableLodTransitionPeriod() override;
|
|
88
|
+
void setEnableLodTransitionPeriod(std::optional<bool> enableLodTransitionPeriod) override;
|
|
89
|
+
std::optional<double> getLodTransitionLength() override;
|
|
90
|
+
void setLodTransitionLength(std::optional<double> lodTransitionLength) override;
|
|
91
|
+
std::optional<double> getSqliteCacheMaxRows() override;
|
|
92
|
+
void setSqliteCacheMaxRows(std::optional<double> sqliteCacheMaxRows) override;
|
|
93
|
+
std::optional<double> getTaskProcessorThreads() override;
|
|
94
|
+
void setTaskProcessorThreads(std::optional<double> taskProcessorThreads) override;
|
|
71
95
|
std::optional<std::function<void(const CesiumMetrics& /* metrics */)>> getOnMetrics() override;
|
|
72
96
|
void setOnMetrics(const std::optional<std::function<void(const CesiumMetrics& /* metrics */)>>& onMetrics) override;
|
|
73
97
|
|
|
@@ -73,6 +73,54 @@ void JHybridCesiumViewStateUpdater::updateViewProps(jni::alias_ref<jni::JClass>
|
|
|
73
73
|
hybridView->setIonImageryAssetId(props->ionImageryAssetId.value);
|
|
74
74
|
props->ionImageryAssetId.isDirty = false;
|
|
75
75
|
}
|
|
76
|
+
if (props->maximumCachedMiB.isDirty) {
|
|
77
|
+
hybridView->setMaximumCachedMiB(props->maximumCachedMiB.value);
|
|
78
|
+
props->maximumCachedMiB.isDirty = false;
|
|
79
|
+
}
|
|
80
|
+
if (props->preloadAncestors.isDirty) {
|
|
81
|
+
hybridView->setPreloadAncestors(props->preloadAncestors.value);
|
|
82
|
+
props->preloadAncestors.isDirty = false;
|
|
83
|
+
}
|
|
84
|
+
if (props->preloadSiblings.isDirty) {
|
|
85
|
+
hybridView->setPreloadSiblings(props->preloadSiblings.value);
|
|
86
|
+
props->preloadSiblings.isDirty = false;
|
|
87
|
+
}
|
|
88
|
+
if (props->forbidHoles.isDirty) {
|
|
89
|
+
hybridView->setForbidHoles(props->forbidHoles.value);
|
|
90
|
+
props->forbidHoles.isDirty = false;
|
|
91
|
+
}
|
|
92
|
+
if (props->enableWaterMask.isDirty) {
|
|
93
|
+
hybridView->setEnableWaterMask(props->enableWaterMask.value);
|
|
94
|
+
props->enableWaterMask.isDirty = false;
|
|
95
|
+
}
|
|
96
|
+
if (props->enableFogCulling.isDirty) {
|
|
97
|
+
hybridView->setEnableFogCulling(props->enableFogCulling.value);
|
|
98
|
+
props->enableFogCulling.isDirty = false;
|
|
99
|
+
}
|
|
100
|
+
if (props->enforceCulledScreenSpaceError.isDirty) {
|
|
101
|
+
hybridView->setEnforceCulledScreenSpaceError(props->enforceCulledScreenSpaceError.value);
|
|
102
|
+
props->enforceCulledScreenSpaceError.isDirty = false;
|
|
103
|
+
}
|
|
104
|
+
if (props->culledScreenSpaceError.isDirty) {
|
|
105
|
+
hybridView->setCulledScreenSpaceError(props->culledScreenSpaceError.value);
|
|
106
|
+
props->culledScreenSpaceError.isDirty = false;
|
|
107
|
+
}
|
|
108
|
+
if (props->enableLodTransitionPeriod.isDirty) {
|
|
109
|
+
hybridView->setEnableLodTransitionPeriod(props->enableLodTransitionPeriod.value);
|
|
110
|
+
props->enableLodTransitionPeriod.isDirty = false;
|
|
111
|
+
}
|
|
112
|
+
if (props->lodTransitionLength.isDirty) {
|
|
113
|
+
hybridView->setLodTransitionLength(props->lodTransitionLength.value);
|
|
114
|
+
props->lodTransitionLength.isDirty = false;
|
|
115
|
+
}
|
|
116
|
+
if (props->sqliteCacheMaxRows.isDirty) {
|
|
117
|
+
hybridView->setSqliteCacheMaxRows(props->sqliteCacheMaxRows.value);
|
|
118
|
+
props->sqliteCacheMaxRows.isDirty = false;
|
|
119
|
+
}
|
|
120
|
+
if (props->taskProcessorThreads.isDirty) {
|
|
121
|
+
hybridView->setTaskProcessorThreads(props->taskProcessorThreads.value);
|
|
122
|
+
props->taskProcessorThreads.isDirty = false;
|
|
123
|
+
}
|
|
76
124
|
if (props->onMetrics.isDirty) {
|
|
77
125
|
hybridView->setOnMetrics(props->onMetrics.value);
|
|
78
126
|
props->onMetrics.isDirty = false;
|
package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativecesium/CameraState.kt
CHANGED
|
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativecesium
|
|
|
9
9
|
|
|
10
10
|
import androidx.annotation.Keep
|
|
11
11
|
import com.facebook.proguard.annotations.DoNotStrip
|
|
12
|
+
import java.util.Objects
|
|
12
13
|
|
|
13
14
|
|
|
14
15
|
/**
|
|
@@ -41,6 +42,30 @@ data class CameraState(
|
|
|
41
42
|
) {
|
|
42
43
|
/* primary constructor */
|
|
43
44
|
|
|
45
|
+
override fun equals(other: Any?): Boolean {
|
|
46
|
+
if (this === other) return true
|
|
47
|
+
if (other !is CameraState) return false
|
|
48
|
+
return Objects.deepEquals(this.latitude, other.latitude)
|
|
49
|
+
&& Objects.deepEquals(this.longitude, other.longitude)
|
|
50
|
+
&& Objects.deepEquals(this.altitude, other.altitude)
|
|
51
|
+
&& Objects.deepEquals(this.heading, other.heading)
|
|
52
|
+
&& Objects.deepEquals(this.pitch, other.pitch)
|
|
53
|
+
&& Objects.deepEquals(this.roll, other.roll)
|
|
54
|
+
&& Objects.deepEquals(this.verticalFovDeg, other.verticalFovDeg)
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
override fun hashCode(): Int {
|
|
58
|
+
return arrayOf(
|
|
59
|
+
latitude,
|
|
60
|
+
longitude,
|
|
61
|
+
altitude,
|
|
62
|
+
heading,
|
|
63
|
+
pitch,
|
|
64
|
+
roll,
|
|
65
|
+
verticalFovDeg
|
|
66
|
+
).contentDeepHashCode()
|
|
67
|
+
}
|
|
68
|
+
|
|
44
69
|
companion object {
|
|
45
70
|
/**
|
|
46
71
|
* Constructor called from C++
|
package/nitrogen/generated/android/kotlin/com/margelo/nitro/reactnativecesium/CesiumMetrics.kt
CHANGED
|
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativecesium
|
|
|
9
9
|
|
|
10
10
|
import androidx.annotation.Keep
|
|
11
11
|
import com.facebook.proguard.annotations.DoNotStrip
|
|
12
|
+
import java.util.Objects
|
|
12
13
|
|
|
13
14
|
|
|
14
15
|
/**
|
|
@@ -34,6 +35,9 @@ data class CesiumMetrics(
|
|
|
34
35
|
val ionTokenConfigured: Boolean,
|
|
35
36
|
@DoNotStrip
|
|
36
37
|
@Keep
|
|
38
|
+
val tlsConfigured: Boolean,
|
|
39
|
+
@DoNotStrip
|
|
40
|
+
@Keep
|
|
37
41
|
val tilesetReady: Boolean,
|
|
38
42
|
@DoNotStrip
|
|
39
43
|
@Keep
|
|
@@ -41,6 +45,32 @@ data class CesiumMetrics(
|
|
|
41
45
|
) {
|
|
42
46
|
/* primary constructor */
|
|
43
47
|
|
|
48
|
+
override fun equals(other: Any?): Boolean {
|
|
49
|
+
if (this === other) return true
|
|
50
|
+
if (other !is CesiumMetrics) return false
|
|
51
|
+
return Objects.deepEquals(this.fps, other.fps)
|
|
52
|
+
&& Objects.deepEquals(this.tilesRendered, other.tilesRendered)
|
|
53
|
+
&& Objects.deepEquals(this.tilesLoading, other.tilesLoading)
|
|
54
|
+
&& Objects.deepEquals(this.tilesVisited, other.tilesVisited)
|
|
55
|
+
&& Objects.deepEquals(this.ionTokenConfigured, other.ionTokenConfigured)
|
|
56
|
+
&& Objects.deepEquals(this.tlsConfigured, other.tlsConfigured)
|
|
57
|
+
&& Objects.deepEquals(this.tilesetReady, other.tilesetReady)
|
|
58
|
+
&& Objects.deepEquals(this.creditsPlainText, other.creditsPlainText)
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
override fun hashCode(): Int {
|
|
62
|
+
return arrayOf(
|
|
63
|
+
fps,
|
|
64
|
+
tilesRendered,
|
|
65
|
+
tilesLoading,
|
|
66
|
+
tilesVisited,
|
|
67
|
+
ionTokenConfigured,
|
|
68
|
+
tlsConfigured,
|
|
69
|
+
tilesetReady,
|
|
70
|
+
creditsPlainText
|
|
71
|
+
).contentDeepHashCode()
|
|
72
|
+
}
|
|
73
|
+
|
|
44
74
|
companion object {
|
|
45
75
|
/**
|
|
46
76
|
* Constructor called from C++
|
|
@@ -49,8 +79,8 @@ data class CesiumMetrics(
|
|
|
49
79
|
@Keep
|
|
50
80
|
@Suppress("unused")
|
|
51
81
|
@JvmStatic
|
|
52
|
-
private fun fromCpp(fps: Double, tilesRendered: Double, tilesLoading: Double, tilesVisited: Double, ionTokenConfigured: Boolean, tilesetReady: Boolean, creditsPlainText: String): CesiumMetrics {
|
|
53
|
-
return CesiumMetrics(fps, tilesRendered, tilesLoading, tilesVisited, ionTokenConfigured, tilesetReady, creditsPlainText)
|
|
82
|
+
private fun fromCpp(fps: Double, tilesRendered: Double, tilesLoading: Double, tilesVisited: Double, ionTokenConfigured: Boolean, tlsConfigured: Boolean, tilesetReady: Boolean, creditsPlainText: String): CesiumMetrics {
|
|
83
|
+
return CesiumMetrics(fps, tilesRendered, tilesLoading, tilesVisited, ionTokenConfigured, tlsConfigured, tilesetReady, creditsPlainText)
|
|
54
84
|
}
|
|
55
85
|
}
|
|
56
86
|
}
|
|
@@ -81,6 +81,78 @@ abstract class HybridCesiumViewSpec: HybridView() {
|
|
|
81
81
|
@set:Keep
|
|
82
82
|
abstract var ionImageryAssetId: Double
|
|
83
83
|
|
|
84
|
+
@get:DoNotStrip
|
|
85
|
+
@get:Keep
|
|
86
|
+
@set:DoNotStrip
|
|
87
|
+
@set:Keep
|
|
88
|
+
abstract var maximumCachedMiB: Double?
|
|
89
|
+
|
|
90
|
+
@get:DoNotStrip
|
|
91
|
+
@get:Keep
|
|
92
|
+
@set:DoNotStrip
|
|
93
|
+
@set:Keep
|
|
94
|
+
abstract var preloadAncestors: Boolean?
|
|
95
|
+
|
|
96
|
+
@get:DoNotStrip
|
|
97
|
+
@get:Keep
|
|
98
|
+
@set:DoNotStrip
|
|
99
|
+
@set:Keep
|
|
100
|
+
abstract var preloadSiblings: Boolean?
|
|
101
|
+
|
|
102
|
+
@get:DoNotStrip
|
|
103
|
+
@get:Keep
|
|
104
|
+
@set:DoNotStrip
|
|
105
|
+
@set:Keep
|
|
106
|
+
abstract var forbidHoles: Boolean?
|
|
107
|
+
|
|
108
|
+
@get:DoNotStrip
|
|
109
|
+
@get:Keep
|
|
110
|
+
@set:DoNotStrip
|
|
111
|
+
@set:Keep
|
|
112
|
+
abstract var enableWaterMask: Boolean?
|
|
113
|
+
|
|
114
|
+
@get:DoNotStrip
|
|
115
|
+
@get:Keep
|
|
116
|
+
@set:DoNotStrip
|
|
117
|
+
@set:Keep
|
|
118
|
+
abstract var enableFogCulling: Boolean?
|
|
119
|
+
|
|
120
|
+
@get:DoNotStrip
|
|
121
|
+
@get:Keep
|
|
122
|
+
@set:DoNotStrip
|
|
123
|
+
@set:Keep
|
|
124
|
+
abstract var enforceCulledScreenSpaceError: Boolean?
|
|
125
|
+
|
|
126
|
+
@get:DoNotStrip
|
|
127
|
+
@get:Keep
|
|
128
|
+
@set:DoNotStrip
|
|
129
|
+
@set:Keep
|
|
130
|
+
abstract var culledScreenSpaceError: Double?
|
|
131
|
+
|
|
132
|
+
@get:DoNotStrip
|
|
133
|
+
@get:Keep
|
|
134
|
+
@set:DoNotStrip
|
|
135
|
+
@set:Keep
|
|
136
|
+
abstract var enableLodTransitionPeriod: Boolean?
|
|
137
|
+
|
|
138
|
+
@get:DoNotStrip
|
|
139
|
+
@get:Keep
|
|
140
|
+
@set:DoNotStrip
|
|
141
|
+
@set:Keep
|
|
142
|
+
abstract var lodTransitionLength: Double?
|
|
143
|
+
|
|
144
|
+
@get:DoNotStrip
|
|
145
|
+
@get:Keep
|
|
146
|
+
@set:DoNotStrip
|
|
147
|
+
@set:Keep
|
|
148
|
+
abstract var sqliteCacheMaxRows: Double?
|
|
149
|
+
|
|
150
|
+
@get:DoNotStrip
|
|
151
|
+
@get:Keep
|
|
152
|
+
@set:DoNotStrip
|
|
153
|
+
@set:Keep
|
|
154
|
+
abstract var taskProcessorThreads: Double?
|
|
155
|
+
|
|
84
156
|
abstract var onMetrics: ((metrics: CesiumMetrics) -> Unit)?
|
|
85
157
|
|
|
86
158
|
private var onMetrics_cxx: Func_void_CesiumMetrics?
|
|
@@ -9,6 +9,7 @@ package com.margelo.nitro.reactnativecesium
|
|
|
9
9
|
|
|
10
10
|
import androidx.annotation.Keep
|
|
11
11
|
import com.facebook.proguard.annotations.DoNotStrip
|
|
12
|
+
import java.util.Objects
|
|
12
13
|
|
|
13
14
|
|
|
14
15
|
/**
|
|
@@ -32,6 +33,24 @@ data class Quaternion(
|
|
|
32
33
|
) {
|
|
33
34
|
/* primary constructor */
|
|
34
35
|
|
|
36
|
+
override fun equals(other: Any?): Boolean {
|
|
37
|
+
if (this === other) return true
|
|
38
|
+
if (other !is Quaternion) return false
|
|
39
|
+
return Objects.deepEquals(this.w, other.w)
|
|
40
|
+
&& Objects.deepEquals(this.x, other.x)
|
|
41
|
+
&& Objects.deepEquals(this.y, other.y)
|
|
42
|
+
&& Objects.deepEquals(this.z, other.z)
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
override fun hashCode(): Int {
|
|
46
|
+
return arrayOf(
|
|
47
|
+
w,
|
|
48
|
+
x,
|
|
49
|
+
y,
|
|
50
|
+
z
|
|
51
|
+
).contentDeepHashCode()
|
|
52
|
+
}
|
|
53
|
+
|
|
35
54
|
companion object {
|
|
36
55
|
/**
|
|
37
56
|
* Constructor called from C++
|
|
@@ -41,6 +41,36 @@ namespace ReactNativeCesium { class HybridCesiumViewSpec_cxx; }
|
|
|
41
41
|
*/
|
|
42
42
|
namespace margelo::nitro::reactnativecesium::bridge::swift {
|
|
43
43
|
|
|
44
|
+
// pragma MARK: std::optional<double>
|
|
45
|
+
/**
|
|
46
|
+
* Specialized version of `std::optional<double>`.
|
|
47
|
+
*/
|
|
48
|
+
using std__optional_double_ = std::optional<double>;
|
|
49
|
+
inline std::optional<double> create_std__optional_double_(const double& value) noexcept {
|
|
50
|
+
return std::optional<double>(value);
|
|
51
|
+
}
|
|
52
|
+
inline bool has_value_std__optional_double_(const std::optional<double>& optional) noexcept {
|
|
53
|
+
return optional.has_value();
|
|
54
|
+
}
|
|
55
|
+
inline double get_std__optional_double_(const std::optional<double>& optional) noexcept {
|
|
56
|
+
return optional.value();
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
// pragma MARK: std::optional<bool>
|
|
60
|
+
/**
|
|
61
|
+
* Specialized version of `std::optional<bool>`.
|
|
62
|
+
*/
|
|
63
|
+
using std__optional_bool_ = std::optional<bool>;
|
|
64
|
+
inline std::optional<bool> create_std__optional_bool_(const bool& value) noexcept {
|
|
65
|
+
return std::optional<bool>(value);
|
|
66
|
+
}
|
|
67
|
+
inline bool has_value_std__optional_bool_(const std::optional<bool>& optional) noexcept {
|
|
68
|
+
return optional.has_value();
|
|
69
|
+
}
|
|
70
|
+
inline bool get_std__optional_bool_(const std::optional<bool>& optional) noexcept {
|
|
71
|
+
return optional.value();
|
|
72
|
+
}
|
|
73
|
+
|
|
44
74
|
// pragma MARK: std::function<void(const CesiumMetrics& /* metrics */)>
|
|
45
75
|
/**
|
|
46
76
|
* Specialized version of `std::function<void(const CesiumMetrics&)>`.
|
|
@@ -21,9 +21,9 @@ namespace margelo::nitro::reactnativecesium { struct Quaternion; }
|
|
|
21
21
|
|
|
22
22
|
#include <string>
|
|
23
23
|
#include "CameraState.hpp"
|
|
24
|
+
#include <optional>
|
|
24
25
|
#include "CesiumMetrics.hpp"
|
|
25
26
|
#include <functional>
|
|
26
|
-
#include <optional>
|
|
27
27
|
#include <NitroModules/Promise.hpp>
|
|
28
28
|
#include "Quaternion.hpp"
|
|
29
29
|
|
|
@@ -128,6 +128,90 @@ namespace margelo::nitro::reactnativecesium {
|
|
|
128
128
|
inline void setIonImageryAssetId(double ionImageryAssetId) noexcept override {
|
|
129
129
|
_swiftPart.setIonImageryAssetId(std::forward<decltype(ionImageryAssetId)>(ionImageryAssetId));
|
|
130
130
|
}
|
|
131
|
+
inline std::optional<double> getMaximumCachedMiB() noexcept override {
|
|
132
|
+
auto __result = _swiftPart.getMaximumCachedMiB();
|
|
133
|
+
return __result;
|
|
134
|
+
}
|
|
135
|
+
inline void setMaximumCachedMiB(std::optional<double> maximumCachedMiB) noexcept override {
|
|
136
|
+
_swiftPart.setMaximumCachedMiB(maximumCachedMiB);
|
|
137
|
+
}
|
|
138
|
+
inline std::optional<bool> getPreloadAncestors() noexcept override {
|
|
139
|
+
auto __result = _swiftPart.getPreloadAncestors();
|
|
140
|
+
return __result;
|
|
141
|
+
}
|
|
142
|
+
inline void setPreloadAncestors(std::optional<bool> preloadAncestors) noexcept override {
|
|
143
|
+
_swiftPart.setPreloadAncestors(preloadAncestors);
|
|
144
|
+
}
|
|
145
|
+
inline std::optional<bool> getPreloadSiblings() noexcept override {
|
|
146
|
+
auto __result = _swiftPart.getPreloadSiblings();
|
|
147
|
+
return __result;
|
|
148
|
+
}
|
|
149
|
+
inline void setPreloadSiblings(std::optional<bool> preloadSiblings) noexcept override {
|
|
150
|
+
_swiftPart.setPreloadSiblings(preloadSiblings);
|
|
151
|
+
}
|
|
152
|
+
inline std::optional<bool> getForbidHoles() noexcept override {
|
|
153
|
+
auto __result = _swiftPart.getForbidHoles();
|
|
154
|
+
return __result;
|
|
155
|
+
}
|
|
156
|
+
inline void setForbidHoles(std::optional<bool> forbidHoles) noexcept override {
|
|
157
|
+
_swiftPart.setForbidHoles(forbidHoles);
|
|
158
|
+
}
|
|
159
|
+
inline std::optional<bool> getEnableWaterMask() noexcept override {
|
|
160
|
+
auto __result = _swiftPart.getEnableWaterMask();
|
|
161
|
+
return __result;
|
|
162
|
+
}
|
|
163
|
+
inline void setEnableWaterMask(std::optional<bool> enableWaterMask) noexcept override {
|
|
164
|
+
_swiftPart.setEnableWaterMask(enableWaterMask);
|
|
165
|
+
}
|
|
166
|
+
inline std::optional<bool> getEnableFogCulling() noexcept override {
|
|
167
|
+
auto __result = _swiftPart.getEnableFogCulling();
|
|
168
|
+
return __result;
|
|
169
|
+
}
|
|
170
|
+
inline void setEnableFogCulling(std::optional<bool> enableFogCulling) noexcept override {
|
|
171
|
+
_swiftPart.setEnableFogCulling(enableFogCulling);
|
|
172
|
+
}
|
|
173
|
+
inline std::optional<bool> getEnforceCulledScreenSpaceError() noexcept override {
|
|
174
|
+
auto __result = _swiftPart.getEnforceCulledScreenSpaceError();
|
|
175
|
+
return __result;
|
|
176
|
+
}
|
|
177
|
+
inline void setEnforceCulledScreenSpaceError(std::optional<bool> enforceCulledScreenSpaceError) noexcept override {
|
|
178
|
+
_swiftPart.setEnforceCulledScreenSpaceError(enforceCulledScreenSpaceError);
|
|
179
|
+
}
|
|
180
|
+
inline std::optional<double> getCulledScreenSpaceError() noexcept override {
|
|
181
|
+
auto __result = _swiftPart.getCulledScreenSpaceError();
|
|
182
|
+
return __result;
|
|
183
|
+
}
|
|
184
|
+
inline void setCulledScreenSpaceError(std::optional<double> culledScreenSpaceError) noexcept override {
|
|
185
|
+
_swiftPart.setCulledScreenSpaceError(culledScreenSpaceError);
|
|
186
|
+
}
|
|
187
|
+
inline std::optional<bool> getEnableLodTransitionPeriod() noexcept override {
|
|
188
|
+
auto __result = _swiftPart.getEnableLodTransitionPeriod();
|
|
189
|
+
return __result;
|
|
190
|
+
}
|
|
191
|
+
inline void setEnableLodTransitionPeriod(std::optional<bool> enableLodTransitionPeriod) noexcept override {
|
|
192
|
+
_swiftPart.setEnableLodTransitionPeriod(enableLodTransitionPeriod);
|
|
193
|
+
}
|
|
194
|
+
inline std::optional<double> getLodTransitionLength() noexcept override {
|
|
195
|
+
auto __result = _swiftPart.getLodTransitionLength();
|
|
196
|
+
return __result;
|
|
197
|
+
}
|
|
198
|
+
inline void setLodTransitionLength(std::optional<double> lodTransitionLength) noexcept override {
|
|
199
|
+
_swiftPart.setLodTransitionLength(lodTransitionLength);
|
|
200
|
+
}
|
|
201
|
+
inline std::optional<double> getSqliteCacheMaxRows() noexcept override {
|
|
202
|
+
auto __result = _swiftPart.getSqliteCacheMaxRows();
|
|
203
|
+
return __result;
|
|
204
|
+
}
|
|
205
|
+
inline void setSqliteCacheMaxRows(std::optional<double> sqliteCacheMaxRows) noexcept override {
|
|
206
|
+
_swiftPart.setSqliteCacheMaxRows(sqliteCacheMaxRows);
|
|
207
|
+
}
|
|
208
|
+
inline std::optional<double> getTaskProcessorThreads() noexcept override {
|
|
209
|
+
auto __result = _swiftPart.getTaskProcessorThreads();
|
|
210
|
+
return __result;
|
|
211
|
+
}
|
|
212
|
+
inline void setTaskProcessorThreads(std::optional<double> taskProcessorThreads) noexcept override {
|
|
213
|
+
_swiftPart.setTaskProcessorThreads(taskProcessorThreads);
|
|
214
|
+
}
|
|
131
215
|
inline std::optional<std::function<void(const CesiumMetrics& /* metrics */)>> getOnMetrics() noexcept override {
|
|
132
216
|
auto __result = _swiftPart.getOnMetrics();
|
|
133
217
|
return __result;
|
|
@@ -124,6 +124,66 @@ using namespace margelo::nitro::reactnativecesium::views;
|
|
|
124
124
|
swiftPart.setIonImageryAssetId(newViewProps.ionImageryAssetId.value);
|
|
125
125
|
newViewProps.ionImageryAssetId.isDirty = false;
|
|
126
126
|
}
|
|
127
|
+
// maximumCachedMiB: optional
|
|
128
|
+
if (newViewProps.maximumCachedMiB.isDirty) {
|
|
129
|
+
swiftPart.setMaximumCachedMiB(newViewProps.maximumCachedMiB.value);
|
|
130
|
+
newViewProps.maximumCachedMiB.isDirty = false;
|
|
131
|
+
}
|
|
132
|
+
// preloadAncestors: optional
|
|
133
|
+
if (newViewProps.preloadAncestors.isDirty) {
|
|
134
|
+
swiftPart.setPreloadAncestors(newViewProps.preloadAncestors.value);
|
|
135
|
+
newViewProps.preloadAncestors.isDirty = false;
|
|
136
|
+
}
|
|
137
|
+
// preloadSiblings: optional
|
|
138
|
+
if (newViewProps.preloadSiblings.isDirty) {
|
|
139
|
+
swiftPart.setPreloadSiblings(newViewProps.preloadSiblings.value);
|
|
140
|
+
newViewProps.preloadSiblings.isDirty = false;
|
|
141
|
+
}
|
|
142
|
+
// forbidHoles: optional
|
|
143
|
+
if (newViewProps.forbidHoles.isDirty) {
|
|
144
|
+
swiftPart.setForbidHoles(newViewProps.forbidHoles.value);
|
|
145
|
+
newViewProps.forbidHoles.isDirty = false;
|
|
146
|
+
}
|
|
147
|
+
// enableWaterMask: optional
|
|
148
|
+
if (newViewProps.enableWaterMask.isDirty) {
|
|
149
|
+
swiftPart.setEnableWaterMask(newViewProps.enableWaterMask.value);
|
|
150
|
+
newViewProps.enableWaterMask.isDirty = false;
|
|
151
|
+
}
|
|
152
|
+
// enableFogCulling: optional
|
|
153
|
+
if (newViewProps.enableFogCulling.isDirty) {
|
|
154
|
+
swiftPart.setEnableFogCulling(newViewProps.enableFogCulling.value);
|
|
155
|
+
newViewProps.enableFogCulling.isDirty = false;
|
|
156
|
+
}
|
|
157
|
+
// enforceCulledScreenSpaceError: optional
|
|
158
|
+
if (newViewProps.enforceCulledScreenSpaceError.isDirty) {
|
|
159
|
+
swiftPart.setEnforceCulledScreenSpaceError(newViewProps.enforceCulledScreenSpaceError.value);
|
|
160
|
+
newViewProps.enforceCulledScreenSpaceError.isDirty = false;
|
|
161
|
+
}
|
|
162
|
+
// culledScreenSpaceError: optional
|
|
163
|
+
if (newViewProps.culledScreenSpaceError.isDirty) {
|
|
164
|
+
swiftPart.setCulledScreenSpaceError(newViewProps.culledScreenSpaceError.value);
|
|
165
|
+
newViewProps.culledScreenSpaceError.isDirty = false;
|
|
166
|
+
}
|
|
167
|
+
// enableLodTransitionPeriod: optional
|
|
168
|
+
if (newViewProps.enableLodTransitionPeriod.isDirty) {
|
|
169
|
+
swiftPart.setEnableLodTransitionPeriod(newViewProps.enableLodTransitionPeriod.value);
|
|
170
|
+
newViewProps.enableLodTransitionPeriod.isDirty = false;
|
|
171
|
+
}
|
|
172
|
+
// lodTransitionLength: optional
|
|
173
|
+
if (newViewProps.lodTransitionLength.isDirty) {
|
|
174
|
+
swiftPart.setLodTransitionLength(newViewProps.lodTransitionLength.value);
|
|
175
|
+
newViewProps.lodTransitionLength.isDirty = false;
|
|
176
|
+
}
|
|
177
|
+
// sqliteCacheMaxRows: optional
|
|
178
|
+
if (newViewProps.sqliteCacheMaxRows.isDirty) {
|
|
179
|
+
swiftPart.setSqliteCacheMaxRows(newViewProps.sqliteCacheMaxRows.value);
|
|
180
|
+
newViewProps.sqliteCacheMaxRows.isDirty = false;
|
|
181
|
+
}
|
|
182
|
+
// taskProcessorThreads: optional
|
|
183
|
+
if (newViewProps.taskProcessorThreads.isDirty) {
|
|
184
|
+
swiftPart.setTaskProcessorThreads(newViewProps.taskProcessorThreads.value);
|
|
185
|
+
newViewProps.taskProcessorThreads.isDirty = false;
|
|
186
|
+
}
|
|
127
187
|
// onMetrics: optional
|
|
128
188
|
if (newViewProps.onMetrics.isDirty) {
|
|
129
189
|
swiftPart.setOnMetrics(newViewProps.onMetrics.value);
|
|
@@ -18,8 +18,8 @@ public extension CesiumMetrics {
|
|
|
18
18
|
/**
|
|
19
19
|
* Create a new instance of `CesiumMetrics`.
|
|
20
20
|
*/
|
|
21
|
-
init(fps: Double, tilesRendered: Double, tilesLoading: Double, tilesVisited: Double, ionTokenConfigured: Bool, tilesetReady: Bool, creditsPlainText: String) {
|
|
22
|
-
self.init(fps, tilesRendered, tilesLoading, tilesVisited, ionTokenConfigured, tilesetReady, std.string(creditsPlainText))
|
|
21
|
+
init(fps: Double, tilesRendered: Double, tilesLoading: Double, tilesVisited: Double, ionTokenConfigured: Bool, tlsConfigured: Bool, tilesetReady: Bool, creditsPlainText: String) {
|
|
22
|
+
self.init(fps, tilesRendered, tilesLoading, tilesVisited, ionTokenConfigured, tlsConfigured, tilesetReady, std.string(creditsPlainText))
|
|
23
23
|
}
|
|
24
24
|
|
|
25
25
|
@inline(__always)
|
|
@@ -47,6 +47,11 @@ public extension CesiumMetrics {
|
|
|
47
47
|
return self.__ionTokenConfigured
|
|
48
48
|
}
|
|
49
49
|
|
|
50
|
+
@inline(__always)
|
|
51
|
+
var tlsConfigured: Bool {
|
|
52
|
+
return self.__tlsConfigured
|
|
53
|
+
}
|
|
54
|
+
|
|
50
55
|
@inline(__always)
|
|
51
56
|
var tilesetReady: Bool {
|
|
52
57
|
return self.__tilesetReady
|