@aguacerowx/react-native 0.0.8 → 0.0.9
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/android/build/.transforms/78b892a9dae44f36e51ff0649e9c6e36/transformed/classes/classes_dex/classes.dex +0 -0
- package/android/build/.transforms/f4de14556a82e99f0d27ddcab762b219/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/com/aguacerowx/reactnative/GridRenderLayer$VertexInfo.dex +0 -0
- package/android/build/.transforms/f4de14556a82e99f0d27ddcab762b219/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/com/aguacerowx/reactnative/GridRenderLayer.dex +0 -0
- package/android/build/.transforms/f4de14556a82e99f0d27ddcab762b219/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/com/aguacerowx/reactnative/GridRenderLayerView.dex +0 -0
- package/android/build/.transforms/f4de14556a82e99f0d27ddcab762b219/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/com/aguacerowx/reactnative/InspectorModule.dex +0 -0
- package/android/build/.transforms/f4de14556a82e99f0d27ddcab762b219/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/com/aguacerowx/reactnative/WeatherFrameProcessorModule.dex +0 -0
- package/android/build/intermediates/compile_library_classes_jar/debug/bundleLibCompileToJarDebug/classes.jar +0 -0
- package/android/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes/com/aguacerowx/reactnative/GridRenderLayer$VertexInfo.class +0 -0
- package/android/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes/com/aguacerowx/reactnative/GridRenderLayer.class +0 -0
- package/android/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes/com/aguacerowx/reactnative/GridRenderLayerView.class +0 -0
- package/android/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes/com/aguacerowx/reactnative/InspectorModule.class +0 -0
- package/android/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes/com/aguacerowx/reactnative/WeatherFrameProcessorModule.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/aguacerowx/reactnative/GridRenderLayer$VertexInfo.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/aguacerowx/reactnative/GridRenderLayer.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/aguacerowx/reactnative/GridRenderLayerView.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/aguacerowx/reactnative/InspectorModule.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/aguacerowx/reactnative/WeatherFrameProcessorModule.class +0 -0
- package/android/build/intermediates/runtime_library_classes_jar/debug/bundleLibRuntimeToJarDebug/classes.jar +0 -0
- package/android/build/tmp/compileDebugJavaWithJavac/compileTransaction/stash-dir/GridRenderLayerView.class.uniqueId2 +0 -0
- package/android/build/tmp/compileDebugJavaWithJavac/compileTransaction/stash-dir/InspectorModule.class.uniqueId0 +0 -0
- package/android/build/tmp/compileDebugJavaWithJavac/previous-compilation-data.bin +0 -0
- package/android/src/main/java/com/aguacerowx/reactnative/GridRenderLayer.java +126 -122
- package/android/src/main/java/com/aguacerowx/reactnative/GridRenderLayerView.java +3 -1
- package/android/src/main/java/com/aguacerowx/reactnative/InspectorModule.java +13 -5
- package/android/src/main/java/com/aguacerowx/reactnative/WeatherFrameProcessorModule.java +4 -18
- package/ios/AguaceroPackage.m +19 -0
- package/ios/FragmentUniforms.swift +14 -0
- package/ios/GridRenderLayer.swift +959 -59
- package/ios/GridRenderLayerBridge.swift +30 -0
- package/ios/GridRenderLayerManager.mm +104 -98
- package/ios/GridRenderLayerView.h +23 -0
- package/ios/GridRenderLayerView.m +199 -0
- package/ios/InspectorDataCache.swift +66 -0
- package/ios/InspectorModule.m +10 -0
- package/ios/InspectorModule.swift +64 -0
- package/ios/Shaders.metal +131 -0
- package/ios/WeatherFrameProcessorModule.m +16 -0
- package/ios/WeatherFrameProcessorModule.swift +104 -0
- package/ios/aguacerowx-react-native.podspec +21 -14
- package/lib/commonjs/android/build/intermediates/compile_library_classes_jar/debug/bundleLibCompileToJarDebug/classes.jar +0 -0
- package/lib/commonjs/android/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes/com/aguacerowx/reactnative/GridRenderLayer$VertexInfo.class +0 -0
- package/lib/commonjs/android/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes/com/aguacerowx/reactnative/GridRenderLayer.class +0 -0
- package/lib/commonjs/android/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes/com/aguacerowx/reactnative/GridRenderLayerView.class +0 -0
- package/lib/commonjs/android/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes/com/aguacerowx/reactnative/InspectorModule.class +0 -0
- package/lib/commonjs/android/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes/com/aguacerowx/reactnative/WeatherFrameProcessorModule.class +0 -0
- package/lib/commonjs/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/aguacerowx/reactnative/GridRenderLayer$VertexInfo.class +0 -0
- package/lib/commonjs/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/aguacerowx/reactnative/GridRenderLayer.class +0 -0
- package/lib/commonjs/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/aguacerowx/reactnative/GridRenderLayerView.class +0 -0
- package/lib/commonjs/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/aguacerowx/reactnative/InspectorModule.class +0 -0
- package/lib/commonjs/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/aguacerowx/reactnative/WeatherFrameProcessorModule.class +0 -0
- package/lib/commonjs/android/build/intermediates/runtime_library_classes_jar/debug/bundleLibRuntimeToJarDebug/classes.jar +0 -0
- package/lib/commonjs/android/build/tmp/compileDebugJavaWithJavac/compileTransaction/stash-dir/GridRenderLayerView.class.uniqueId2 +0 -0
- package/lib/commonjs/android/build/tmp/compileDebugJavaWithJavac/compileTransaction/stash-dir/InspectorModule.class.uniqueId0 +0 -0
- package/lib/commonjs/android/build/tmp/compileDebugJavaWithJavac/previous-compilation-data.bin +0 -0
- package/lib/commonjs/android/src/main/java/com/aguacerowx/reactnative/GridRenderLayer.java +126 -122
- package/lib/commonjs/android/src/main/java/com/aguacerowx/reactnative/GridRenderLayerView.java +3 -1
- package/lib/commonjs/android/src/main/java/com/aguacerowx/reactnative/InspectorModule.java +13 -5
- package/lib/commonjs/android/src/main/java/com/aguacerowx/reactnative/WeatherFrameProcessorModule.java +4 -18
- package/lib/commonjs/ios/AguaceroPackage.m +19 -0
- package/lib/commonjs/ios/FragmentUniforms.swift +14 -0
- package/lib/commonjs/ios/GridRenderLayer.swift +962 -0
- package/lib/commonjs/ios/GridRenderLayerBridge.swift +30 -0
- package/lib/commonjs/ios/GridRenderLayerManager.mm +146 -0
- package/lib/commonjs/ios/GridRenderLayerView.h +23 -0
- package/lib/commonjs/ios/GridRenderLayerView.m +199 -0
- package/lib/commonjs/ios/InspectorDataCache.swift +66 -0
- package/lib/commonjs/ios/InspectorModule.m +10 -0
- package/lib/commonjs/ios/InspectorModule.swift +64 -0
- package/lib/commonjs/ios/Shaders.metal +131 -0
- package/lib/commonjs/ios/WeatherFrameProcessorModule.m +16 -0
- package/lib/commonjs/ios/WeatherFrameProcessorModule.swift +104 -0
- package/lib/commonjs/ios/aguacerowx-react-native.podspec +36 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/AguaceroCore.js +1003 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/AguaceroCore.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/coordinate_configs.js +381 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/coordinate_configs.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/default-colormaps.js +1229 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/default-colormaps.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/dictionaries.js +4023 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/dictionaries.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/events.js +38 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/events.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/fill-layer-worker.js +30 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/fill-layer-worker.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/getBundleId.js +27 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/getBundleId.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/index.js +47 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/index.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/map-styles.js +301 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/map-styles.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/unitConversions.js +126 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/unitConversions.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/package.json +48 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/AguaceroCore.js +1029 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/AguaceroCore.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/coordinate_configs.js +381 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/coordinate_configs.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/default-colormaps.js +1229 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/default-colormaps.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/dictionaries.js +4023 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/dictionaries.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/events.js +38 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/events.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/fill-layer-worker.js +30 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/fill-layer-worker.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/getBundleId.js +27 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/getBundleId.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/index.js +41 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/index.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/map-styles.js +301 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/map-styles.js.map +1 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/unitConversions.js +126 -0
- package/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/unitConversions.js.map +1 -0
- package/lib/commonjs/package.json +9 -17
- package/lib/commonjs/src/GridRenderLayer.js +32 -7
- package/lib/commonjs/src/GridRenderLayer.js.map +1 -1
- package/lib/commonjs/src/MapManager.js +1 -4
- package/lib/commonjs/src/MapManager.js.map +1 -1
- package/lib/commonjs/src/WeatherLayerManager.js +236 -210
- package/lib/commonjs/src/WeatherLayerManager.js.map +1 -1
- package/lib/module/android/build/intermediates/compile_library_classes_jar/debug/bundleLibCompileToJarDebug/classes.jar +0 -0
- package/lib/module/android/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes/com/aguacerowx/reactnative/GridRenderLayer$VertexInfo.class +0 -0
- package/lib/module/android/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes/com/aguacerowx/reactnative/GridRenderLayer.class +0 -0
- package/lib/module/android/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes/com/aguacerowx/reactnative/GridRenderLayerView.class +0 -0
- package/lib/module/android/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes/com/aguacerowx/reactnative/InspectorModule.class +0 -0
- package/lib/module/android/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes/com/aguacerowx/reactnative/WeatherFrameProcessorModule.class +0 -0
- package/lib/module/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/aguacerowx/reactnative/GridRenderLayer$VertexInfo.class +0 -0
- package/lib/module/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/aguacerowx/reactnative/GridRenderLayer.class +0 -0
- package/lib/module/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/aguacerowx/reactnative/GridRenderLayerView.class +0 -0
- package/lib/module/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/aguacerowx/reactnative/InspectorModule.class +0 -0
- package/lib/module/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/aguacerowx/reactnative/WeatherFrameProcessorModule.class +0 -0
- package/lib/module/android/build/intermediates/runtime_library_classes_jar/debug/bundleLibRuntimeToJarDebug/classes.jar +0 -0
- package/lib/module/android/build/tmp/compileDebugJavaWithJavac/compileTransaction/stash-dir/GridRenderLayerView.class.uniqueId2 +0 -0
- package/lib/module/android/build/tmp/compileDebugJavaWithJavac/compileTransaction/stash-dir/InspectorModule.class.uniqueId0 +0 -0
- package/lib/module/android/build/tmp/compileDebugJavaWithJavac/previous-compilation-data.bin +0 -0
- package/lib/module/android/src/main/java/com/aguacerowx/reactnative/GridRenderLayer.java +126 -122
- package/lib/module/android/src/main/java/com/aguacerowx/reactnative/GridRenderLayerView.java +3 -1
- package/lib/module/android/src/main/java/com/aguacerowx/reactnative/InspectorModule.java +13 -5
- package/lib/module/android/src/main/java/com/aguacerowx/reactnative/WeatherFrameProcessorModule.java +4 -18
- package/lib/module/ios/AguaceroPackage.m +19 -0
- package/lib/module/ios/FragmentUniforms.swift +14 -0
- package/lib/module/ios/GridRenderLayer.swift +962 -0
- package/lib/module/ios/GridRenderLayerBridge.swift +30 -0
- package/lib/module/ios/GridRenderLayerManager.mm +146 -0
- package/lib/module/ios/GridRenderLayerView.h +23 -0
- package/lib/module/ios/GridRenderLayerView.m +199 -0
- package/lib/module/ios/InspectorDataCache.swift +66 -0
- package/lib/module/ios/InspectorModule.m +10 -0
- package/lib/module/ios/InspectorModule.swift +64 -0
- package/lib/module/ios/Shaders.metal +131 -0
- package/lib/module/ios/WeatherFrameProcessorModule.m +16 -0
- package/lib/module/ios/WeatherFrameProcessorModule.swift +104 -0
- package/lib/module/ios/aguacerowx-react-native.podspec +36 -0
- package/lib/module/lib/commonjs/ios/AguaceroPackage.m +19 -0
- package/lib/module/lib/commonjs/ios/FragmentUniforms.swift +14 -0
- package/lib/module/lib/commonjs/ios/GridRenderLayer.swift +962 -0
- package/lib/module/lib/commonjs/ios/GridRenderLayerBridge.swift +30 -0
- package/lib/module/lib/commonjs/ios/GridRenderLayerManager.mm +146 -0
- package/lib/module/lib/commonjs/ios/GridRenderLayerView.h +23 -0
- package/lib/module/lib/commonjs/ios/GridRenderLayerView.m +199 -0
- package/lib/module/lib/commonjs/ios/InspectorDataCache.swift +66 -0
- package/lib/module/lib/commonjs/ios/InspectorModule.m +10 -0
- package/lib/module/lib/commonjs/ios/InspectorModule.swift +64 -0
- package/lib/module/lib/commonjs/ios/Shaders.metal +131 -0
- package/lib/module/lib/commonjs/ios/WeatherFrameProcessorModule.m +16 -0
- package/lib/module/lib/commonjs/ios/WeatherFrameProcessorModule.swift +104 -0
- package/lib/module/lib/commonjs/ios/aguacerowx-react-native.podspec +36 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/AguaceroCore.js +1003 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/AguaceroCore.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/coordinate_configs.js +381 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/coordinate_configs.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/default-colormaps.js +1229 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/default-colormaps.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/dictionaries.js +4023 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/dictionaries.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/events.js +38 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/events.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/fill-layer-worker.js +30 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/fill-layer-worker.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/getBundleId.js +27 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/getBundleId.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/index.js +47 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/index.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/map-styles.js +301 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/map-styles.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/unitConversions.js +126 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/dist/unitConversions.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/package.json +48 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/AguaceroCore.js +1033 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/AguaceroCore.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/coordinate_configs.js +381 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/coordinate_configs.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/default-colormaps.js +1229 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/default-colormaps.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/dictionaries.js +4023 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/dictionaries.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/events.js +38 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/events.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/fill-layer-worker.js +30 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/fill-layer-worker.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/getBundleId.js +27 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/getBundleId.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/index.js +41 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/index.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/map-styles.js +301 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/map-styles.js.map +1 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/unitConversions.js +126 -0
- package/lib/module/lib/commonjs/node_modules/@aguacerowx/javascript-sdk/src/unitConversions.js.map +1 -0
- package/lib/module/lib/commonjs/package.json +9 -17
- package/lib/module/lib/commonjs/src/GridRenderLayer.js +32 -7
- package/lib/module/lib/commonjs/src/GridRenderLayer.js.map +1 -1
- package/lib/module/lib/commonjs/src/MapManager.js +1 -4
- package/lib/module/lib/commonjs/src/MapManager.js.map +1 -1
- package/lib/module/lib/commonjs/src/WeatherLayerManager.js +236 -210
- package/lib/module/lib/commonjs/src/WeatherLayerManager.js.map +1 -1
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/AguaceroCore.js +1003 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/AguaceroCore.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/coordinate_configs.js +381 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/coordinate_configs.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/default-colormaps.js +1229 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/default-colormaps.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/dictionaries.js +4023 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/dictionaries.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/events.js +38 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/events.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/fill-layer-worker.js +30 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/fill-layer-worker.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/getBundleId.js +27 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/getBundleId.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/index.js +47 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/index.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/map-styles.js +301 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/map-styles.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/unitConversions.js +126 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/dist/unitConversions.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/package.json +48 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/AguaceroCore.js +1021 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/AguaceroCore.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/coordinate_configs.js +375 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/coordinate_configs.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/default-colormaps.js +1223 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/default-colormaps.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/dictionaries.js +4017 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/dictionaries.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/events.js +31 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/events.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/fill-layer-worker.js +29 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/fill-layer-worker.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/getBundleId.js +21 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/getBundleId.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/index.js +12 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/index.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/map-styles.js +295 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/map-styles.js.map +1 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/unitConversions.js +119 -0
- package/lib/module/node_modules/@aguacerowx/javascript-sdk/src/unitConversions.js.map +1 -0
- package/lib/module/package.json +9 -17
- package/lib/module/src/GridRenderLayer.js +32 -7
- package/lib/module/src/GridRenderLayer.js.map +1 -1
- package/lib/module/src/MapManager.js +1 -4
- package/lib/module/src/MapManager.js.map +1 -1
- package/lib/module/src/WeatherLayerManager.js +237 -211
- package/lib/module/src/WeatherLayerManager.js.map +1 -1
- package/lib/typescript/src/GridRenderLayer.d.ts.map +1 -1
- package/lib/typescript/src/MapManager.d.ts.map +1 -1
- package/lib/typescript/src/WeatherLayerManager.d.ts.map +1 -1
- package/package.json +9 -17
- package/src/AguaceroContext.js +4 -0
- package/src/GridRenderLayer.js +205 -0
- package/src/GridRenderLayerNativeComponent.ts +16 -0
- package/src/MapManager.js +156 -0
- package/src/MapRegistry.js +35 -0
- package/src/StyleApplicator.js +241 -0
- package/src/WeatherLayerManager.js +873 -0
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
#include <metal_stdlib>
|
|
2
|
+
using namespace metal;
|
|
3
|
+
|
|
4
|
+
// Struct to match the vertex buffer layout in Swift
|
|
5
|
+
struct Vertex {
|
|
6
|
+
float2 position [[attribute(0)]];
|
|
7
|
+
float2 texCoord [[attribute(1)]];
|
|
8
|
+
};
|
|
9
|
+
|
|
10
|
+
// Struct for passing data from vertex to fragment shader
|
|
11
|
+
struct RasterizerData {
|
|
12
|
+
float4 position [[position]];
|
|
13
|
+
float2 texCoord;
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
// Uniforms passed from the CPU to the fragment shader
|
|
17
|
+
struct FragmentUniforms {
|
|
18
|
+
float opacity;
|
|
19
|
+
float2 dataRange;
|
|
20
|
+
float scale;
|
|
21
|
+
float offset;
|
|
22
|
+
float missingQuantized;
|
|
23
|
+
float2 textureSize;
|
|
24
|
+
int smoothing;
|
|
25
|
+
int scaleType; // 0 for linear, 1 for sqrt
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
// --- Vertex Shader (Unchanged) ---
|
|
29
|
+
vertex RasterizerData vertex_main(const Vertex in [[stage_in]],
|
|
30
|
+
constant float4x4 &mvp [[buffer(1)]]) {
|
|
31
|
+
RasterizerData out;
|
|
32
|
+
out.position = mvp * float4(in.position, 0.0, 1.0);
|
|
33
|
+
out.texCoord = in.texCoord;
|
|
34
|
+
return out;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
float sampleDataTextureSmooth(
|
|
38
|
+
texture2d<float, access::sample> dataTexture,
|
|
39
|
+
sampler dataSampler,
|
|
40
|
+
float2 uv,
|
|
41
|
+
constant FragmentUniforms &uniforms)
|
|
42
|
+
{
|
|
43
|
+
float missing_value = uniforms.missingQuantized + 128.0;
|
|
44
|
+
|
|
45
|
+
// Calculate the fractional part for interpolation and the size of one texel.
|
|
46
|
+
float2 texel_size = 1.0 / uniforms.textureSize;
|
|
47
|
+
float2 pixel_coord = uv * uniforms.textureSize;
|
|
48
|
+
float2 pixel_floor = floor(pixel_coord - 0.5);
|
|
49
|
+
float2 f = fract(pixel_coord - 0.5);
|
|
50
|
+
|
|
51
|
+
// Calculate the precise UV coordinates for the CENTER of the four surrounding texels.
|
|
52
|
+
float2 uv00 = (pixel_floor + float2(0.5, 0.5)) * texel_size;
|
|
53
|
+
float2 uv10 = (pixel_floor + float2(1.5, 0.5)) * texel_size;
|
|
54
|
+
float2 uv01 = (pixel_floor + float2(0.5, 1.5)) * texel_size;
|
|
55
|
+
float2 uv11 = (pixel_floor + float2(1.5, 1.5)) * texel_size;
|
|
56
|
+
|
|
57
|
+
// Sample the four corner texels.
|
|
58
|
+
float s00 = dataTexture.sample(dataSampler, uv00).r * 255.0;
|
|
59
|
+
float s10 = dataTexture.sample(dataSampler, uv10).r * 255.0;
|
|
60
|
+
float s01 = dataTexture.sample(dataSampler, uv01).r * 255.0;
|
|
61
|
+
float s11 = dataTexture.sample(dataSampler, uv11).r * 255.0;
|
|
62
|
+
|
|
63
|
+
// THE CRITICAL CHECK: If any surrounding pixel is a "missing" value,
|
|
64
|
+
// treat this entire fragment as missing to prevent interpolation.
|
|
65
|
+
if (abs(s00 - missing_value) < 0.5 ||
|
|
66
|
+
abs(s10 - missing_value) < 0.5 ||
|
|
67
|
+
abs(s01 - missing_value) < 0.5 ||
|
|
68
|
+
abs(s11 - missing_value) < 0.5)
|
|
69
|
+
{
|
|
70
|
+
return missing_value;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
// All neighbors are valid data, so we can safely perform manual bilinear interpolation.
|
|
74
|
+
float s0 = mix(s00, s10, f.x); // Interpolate the top row
|
|
75
|
+
float s1 = mix(s01, s11, f.x); // Interpolate the bottom row
|
|
76
|
+
|
|
77
|
+
// --- THE FIX IS HERE ---
|
|
78
|
+
// Remove the incorrect "1.0 - f.y" inversion. The vertical mix should use f.y directly.
|
|
79
|
+
return mix(s0, s1, f.y);
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
// --- Fragment Shader (NEW & IMPROVED) ---
|
|
83
|
+
fragment float4 fragment_main(RasterizerData in [[stage_in]],
|
|
84
|
+
constant FragmentUniforms &uniforms [[buffer(0)]],
|
|
85
|
+
texture2d<float, access::sample> dataTexture [[texture(0)]],
|
|
86
|
+
texture2d<float, access::sample> colormapTexture [[texture(1)]],
|
|
87
|
+
sampler dataSampler [[sampler(0)]],
|
|
88
|
+
sampler colormapSampler [[sampler(1)]])
|
|
89
|
+
{
|
|
90
|
+
// Choose the sampling method based on the smoothing uniform.
|
|
91
|
+
float value_in_texture;
|
|
92
|
+
if (uniforms.smoothing == 1) {
|
|
93
|
+
// Use our custom function that prevents edge artifacts.
|
|
94
|
+
value_in_texture = sampleDataTextureSmooth(dataTexture, dataSampler, in.texCoord, uniforms);
|
|
95
|
+
} else {
|
|
96
|
+
// Smoothing is off. The sampler is already set to 'nearest' by the Swift code,
|
|
97
|
+
// so a standard sample call produces the correct pixelated result.
|
|
98
|
+
value_in_texture = dataTexture.sample(dataSampler, in.texCoord).r * 255.0;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
float missing_value = uniforms.missingQuantized + 128.0;
|
|
102
|
+
|
|
103
|
+
// Discard if the pixel is a predefined missing value (either originally or from our function).
|
|
104
|
+
if (abs(value_in_texture - missing_value) < 0.5) {
|
|
105
|
+
discard_fragment();
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
// Dequantize the value to its real-world representation.
|
|
109
|
+
float quantized_value = value_in_texture - 128.0;
|
|
110
|
+
float intermediate_value = quantized_value * uniforms.scale + uniforms.offset;
|
|
111
|
+
float raw_value = intermediate_value;
|
|
112
|
+
|
|
113
|
+
// Apply non-linear inverse scaling if specified.
|
|
114
|
+
if (uniforms.scaleType == 1) { // 'sqrt'
|
|
115
|
+
raw_value = intermediate_value * abs(intermediate_value);
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
// Discard if the data is below the specified visible range.
|
|
119
|
+
if (raw_value < uniforms.dataRange.x) {
|
|
120
|
+
discard_fragment();
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
// Normalize the value to a 0-1 coordinate for colormap lookup.
|
|
124
|
+
float colormap_coord = (raw_value - uniforms.dataRange.x) / (uniforms.dataRange.y - uniforms.dataRange.x);
|
|
125
|
+
colormap_coord = clamp(colormap_coord, 0.0, 1.0);
|
|
126
|
+
|
|
127
|
+
// Sample the colormap and apply final opacity.
|
|
128
|
+
float4 color = colormapTexture.sample(colormapSampler, float2(colormap_coord, 0.5));
|
|
129
|
+
|
|
130
|
+
return float4(color.rgb, color.a * uniforms.opacity);
|
|
131
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
#import <React/RCTBridgeModule.h>
|
|
2
|
+
|
|
3
|
+
@interface RCT_EXTERN_MODULE(WeatherFrameProcessorModule, NSObject)
|
|
4
|
+
|
|
5
|
+
RCT_EXTERN_METHOD(processFrame:(NSDictionary *)options
|
|
6
|
+
resolver:(RCTPromiseResolveBlock)resolve
|
|
7
|
+
rejecter:(RCTPromiseRejectBlock)reject)
|
|
8
|
+
|
|
9
|
+
RCT_EXTERN_METHOD(cancelAllFrames)
|
|
10
|
+
|
|
11
|
+
+ (BOOL)requiresMainQueueSetup
|
|
12
|
+
{
|
|
13
|
+
return NO;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
@end
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
import Foundation
|
|
2
|
+
import React
|
|
3
|
+
|
|
4
|
+
@objc(WeatherFrameProcessorModule)
|
|
5
|
+
class WeatherFrameProcessorModule: NSObject {
|
|
6
|
+
|
|
7
|
+
private var currentRunToken = 0
|
|
8
|
+
private let session = URLSession(configuration: .default)
|
|
9
|
+
|
|
10
|
+
@objc(cancelAllFrames)
|
|
11
|
+
func cancelAllFrames() {
|
|
12
|
+
// Incrementing the token effectively cancels any in-flight tasks
|
|
13
|
+
// as they will check their token against the new value upon completion.
|
|
14
|
+
currentRunToken += 1
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
@objc(processFrame:resolver:rejecter:)
|
|
18
|
+
func processFrame(options: [String: Any], resolve: @escaping RCTPromiseResolveBlock, reject: @escaping RCTPromiseRejectBlock) {
|
|
19
|
+
let taskToken = self.currentRunToken
|
|
20
|
+
|
|
21
|
+
guard let urlString = options["url"] as? String, let url = URL(string: urlString) else {
|
|
22
|
+
reject("INVALID_URL", "The provided URL is not valid.", nil)
|
|
23
|
+
return
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
let apiKey = options["apiKey"] as? String ?? ""
|
|
27
|
+
let bundleId = options["bundleId"] as? String
|
|
28
|
+
|
|
29
|
+
var request = URLRequest(url: url)
|
|
30
|
+
request.setValue(apiKey, forHTTPHeaderField: "x-api-key")
|
|
31
|
+
if let bundleId = bundleId {
|
|
32
|
+
request.setValue(bundleId, forHTTPHeaderField: "x-app-identifier")
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
let task = session.dataTask(with: request) { data, response, error in
|
|
36
|
+
if self.currentRunToken != taskToken {
|
|
37
|
+
// Task was cancelled
|
|
38
|
+
return
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
if let error = error {
|
|
42
|
+
reject("NETWORK_ERROR", "Failed to fetch frame data: \(error.localizedDescription)", error)
|
|
43
|
+
return
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
guard let httpResponse = response as? HTTPURLResponse, (200...299).contains(httpResponse.statusCode) else {
|
|
47
|
+
let statusCode = (response as? HTTPURLResponse)?.statusCode ?? -1
|
|
48
|
+
reject("HTTP_ERROR", "HTTP request failed with status code: \(statusCode)", nil)
|
|
49
|
+
return
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
guard let data = data else {
|
|
53
|
+
reject("NO_DATA", "The server returned no data.", nil)
|
|
54
|
+
return
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
do {
|
|
58
|
+
guard let jsonResponse = try JSONSerialization.jsonObject(with: data, options: []) as? [String: Any],
|
|
59
|
+
let b64CompressedData = jsonResponse["data"] as? String,
|
|
60
|
+
let encoding = jsonResponse["encoding"] as? [String: Any],
|
|
61
|
+
let scale = encoding["scale"] as? NSNumber,
|
|
62
|
+
let offset = encoding["offset"] as? NSNumber,
|
|
63
|
+
let missing = encoding["missing_quantized"] as? NSNumber else {
|
|
64
|
+
reject("INVALID_RESPONSE", "The API response format was invalid.", nil)
|
|
65
|
+
return
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
guard let compressedData = Data(base64Encoded: b64CompressedData) else {
|
|
69
|
+
reject("DECODING_ERROR", "Failed to decode base64 data string.", nil)
|
|
70
|
+
return
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
let cacheDir = FileManager.default.urls(for: .cachesDirectory, in: .userDomainMask).first!
|
|
74
|
+
let fileName = "frame_\(urlString.hashValue).zst"
|
|
75
|
+
let dataFile = cacheDir.appendingPathComponent(fileName)
|
|
76
|
+
|
|
77
|
+
try compressedData.write(to: dataFile)
|
|
78
|
+
|
|
79
|
+
var responseMap: [String: Any] = [
|
|
80
|
+
"filePath": dataFile.path,
|
|
81
|
+
"scale": scale,
|
|
82
|
+
"offset": offset,
|
|
83
|
+
"missing": missing,
|
|
84
|
+
"dataAsBase64": b64CompressedData // Pass this through for the initial load case
|
|
85
|
+
]
|
|
86
|
+
|
|
87
|
+
if let scaleType = encoding["scale_type"] as? String {
|
|
88
|
+
responseMap["scaleType"] = scaleType
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
resolve(responseMap)
|
|
92
|
+
|
|
93
|
+
} catch {
|
|
94
|
+
reject("PROCESSING_ERROR", "Failed to process the frame data: \(error.localizedDescription)", error)
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
task.resume()
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
@objc
|
|
101
|
+
static func requiresMainQueueSetup() -> Bool {
|
|
102
|
+
return false
|
|
103
|
+
}
|
|
104
|
+
}
|
|
@@ -5,25 +5,32 @@ Pod::Spec.new do |s|
|
|
|
5
5
|
s.name = "aguacerowx-react-native"
|
|
6
6
|
s.version = package["version"]
|
|
7
7
|
s.summary = package["description"]
|
|
8
|
-
s.homepage =
|
|
8
|
+
s.homepage = "https://www.npmjs.com/package/@aguacerowx/react-native"
|
|
9
9
|
s.license = package["license"]
|
|
10
10
|
s.authors = { package["author"] => "support@aguacerowx.com" }
|
|
11
11
|
s.platforms = { :ios => "13.4" }
|
|
12
|
-
s.source = { :git => "https://github.com/AguaceroWx/aguacero-sdks", :tag => "v#{s.version}" }
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
# This tells Xcode how to build your specific pod target.
|
|
18
|
-
# It explicitly defines the name of the generated header file, making it discoverable.
|
|
12
|
+
s.source = { :git => "https://github.com/AguaceroWx/aguacero-sdks.git", :tag => "v#{s.version}" }
|
|
13
|
+
|
|
14
|
+
s.swift_version = "5.0"
|
|
15
|
+
|
|
19
16
|
s.pod_target_xcconfig = {
|
|
20
17
|
'DEFINES_MODULE' => 'YES',
|
|
21
|
-
'
|
|
18
|
+
'CLANG_ALLOW_NON_MODULAR_INCLUDES_IN_FRAMEWORK_MODULES' => 'YES',
|
|
19
|
+
'SWIFT_COMPILATION_MODE' => 'wholemodule',
|
|
20
|
+
'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) ZSTD_DISABLE_ASM=1'
|
|
22
21
|
}
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
22
|
+
|
|
23
|
+
s.user_target_xcconfig = {
|
|
24
|
+
'DEFINES_MODULE' => 'YES'
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
s.resource_bundles = {
|
|
28
|
+
'AguaceroMetalShaders' => ['**/*.metal']
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
s.source_files = "**/*.{h,m,mm,swift}"
|
|
32
|
+
|
|
26
33
|
s.dependency "React-Core"
|
|
27
|
-
|
|
28
|
-
|
|
34
|
+
s.dependency "MapboxMaps", "~> 11.0"
|
|
35
|
+
s.dependency "libzstd", "~> 1.5.5"
|
|
29
36
|
end
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/lib/commonjs/android/build/tmp/compileDebugJavaWithJavac/previous-compilation-data.bin
CHANGED
|
Binary file
|
|
@@ -297,6 +297,15 @@ public class GridRenderLayer implements CustomLayerHost {
|
|
|
297
297
|
}
|
|
298
298
|
}
|
|
299
299
|
|
|
300
|
+
// Add this method to GridRenderLayer.java (around line 270)
|
|
301
|
+
public void updateDataParameters(float scale, float offset, float missing) {
|
|
302
|
+
synchronized (dataLock) {
|
|
303
|
+
this.scale = scale;
|
|
304
|
+
this.offset = offset;
|
|
305
|
+
this.missingQuantized = missing;
|
|
306
|
+
}
|
|
307
|
+
}
|
|
308
|
+
|
|
300
309
|
// This existing method is now used by both the old JS path and our new native path
|
|
301
310
|
public void updateDataTexture(byte[] bytes, int nx, int ny, float scale, float offset, float missing, String scaleType) {
|
|
302
311
|
ByteBuffer dataBuffer = ByteBuffer.allocateDirect(bytes.length);
|
|
@@ -470,139 +479,134 @@ public class GridRenderLayer implements CustomLayerHost {
|
|
|
470
479
|
Math.abs(getDouble(gridParams, "lat_first", -1)) == 90.0;
|
|
471
480
|
}
|
|
472
481
|
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
if (gridParams == null) {
|
|
480
|
-
Log.e(TAG, "❌ [Geometry] grid_params is null. Aborting mesh generation.");
|
|
481
|
-
return;
|
|
482
|
-
}
|
|
482
|
+
private void generateGeometryData(ReadableMap gridDefMap, ArrayList<Float> vertices, ArrayList<Short> indices) {
|
|
483
|
+
ReadableMap gridParams = gridDefMap.getMap("grid_params");
|
|
484
|
+
if (gridParams == null) {
|
|
485
|
+
Log.e(TAG, "❌ [Geometry] grid_params is null. Aborting mesh generation.");
|
|
486
|
+
return;
|
|
487
|
+
}
|
|
483
488
|
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
489
|
+
// --- Path 1: Specialized GFS Global Grid Logic (Working Correctly) ---
|
|
490
|
+
if (isGFSType(gridParams)) {
|
|
491
|
+
// This proven logic remains unchanged.
|
|
492
|
+
int subdivisions = 120;
|
|
493
|
+
int verticesPerRow = (subdivisions * 3) + 1;
|
|
494
|
+
final double TILE_SIZE = 512.0;
|
|
495
|
+
for (int row = 0; row <= subdivisions; row++) {
|
|
496
|
+
for (int col = 0; col <= subdivisions * 3; col++) {
|
|
497
|
+
float v_interp = (float) row / subdivisions;
|
|
498
|
+
float u_interp = (float) col / subdivisions;
|
|
499
|
+
double lon = -540.0 + u_interp * 1080.0;
|
|
500
|
+
double lat = -90.0 + v_interp * 180.0;
|
|
501
|
+
double mercX_normalized = (lon + 180.0) / 360.0;
|
|
502
|
+
double clampedLat = Math.max(-85.05112878, Math.min(85.05112878, lat));
|
|
503
|
+
double sinLatitude = Math.sin(Math.toRadians(clampedLat));
|
|
504
|
+
double mercY_normalized = 0.5 - Math.log((1 + sinLatitude) / (1 - sinLatitude)) / (4 * Math.PI);
|
|
505
|
+
double mercX = mercX_normalized * TILE_SIZE;
|
|
506
|
+
double mercY = mercY_normalized * TILE_SIZE;
|
|
507
|
+
vertices.add((float) mercX);
|
|
508
|
+
vertices.add((float) mercY);
|
|
509
|
+
float tex_u = (float) ((lon + 180.0) / 360.0);
|
|
510
|
+
float tex_v = 1.0f - v_interp;
|
|
511
|
+
vertices.add(tex_u);
|
|
512
|
+
vertices.add(tex_v);
|
|
513
|
+
}
|
|
508
514
|
}
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
515
|
+
for (short row = 0; row < subdivisions; row++) {
|
|
516
|
+
for (short col = 0; col < subdivisions * 3; col++) {
|
|
517
|
+
short tl = (short) (row * verticesPerRow + col);
|
|
518
|
+
short tr = (short) (tl + 1);
|
|
519
|
+
short bl = (short) ((row + 1) * verticesPerRow + col);
|
|
520
|
+
short br = (short) (bl + 1);
|
|
521
|
+
indices.add(tl); indices.add(bl); indices.add(tr);
|
|
522
|
+
indices.add(tr); indices.add(bl); indices.add(br);
|
|
523
|
+
}
|
|
518
524
|
}
|
|
525
|
+
return;
|
|
519
526
|
}
|
|
520
|
-
return;
|
|
521
|
-
}
|
|
522
527
|
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
// Step 1: Extract grid parameters
|
|
530
|
-
int nx = gridParams.getInt("nx");
|
|
531
|
-
int ny = gridParams.getInt("ny");
|
|
532
|
-
double lon_first = getDouble(gridParams, "lon_first", 0.0);
|
|
533
|
-
double lat_first = getDouble(gridParams, "lat_first", 90.0);
|
|
534
|
-
double dx = getDouble(gridParams, "dx_degrees", 0.0);
|
|
535
|
-
double dy = getDouble(gridParams, "dy_degrees", 0.0);
|
|
536
|
-
double lon_last = getDouble(gridParams, "lon_last", lon_first + (nx - 1) * dx);
|
|
537
|
-
double lat_last = getDouble(gridParams, "lat_last", lat_first + (ny - 1) * dy);
|
|
538
|
-
double lat_span = lat_last - lat_first;
|
|
539
|
-
boolean isSouthToNorth = lat_span > 0;
|
|
540
|
-
|
|
541
|
-
// Step 2: Normalize data longitudes to the -180 to +180 range for consistent placement.
|
|
542
|
-
double data_lon_first_180 = lon_first > 180 ? lon_first - 360 : lon_first;
|
|
543
|
-
double data_lon_last_180 = lon_last > 180 ? lon_last - 360 : lon_last;
|
|
544
|
-
double data_lon_range = data_lon_last_180 - data_lon_first_180;
|
|
545
|
-
|
|
546
|
-
// Step 3: Define mesh properties
|
|
547
|
-
int subdivisions_x = 120; // Subdivisions for a single mesh instance
|
|
548
|
-
int subdivisions_y = 60;
|
|
549
|
-
int verticesPerMesh = (subdivisions_y + 1) * (subdivisions_x + 1);
|
|
550
|
-
int verticesPerRow = subdivisions_x + 1;
|
|
551
|
-
final double TILE_SIZE = 512.0;
|
|
552
|
-
|
|
553
|
-
// Step 4: Generate three separate, non-connected meshes to prevent seam artifacts
|
|
554
|
-
for (int world_copy = -1; world_copy <= 1; world_copy++) {
|
|
555
|
-
short vertexStartIndex = (short) (vertices.size() / 4); // 4 floats per vertex (x,y,u,v)
|
|
556
|
-
double lon_offset = world_copy * 360.0;
|
|
557
|
-
|
|
558
|
-
// Generate vertices for this specific world copy
|
|
559
|
-
for (int row = 0; row <= subdivisions_y; row++) {
|
|
560
|
-
for (int col = 0; col <= subdivisions_x; col++) {
|
|
561
|
-
float v_interp = (float) row / subdivisions_y;
|
|
562
|
-
float u_interp = (float) col / subdivisions_x;
|
|
563
|
-
|
|
564
|
-
// Vertex position is interpolated across the data's native bounds, then offset for the world copy
|
|
565
|
-
double vertex_lon = data_lon_first_180 + (u_interp * data_lon_range);
|
|
566
|
-
double vertex_lat = lat_first + (v_interp * lat_span);
|
|
567
|
-
|
|
568
|
-
// Convert to map coordinates, adding the world copy offset
|
|
569
|
-
double mercX_normalized = ((vertex_lon + lon_offset) + 180.0) / 360.0;
|
|
570
|
-
double clampedLat = Math.max(-85.05112878, Math.min(85.05112878, vertex_lat));
|
|
571
|
-
double sinLatitude = Math.sin(Math.toRadians(clampedLat));
|
|
572
|
-
double mercY_normalized = 0.5 - Math.log((1 + sinLatitude) / (1 - sinLatitude)) / (4 * Math.PI);
|
|
573
|
-
double mercX = mercX_normalized * TILE_SIZE;
|
|
574
|
-
double mercY = mercY_normalized * TILE_SIZE;
|
|
528
|
+
// --- Path 2: LCC Grid Logic ---
|
|
529
|
+
if (isLCCType(gridDefMap)) {
|
|
530
|
+
generateLCCGeometry(gridDefMap, vertices, indices);
|
|
531
|
+
return;
|
|
532
|
+
}
|
|
575
533
|
|
|
576
|
-
|
|
577
|
-
|
|
534
|
+
// Step 1: Extract grid parameters
|
|
535
|
+
int nx = gridParams.getInt("nx");
|
|
536
|
+
int ny = gridParams.getInt("ny");
|
|
537
|
+
double lon_first = getDouble(gridParams, "lon_first", 0.0);
|
|
538
|
+
double lat_first = getDouble(gridParams, "lat_first", 90.0);
|
|
539
|
+
double dx = getDouble(gridParams, "dx_degrees", 0.0);
|
|
540
|
+
double dy = getDouble(gridParams, "dy_degrees", 0.0);
|
|
541
|
+
double lon_last = getDouble(gridParams, "lon_last", lon_first + (nx - 1) * dx);
|
|
542
|
+
double lat_last = getDouble(gridParams, "lat_last", lat_first + (ny - 1) * dy);
|
|
543
|
+
double lat_span = lat_last - lat_first;
|
|
544
|
+
boolean isSouthToNorth = lat_span > 0;
|
|
545
|
+
|
|
546
|
+
// Step 2: Normalize data longitudes to the -180 to +180 range for consistent placement.
|
|
547
|
+
double data_lon_first_180 = lon_first > 180 ? lon_first - 360 : lon_first;
|
|
548
|
+
double data_lon_last_180 = lon_last > 180 ? lon_last - 360 : lon_last;
|
|
549
|
+
double data_lon_range = data_lon_last_180 - data_lon_first_180;
|
|
550
|
+
|
|
551
|
+
// Step 3: Define mesh properties
|
|
552
|
+
int subdivisions_x = 120; // Subdivisions for a single mesh instance
|
|
553
|
+
int subdivisions_y = 60;
|
|
554
|
+
int verticesPerMesh = (subdivisions_y + 1) * (subdivisions_x + 1);
|
|
555
|
+
int verticesPerRow = subdivisions_x + 1;
|
|
556
|
+
final double TILE_SIZE = 512.0;
|
|
578
557
|
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
558
|
+
// Step 4: Generate three separate, non-connected meshes to prevent seam artifacts
|
|
559
|
+
for (int world_copy = -1; world_copy <= 1; world_copy++) {
|
|
560
|
+
short vertexStartIndex = (short) (vertices.size() / 4); // 4 floats per vertex (x,y,u,v)
|
|
561
|
+
double lon_offset = world_copy * 360.0;
|
|
562
|
+
|
|
563
|
+
// Generate vertices for this specific world copy
|
|
564
|
+
for (int row = 0; row <= subdivisions_y; row++) {
|
|
565
|
+
for (int col = 0; col <= subdivisions_x; col++) {
|
|
566
|
+
float v_interp = (float) row / subdivisions_y;
|
|
567
|
+
float u_interp = (float) col / subdivisions_x;
|
|
568
|
+
|
|
569
|
+
// Vertex position is interpolated across the data's native bounds, then offset for the world copy
|
|
570
|
+
double vertex_lon = data_lon_first_180 + (u_interp * data_lon_range);
|
|
571
|
+
double vertex_lat = lat_first + (v_interp * lat_span);
|
|
572
|
+
|
|
573
|
+
// Convert to map coordinates, adding the world copy offset
|
|
574
|
+
double mercX_normalized = ((vertex_lon + lon_offset) + 180.0) / 360.0;
|
|
575
|
+
double clampedLat = Math.max(-85.05112878, Math.min(85.05112878, vertex_lat));
|
|
576
|
+
double sinLatitude = Math.sin(Math.toRadians(clampedLat));
|
|
577
|
+
double mercY_normalized = 0.5 - Math.log((1 + sinLatitude) / (1 - sinLatitude)) / (4 * Math.PI);
|
|
578
|
+
double mercX = mercX_normalized * TILE_SIZE;
|
|
579
|
+
double mercY = mercY_normalized * TILE_SIZE;
|
|
580
|
+
|
|
581
|
+
vertices.add((float) mercX);
|
|
582
|
+
vertices.add((float) mercY);
|
|
583
|
+
|
|
584
|
+
// Texture coordinates are always a clean 0.0 to 1.0 for each mesh instance
|
|
585
|
+
float tex_u = u_interp;
|
|
586
|
+
float tex_v = isSouthToNorth ? (1.0f - v_interp) : v_interp;
|
|
587
|
+
|
|
588
|
+
vertices.add(tex_u);
|
|
589
|
+
vertices.add(tex_v);
|
|
590
|
+
}
|
|
585
591
|
}
|
|
586
|
-
}
|
|
587
|
-
|
|
588
|
-
// Generate indices for this specific world copy, offsetting by the starting index
|
|
589
|
-
for (short row = 0; row < subdivisions_y; row++) {
|
|
590
|
-
for (short col = 0; col < subdivisions_x; col++) {
|
|
591
|
-
short tl = (short) (vertexStartIndex + row * verticesPerRow + col);
|
|
592
|
-
short tr = (short) (tl + 1);
|
|
593
|
-
short bl = (short) (vertexStartIndex + (row + 1) * verticesPerRow + col);
|
|
594
|
-
short br = (short) (bl + 1);
|
|
595
592
|
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
593
|
+
// Generate indices for this specific world copy, offsetting by the starting index
|
|
594
|
+
for (short row = 0; row < subdivisions_y; row++) {
|
|
595
|
+
for (short col = 0; col < subdivisions_x; col++) {
|
|
596
|
+
short tl = (short) (vertexStartIndex + row * verticesPerRow + col);
|
|
597
|
+
short tr = (short) (tl + 1);
|
|
598
|
+
short bl = (short) (vertexStartIndex + (row + 1) * verticesPerRow + col);
|
|
599
|
+
short br = (short) (bl + 1);
|
|
600
|
+
|
|
601
|
+
if (isSouthToNorth) {
|
|
602
|
+
indices.add(tl); indices.add(bl); indices.add(tr);
|
|
603
|
+
indices.add(tr); indices.add(bl); indices.add(br);
|
|
604
|
+
} else { // North-to-South (MRMS)
|
|
605
|
+
indices.add(tl); indices.add(tr); indices.add(bl);
|
|
606
|
+
indices.add(bl); indices.add(tr); indices.add(br);
|
|
607
|
+
}
|
|
602
608
|
}
|
|
603
609
|
}
|
|
604
610
|
}
|
|
605
611
|
}
|
|
606
|
-
}
|
|
607
|
-
|
|
608
612
|
}
|
package/lib/commonjs/android/src/main/java/com/aguacerowx/reactnative/GridRenderLayerView.java
CHANGED
|
@@ -241,7 +241,6 @@ public class GridRenderLayerView extends FrameLayout {
|
|
|
241
241
|
colormapBuffer.put(bytes);
|
|
242
242
|
colormapBuffer.position(0);
|
|
243
243
|
gridLayerImplementation.updateColormapTexture(colormapBuffer);
|
|
244
|
-
triggerRepaint();
|
|
245
244
|
}
|
|
246
245
|
|
|
247
246
|
public void updateGeometry(ReadableMap corners, ReadableMap gridDef) {
|
|
@@ -289,6 +288,9 @@ public class GridRenderLayerView extends FrameLayout {
|
|
|
289
288
|
lastDataScale = scale;
|
|
290
289
|
lastDataOffset = offset;
|
|
291
290
|
lastDataMissing = missing;
|
|
291
|
+
|
|
292
|
+
// CRITICAL FIX: Also update the GridRenderLayer implementation
|
|
293
|
+
gridLayerImplementation.updateDataParameters(scale, offset, missing);
|
|
292
294
|
}
|
|
293
295
|
|
|
294
296
|
public void clearData() {
|