@nativescript/canvas 2.0.0-alpha.5 → 2.0.0-alpha.50
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/Canvas/common.d.ts +213 -25
- package/Canvas/common.js +702 -452
- package/Canvas/common.js.map +1 -1
- package/Canvas/index.android.d.ts +12 -1
- package/Canvas/index.android.js +162 -49
- package/Canvas/index.android.js.map +1 -1
- package/Canvas/index.d.ts +13 -0
- package/Canvas/index.ios.d.ts +9 -4
- package/Canvas/index.ios.js +166 -103
- package/Canvas/index.ios.js.map +1 -1
- package/Canvas2D/CanvasGradient/index.d.ts +1 -3
- package/Canvas2D/CanvasGradient/index.js +1 -10
- package/Canvas2D/CanvasGradient/index.js.map +1 -1
- package/Canvas2D/CanvasPattern/index.d.ts +1 -3
- package/Canvas2D/CanvasPattern/index.js +1 -10
- package/Canvas2D/CanvasPattern/index.js.map +1 -1
- package/Canvas2D/CanvasRenderingContext2D/index.d.ts +7 -3
- package/Canvas2D/CanvasRenderingContext2D/index.js +132 -233
- package/Canvas2D/CanvasRenderingContext2D/index.js.map +1 -1
- package/Canvas2D/DOMMatrix/index.js +3 -3
- package/Canvas2D/DOMMatrix/index.js.map +1 -1
- package/Canvas2D/ImageData/index.js +6 -6
- package/Canvas2D/ImageData/index.js.map +1 -1
- package/Canvas2D/Path2D/index.d.ts +0 -2
- package/Canvas2D/Path2D/index.js +32 -42
- package/Canvas2D/Path2D/index.js.map +1 -1
- package/Dom/Paint.js +2 -3
- package/Dom/Paint.js.map +1 -1
- package/Dom/shapes/Circle.js +1 -2
- package/Dom/shapes/Circle.js.map +1 -1
- package/Dom/shapes/Points.js +1 -2
- package/Dom/shapes/Points.js.map +1 -1
- package/ImageAsset/index.d.ts +2 -2
- package/ImageAsset/index.js +33 -37
- package/ImageAsset/index.js.map +1 -1
- package/ImageBitmap/index.d.ts +0 -2
- package/ImageBitmap/index.js +47 -33
- package/ImageBitmap/index.js.map +1 -1
- package/LICENSE +201 -0
- package/SVG/SVG.js +1 -1
- package/SVG/SVG.js.map +1 -1
- package/TextDecoder/index.d.ts +0 -2
- package/TextDecoder/index.js +3 -12
- package/TextDecoder/index.js.map +1 -1
- package/TextEncoder/index.d.ts +0 -2
- package/TextEncoder/index.js +4 -13
- package/TextEncoder/index.js.map +1 -1
- package/WebGL/WebGLExtensions/index.d.ts +4 -12
- package/WebGL/WebGLExtensions/index.js +27 -77
- package/WebGL/WebGLExtensions/index.js.map +1 -1
- package/WebGL/WebGLProgram.d.ts +0 -1
- package/WebGL/WebGLProgram.js +0 -3
- package/WebGL/WebGLProgram.js.map +1 -1
- package/WebGL/WebGLRenderingContext/common.d.ts +1 -3
- package/WebGL/WebGLRenderingContext/common.js +3 -13
- package/WebGL/WebGLRenderingContext/common.js.map +1 -1
- package/WebGL/WebGLRenderingContext/index.d.ts +19 -17
- package/WebGL/WebGLRenderingContext/index.js +354 -728
- package/WebGL/WebGLRenderingContext/index.js.map +1 -1
- package/WebGL2/WebGL2RenderingContext/common.d.ts +2 -2
- package/WebGL2/WebGL2RenderingContext/common.js +2 -2
- package/WebGL2/WebGL2RenderingContext/common.js.map +1 -1
- package/WebGL2/WebGL2RenderingContext/index.d.ts +1 -1
- package/WebGL2/WebGL2RenderingContext/index.js +116 -285
- package/WebGL2/WebGL2RenderingContext/index.js.map +1 -1
- package/angular/esm2020/index.mjs +4 -4
- package/angular/fesm2015/nativescript-canvas-angular.mjs +4 -4
- package/angular/fesm2020/nativescript-canvas-angular.mjs +4 -4
- package/angular/package.json +2 -2
- package/index.js.map +1 -1
- package/package.json +3 -2
- package/platforms/android/canvas-release.aar +0 -0
- package/platforms/android/include.gradle +15 -0
- package/platforms/ios/CanvasNative.xcframework/Info.plist +5 -5
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/CanvasNative +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Headers/CanvasNative-Swift.h +135 -68
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Headers/CanvasNative.h +10 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Headers/canvas_ios.h +144 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Headers/canvas_native.h +2774 -70
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Info.plist +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Modules/CanvasNative.swiftmodule/Project/arm64-apple-ios.swiftsourceinfo +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios.abi.json +5851 -2555
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios.private.swiftinterface +44 -24
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios.swiftdoc +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios.swiftinterface +44 -24
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/dSYMs/CanvasNative.framework.dSYM/Contents/Resources/DWARF/CanvasNative +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/CanvasNative +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Headers/CanvasNative-Swift.h +270 -136
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Headers/CanvasNative.h +10 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Headers/canvas_ios.h +144 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Headers/canvas_native.h +2774 -70
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Info.plist +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/Project/arm64-apple-ios-simulator.swiftsourceinfo +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/Project/x86_64-apple-ios-simulator.swiftsourceinfo +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios-simulator.abi.json +5851 -2555
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios-simulator.private.swiftinterface +44 -24
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios-simulator.swiftdoc +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios-simulator.swiftinterface +44 -24
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/x86_64-apple-ios-simulator.abi.json +5851 -2555
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/x86_64-apple-ios-simulator.private.swiftinterface +44 -24
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/x86_64-apple-ios-simulator.swiftdoc +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/x86_64-apple-ios-simulator.swiftinterface +44 -24
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/_CodeSignature/CodeResources +42 -31
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/dSYMs/CanvasNative.framework.dSYM/Contents/Resources/DWARF/CanvasNative +0 -0
- package/platforms/ios/Podfile +5 -2
- package/platforms/ios/build.xcconfig +3 -3
- package/platforms/ios/src/CanvasModule.h +0 -2
- package/platforms/ios/src/CanvasModule.mm +4 -4
- package/platforms/ios/src/NSOperationQueueWrapper.h +11 -0
- package/platforms/ios/src/NSOperationQueueWrapper.mm +74 -0
- package/platforms/ios/src/cpp/Caches.cpp +35 -0
- package/platforms/ios/src/cpp/Caches.h +190 -0
- package/platforms/ios/src/cpp/CanvasJSIModule.cpp +1593 -0
- package/platforms/ios/src/cpp/CanvasJSIModule.h +16 -34
- package/platforms/ios/src/cpp/Common.h +30 -0
- package/platforms/ios/src/cpp/ConcurrentMap.h +54 -0
- package/platforms/ios/src/cpp/Helpers.h +336 -38
- package/platforms/ios/src/cpp/ImageAssetImpl.cpp +802 -0
- package/platforms/ios/src/cpp/ImageAssetImpl.h +46 -12
- package/platforms/ios/src/cpp/ImageBitmapImpl.cpp +189 -0
- package/platforms/ios/src/cpp/ImageBitmapImpl.h +42 -16
- package/platforms/ios/src/cpp/JSICallback.h +83 -5
- package/platforms/ios/src/cpp/JSIReadFileCallback.h +86 -6
- package/platforms/ios/src/cpp/JSIRuntime.cpp +21 -0
- package/platforms/ios/src/cpp/JSIRuntime.h +7 -0
- package/platforms/ios/src/cpp/ObjectWrapperImpl.h +31 -0
- package/platforms/ios/src/cpp/OneByteStringResource.cpp +55 -0
- package/platforms/ios/src/cpp/OneByteStringResource.h +36 -0
- package/platforms/ios/src/cpp/PerIsolateData.cpp +49 -0
- package/platforms/ios/src/cpp/PerIsolateData.h +54 -0
- package/platforms/ios/src/cpp/RafImpl.cpp +8 -0
- package/platforms/ios/src/cpp/RafImpl.h +11 -8
- package/platforms/ios/src/cpp/TextDecoderImpl.cpp +193 -0
- package/platforms/ios/src/cpp/TextDecoderImpl.h +23 -13
- package/platforms/ios/src/cpp/TextEncoderImpl.cpp +139 -0
- package/platforms/ios/src/cpp/TextEncoderImpl.h +21 -12
- package/platforms/ios/src/cpp/URLImpl.cpp +464 -0
- package/platforms/ios/src/cpp/URLImpl.h +121 -0
- package/platforms/ios/src/cpp/canvas2d/CanvasGradient.cpp +71 -0
- package/platforms/ios/src/cpp/canvas2d/CanvasGradient.h +29 -13
- package/platforms/ios/src/cpp/canvas2d/CanvasPattern.cpp +89 -0
- package/platforms/ios/src/cpp/canvas2d/CanvasPattern.h +49 -12
- package/platforms/ios/src/cpp/canvas2d/CanvasRenderingContext2DImpl.cpp +2841 -0
- package/platforms/ios/src/cpp/canvas2d/CanvasRenderingContext2DImpl.h +1331 -21
- package/platforms/ios/src/cpp/canvas2d/ImageDataImpl.cpp +207 -0
- package/platforms/ios/src/cpp/canvas2d/ImageDataImpl.h +27 -13
- package/platforms/ios/src/cpp/canvas2d/MatrixImpl.cpp +807 -0
- package/platforms/ios/src/cpp/canvas2d/MatrixImpl.h +173 -13
- package/platforms/ios/src/cpp/canvas2d/Path2D.cpp +499 -0
- package/platforms/ios/src/cpp/canvas2d/Path2D.h +422 -12
- package/platforms/ios/src/cpp/canvas2d/TextMetricsImpl.cpp +253 -0
- package/platforms/ios/src/cpp/canvas2d/TextMetricsImpl.h +51 -12
- package/platforms/ios/src/cpp/gl.h +57 -7
- package/platforms/ios/src/cpp/gl3stub.c +425 -0
- package/platforms/ios/src/cpp/gl3stub.h +665 -0
- package/platforms/ios/src/cpp/gles3jni.h +37 -0
- package/platforms/ios/src/cpp/include/robin_hood.h +2544 -0
- package/platforms/ios/src/cpp/webgl/WebGLActiveInfoImpl.cpp +91 -0
- package/platforms/ios/src/cpp/webgl/WebGLActiveInfoImpl.h +33 -13
- package/platforms/ios/src/cpp/webgl/WebGLBuffer.h +42 -7
- package/platforms/ios/src/cpp/webgl/WebGLFramebuffer.h +47 -11
- package/platforms/ios/src/cpp/webgl/WebGLProgram.h +41 -6
- package/platforms/ios/src/cpp/webgl/WebGLRenderbuffer.h +41 -7
- package/platforms/ios/src/cpp/webgl/WebGLRenderingContext.cpp +6845 -0
- package/platforms/ios/src/cpp/webgl/WebGLRenderingContext.h +3217 -388
- package/platforms/ios/src/cpp/webgl/{WebGLRenderingContextBase.mm → WebGLRenderingContextBase.cpp} +18 -17
- package/platforms/ios/src/cpp/webgl/WebGLRenderingContextBase.h +16 -36
- package/platforms/ios/src/cpp/webgl/WebGLShader.h +41 -7
- package/platforms/ios/src/cpp/webgl/WebGLShaderPrecisionFormatImpl.cpp +50 -0
- package/platforms/ios/src/cpp/webgl/WebGLShaderPrecisionFormatImpl.h +67 -12
- package/platforms/ios/src/cpp/webgl/WebGLTexture.h +41 -7
- package/platforms/ios/src/cpp/webgl/WebGLUniformLocation.h +45 -9
- package/platforms/ios/src/cpp/webgl/extensions/ANGLE_instanced_arraysImpl.cpp +126 -0
- package/platforms/ios/src/cpp/webgl/extensions/ANGLE_instanced_arraysImpl.h +26 -12
- package/platforms/ios/src/cpp/webgl/extensions/EXT_blend_minmaxImpl.cpp +35 -0
- package/platforms/ios/src/cpp/webgl/extensions/EXT_blend_minmaxImpl.h +26 -6
- package/platforms/ios/src/cpp/webgl/extensions/EXT_color_buffer_half_floatImpl.cpp +41 -0
- package/platforms/ios/src/cpp/webgl/extensions/EXT_color_buffer_half_floatImpl.h +26 -6
- package/platforms/ios/src/cpp/webgl/extensions/EXT_disjoint_timer_queryImpl.cpp +306 -0
- package/platforms/ios/src/cpp/webgl/extensions/EXT_disjoint_timer_queryImpl.h +47 -13
- package/platforms/ios/src/cpp/webgl/extensions/EXT_sRGBImpl.h +49 -6
- package/platforms/ios/src/cpp/webgl/extensions/EXT_shader_texture_lodImpl.h +37 -15
- package/platforms/ios/src/cpp/webgl/extensions/EXT_texture_filter_anisotropicImpl.h +47 -6
- package/platforms/ios/src/cpp/webgl/extensions/OES_element_index_uintImpl.h +49 -6
- package/platforms/ios/src/cpp/webgl/extensions/OES_fbo_render_mipmap.h +41 -16
- package/platforms/ios/src/cpp/webgl/extensions/OES_standard_derivativesImpl.h +44 -6
- package/platforms/ios/src/cpp/webgl/extensions/OES_texture_floatImpl.h +39 -16
- package/platforms/ios/src/cpp/webgl/extensions/OES_texture_float_linearImpl.h +37 -16
- package/platforms/ios/src/cpp/webgl/extensions/OES_texture_half_floatImpl.h +42 -6
- package/platforms/ios/src/cpp/webgl/extensions/OES_texture_half_float_linearImpl.h +40 -16
- package/platforms/ios/src/cpp/webgl/extensions/OES_vertex_array_objectImpl.cpp +102 -0
- package/platforms/ios/src/cpp/webgl/extensions/OES_vertex_array_objectImpl.h +69 -14
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_color_buffer_floatImpl.h +51 -8
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_compressed_texture_atcImpl.h +49 -6
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_compressed_texture_etc1Impl.h +49 -8
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_compressed_texture_etcImpl.h +76 -6
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_compressed_texture_pvrtcImpl.h +57 -6
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_compressed_texture_s3tcImpl.h +53 -6
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_compressed_texture_s3tc_srgbImpl.h +59 -6
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_depth_textureImpl.h +46 -6
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_draw_buffersImpl.cpp +35 -0
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_draw_buffersImpl.h +131 -14
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_lose_contextImpl.cpp +32 -0
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_lose_contextImpl.h +61 -13
- package/platforms/ios/src/cpp/webgl2/WebGL2RenderingContext.cpp +4533 -0
- package/platforms/ios/src/cpp/webgl2/WebGL2RenderingContext.h +1427 -342
- package/platforms/ios/src/cpp/webgl2/WebGLQuery.h +41 -4
- package/platforms/ios/src/cpp/webgl2/WebGLSampler.h +42 -3
- package/platforms/ios/src/cpp/webgl2/WebGLSyncImpl.h +45 -11
- package/platforms/ios/src/cpp/webgl2/WebGLTransformFeedback.h +43 -4
- package/platforms/ios/src/cpp/webgl2/WebGLVertexArrayObject.h +44 -4
- package/platforms/ios/src/module.modulemap +1 -0
- package/{pods → src-native/ios}/NativeScript.podspec +12 -25
- package/typings/objc!CanvasNative.d.ts +2038 -0
- package/typings/objc!CanvasNative.js +1 -0
- package/typings/objc!CanvasNative.js.map +1 -0
- package/utils.d.ts +3 -1
- package/utils.js +7 -20
- package/utils.js.map +1 -1
- package/angular/nativescript-canvas-angular.d.ts +0 -5
- package/platforms/ios/src/cpp/CanvasJSIModule.mm +0 -1105
- package/platforms/ios/src/cpp/ImageAssetImpl.mm +0 -417
- package/platforms/ios/src/cpp/ImageBitmapImpl.mm +0 -126
- package/platforms/ios/src/cpp/RafImpl.mm +0 -10
- package/platforms/ios/src/cpp/TextDecoderImpl.mm +0 -97
- package/platforms/ios/src/cpp/TextEncoderImpl.mm +0 -60
- package/platforms/ios/src/cpp/VecMutableBuffer.h +0 -46
- package/platforms/ios/src/cpp/canvas-cxx/src/lib.rs.cc +0 -6132
- package/platforms/ios/src/cpp/canvas-cxx/src/lib.rs.h +0 -2859
- package/platforms/ios/src/cpp/canvas2d/CanvasGradient.mm +0 -42
- package/platforms/ios/src/cpp/canvas2d/CanvasPattern.mm +0 -49
- package/platforms/ios/src/cpp/canvas2d/CanvasRenderingContext2DImpl.mm +0 -1975
- package/platforms/ios/src/cpp/canvas2d/ImageDataImpl.mm +0 -68
- package/platforms/ios/src/cpp/canvas2d/MatrixImpl.mm +0 -149
- package/platforms/ios/src/cpp/canvas2d/Path2D.mm +0 -335
- package/platforms/ios/src/cpp/canvas2d/TextMetricsImpl.mm +0 -68
- package/platforms/ios/src/cpp/rust/cxx.cc +0 -793
- package/platforms/ios/src/cpp/rust/cxx.h +0 -1111
- package/platforms/ios/src/cpp/webgl/WebGLActiveInfoImpl.mm +0 -39
- package/platforms/ios/src/cpp/webgl/WebGLRenderingContext.mm +0 -5958
- package/platforms/ios/src/cpp/webgl/WebGLShaderPrecisionFormatImpl.mm +0 -40
- package/platforms/ios/src/cpp/webgl/extensions/ANGLE_instanced_arraysImpl.mm +0 -108
- package/platforms/ios/src/cpp/webgl/extensions/EXT_blend_minmaxImpl.mm +0 -28
- package/platforms/ios/src/cpp/webgl/extensions/EXT_color_buffer_half_floatImpl.mm +0 -42
- package/platforms/ios/src/cpp/webgl/extensions/EXT_disjoint_timer_queryImpl.mm +0 -295
- package/platforms/ios/src/cpp/webgl/extensions/EXT_sRGBImpl.mm +0 -40
- package/platforms/ios/src/cpp/webgl/extensions/EXT_texture_filter_anisotropicImpl.mm +0 -37
- package/platforms/ios/src/cpp/webgl/extensions/OES_element_index_uintImpl.mm +0 -28
- package/platforms/ios/src/cpp/webgl/extensions/OES_standard_derivativesImpl.mm +0 -31
- package/platforms/ios/src/cpp/webgl/extensions/OES_texture_half_floatImpl.mm +0 -28
- package/platforms/ios/src/cpp/webgl/extensions/OES_vertex_array_objectImpl.mm +0 -127
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_color_buffer_floatImpl.mm +0 -45
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_compressed_texture_atcImpl.mm +0 -45
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_compressed_texture_etc1Impl.mm +0 -31
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_compressed_texture_etcImpl.mm +0 -70
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_compressed_texture_pvrtcImpl.mm +0 -47
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_compressed_texture_s3tcImpl.mm +0 -46
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_compressed_texture_s3tc_srgbImpl.mm +0 -49
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_depth_textureImpl.mm +0 -30
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_draw_buffersImpl.mm +0 -177
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_lose_contextImpl.mm +0 -64
- package/platforms/ios/src/cpp/webgl2/WebGL2RenderingContext.mm +0 -4556
- package/pods/Headers/jsi/decorator.h +0 -770
- package/pods/Headers/jsi/instrumentation.h +0 -117
- package/pods/Headers/jsi/jsi-inl.h +0 -338
- package/pods/Headers/jsi/jsi.h +0 -1571
- package/pods/Headers/jsi/jsilib.h +0 -59
- package/pods/Headers/jsi/threadsafe.h +0 -79
- package/pods/Headers/v8runtime/HostProxy.h +0 -71
- package/pods/Headers/v8runtime/JSIV8ValueConverter.h +0 -74
- package/pods/Headers/v8runtime/V8PointerValue.h +0 -44
- package/pods/Headers/v8runtime/V8Runtime.h +0 -240
- package/pods/Headers/v8runtime/V8RuntimeConfig.h +0 -26
- package/pods/Headers/v8runtime/V8RuntimeFactory.h +0 -21
- /package/platforms/ios/src/cpp/{OnRafCallback.mm → OnRafCallback.cpp} +0 -0
- /package/{pods → src-native/ios}/Headers/include/APIDesign.md +0 -0
- /package/{pods → src-native/ios}/Headers/include/DEPS +0 -0
- /package/{pods → src-native/ios}/Headers/include/DIR_METADATA +0 -0
- /package/{pods → src-native/ios}/Headers/include/OWNERS +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/DEPS +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/OWNERS +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/README.md +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/allocation.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/common.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/cross-thread-persistent.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/custom-space.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/default-platform.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/ephemeron-pair.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/explicit-management.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/garbage-collected.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/heap-consistency.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/heap-state.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/heap-statistics.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/heap.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/internal/api-constants.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/internal/atomic-entry-flag.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/internal/caged-heap-local-data.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/internal/compiler-specific.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/internal/finalizer-trait.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/internal/gc-info.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/internal/logging.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/internal/name-trait.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/internal/persistent-node.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/internal/pointer-policies.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/internal/write-barrier.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/liveness-broker.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/macros.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/member.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/name-provider.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/object-size-trait.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/persistent.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/platform.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/prefinalizer.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/process-heap-statistics.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/sentinel-pointer.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/source-location.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/testing.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/trace-trait.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/type-traits.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/cppgc/visitor.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/js_protocol-1.2.json +0 -0
- /package/{pods → src-native/ios}/Headers/include/js_protocol-1.3.json +0 -0
- /package/{pods → src-native/ios}/Headers/include/js_protocol.pdl +0 -0
- /package/{pods → src-native/ios}/Headers/include/libffi/arm64/ffi.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/libffi/arm64/ffitarget.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/libffi/x86_64/ffi.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/libffi/x86_64/ffitarget.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/libffi.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/libplatform/DEPS +0 -0
- /package/{pods → src-native/ios}/Headers/include/libplatform/libplatform-export.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/libplatform/libplatform.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/libplatform/v8-tracing.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-array-buffer.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-callbacks.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-container.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-context.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-cppgc.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-data.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-date.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-debug.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-embedder-heap.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-embedder-state-scope.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-exception.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-extension.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-external.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-fast-api-calls.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-forward.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-function-callback.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-function.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-initialization.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-inspector-protocol.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-inspector.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-internal.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-isolate.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-json.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-local-handle.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-locker.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-maybe.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-memory-span.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-message.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-metrics.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-microtask-queue.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-microtask.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-object.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-persistent-handle.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-platform.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-primitive-object.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-primitive.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-profiler.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-promise.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-proxy.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-regexp.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-script.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-snapshot.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-statistics.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-template.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-traced-handle.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-typed-array.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-unwinder-state.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-unwinder.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-util.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-value-serializer-version.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-value-serializer.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-value.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-version-string.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-version.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-wasm-trap-handler-posix.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-wasm-trap-handler-win.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-wasm.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8-weak-callback-info.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8.h +0 -0
- /package/{pods → src-native/ios}/Headers/include/v8config.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/InspectorServer.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/JsV8InspectorClient.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/base/trace_event/common/trace_event_common.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/base64.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/address-region.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/atomic-utils.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/atomicops.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/atomicops_internals_atomicword_compat.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/base-export.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/bits.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/build_config.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/compiler-specific.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/export-template.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/flags.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/immediate-crash.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/lazy-instance.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/logging.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/macros.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/memory.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/once.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/optional.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/platform/mutex.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/platform/platform.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/platform/semaphore.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/platform/v8-time.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/platform/wrappers.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/safe_conversions.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/safe_conversions_impl.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/template-utils.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/base/v8-fallthrough.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/common/checks.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/common/globals.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/debug/debug-interface.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/debug/interface-types.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/init/v8.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/custom-preview.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/injected-script.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/inspected-context.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/protocol/CSS.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/protocol/Console.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/protocol/DOM.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/protocol/Debugger.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/protocol/Forward.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/protocol/HeapProfiler.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/protocol/Log.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/protocol/Network.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/protocol/Overlay.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/protocol/Page.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/protocol/Profiler.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/protocol/Protocol.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/protocol/Runtime.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/protocol/Schema.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/protocol/Security.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/remote-object-id.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/search-util.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/string-16.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/string-util.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-console-agent-impl.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-console-message.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-console.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-css-agent-impl.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-debugger-agent-impl.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-debugger-id.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-debugger-script.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-debugger.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-dom-agent-impl.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-heap-profiler-agent-impl.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-inspector-impl.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-inspector-session-impl.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-log-agent-impl.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-network-agent-impl.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-ns-debugger-agent-impl.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-overlay-agent-impl.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-page-agent-impl.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-profiler-agent-impl.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-regex.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-runtime-agent-impl.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-schema-agent-impl.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-stack-trace-impl.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-string-conversions.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/v8-value-utils.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/inspector/value-mirror.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/libplatform/default-platform.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/logging/tracing-flags.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/numbers/conversions.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/tracing/trace-event.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/utils/allocation.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/src/utils/vector.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/third_party/inspector_protocol/crdtp/cbor.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/third_party/inspector_protocol/crdtp/dispatch.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/third_party/inspector_protocol/crdtp/error_support.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/third_party/inspector_protocol/crdtp/export.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/third_party/inspector_protocol/crdtp/find_by_first.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/third_party/inspector_protocol/crdtp/frontend_channel.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/third_party/inspector_protocol/crdtp/glue.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/third_party/inspector_protocol/crdtp/json.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/third_party/inspector_protocol/crdtp/json_platform.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/third_party/inspector_protocol/crdtp/maybe.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/third_party/inspector_protocol/crdtp/parser_handler.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/third_party/inspector_protocol/crdtp/protocol_core.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/third_party/inspector_protocol/crdtp/serializable.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/third_party/inspector_protocol/crdtp/serializer_traits.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/third_party/inspector_protocol/crdtp/span.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/third_party/inspector_protocol/crdtp/status.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/utils.h +0 -0
- /package/{pods → src-native/ios}/Headers/inspector/v8-inspector-platform.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/ArgConverter.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/ArrayAdapter.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/Caches.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/ClassBuilder.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/Common.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/ConcurrentMap.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/ConcurrentQueue.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/Console.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/Constants.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/DataWrapper.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/DictionaryAdapter.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/ExtVector.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/FFICall.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/FastEnumerationAdapter.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/FunctionReference.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/Helpers.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/InlineFunctions.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/Interop.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/KnownUnknownClassPair.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/Metadata.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/MetadataBuilder.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/MetadataInlines.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/ModuleInternal.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/NSDataAdapter.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/NativeScriptException.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/ObjectManager.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/OneByteStringResource.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/Pointer.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/PromiseProxy.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/Reference.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/Runtime.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/RuntimeConfig.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/SetTimeout.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/SimpleAllocator.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/StringHasher.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/SymbolIterator.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/SymbolLoader.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/TNSDerivedClass.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/TSHelpers.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/Tasks.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/UnmanagedType.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/WeakRef.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/Worker.h +0 -0
- /package/{pods → src-native/ios}/Headers/runtime/robin_hood.h +0 -0
|
@@ -6,10 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
#include <memory>
|
|
8
8
|
#include <array>
|
|
9
|
-
#include "NativeScript/JSIRuntime.h"
|
|
10
9
|
#include "canvas2d/CanvasRenderingContext2DImpl.h"
|
|
11
|
-
|
|
12
|
-
#import "canvas-cxx/src/lib.rs.h"
|
|
13
10
|
#include "Helpers.h"
|
|
14
11
|
|
|
15
12
|
#include "ImageAssetImpl.h"
|
|
@@ -22,39 +19,24 @@
|
|
|
22
19
|
#include "webgl/WebGLRenderingContext.h"
|
|
23
20
|
#include "webgl2/WebGL2RenderingContext.h"
|
|
24
21
|
|
|
25
|
-
|
|
26
|
-
using namespace org::nativescript::canvas;
|
|
27
|
-
|
|
28
|
-
template<typename NativeFunc>
|
|
29
|
-
static void
|
|
30
|
-
createGlobalFunc(jsi::Runtime &jsiRuntime, const char *prop, int paramCount, NativeFunc &&func) {
|
|
31
|
-
auto f = jsi::Function::createFromHostFunction(jsiRuntime,
|
|
32
|
-
jsi::PropNameID::forAscii(jsiRuntime, prop),
|
|
33
|
-
paramCount,
|
|
34
|
-
std::forward<NativeFunc>(func));
|
|
35
|
-
jsiRuntime.global().setProperty(jsiRuntime, prop, std::move(f));
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
#define CREATE_GLOBAL_FUNC(prop, paramCount, func) \
|
|
39
|
-
createFunc(jsiRuntime, prop, paramCount, func)
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
template<typename NativeFunc>
|
|
43
|
-
static void
|
|
44
|
-
createFunc(jsi::Runtime &jsiRuntime, jsi::Object &object, const char *prop, int paramCount,
|
|
45
|
-
NativeFunc &&func) {
|
|
46
|
-
auto f = jsi::Function::createFromHostFunction(jsiRuntime,
|
|
47
|
-
jsi::PropNameID::forAscii(jsiRuntime, prop),
|
|
48
|
-
paramCount,
|
|
49
|
-
std::forward<NativeFunc>(func));
|
|
50
|
-
object.setProperty(jsiRuntime, prop, std::move(f));
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
#define CREATE_FUNC(prop, object, paramCount, func) \
|
|
54
|
-
createFunc(jsiRuntime, object, prop, paramCount, func)
|
|
22
|
+
#include "URLImpl.h"
|
|
55
23
|
|
|
56
24
|
class CanvasJSIModule {
|
|
57
25
|
public:
|
|
58
|
-
static void install(
|
|
26
|
+
static void install(v8::Isolate *isolate);
|
|
27
|
+
|
|
28
|
+
static void CreateImageBitmap(const v8::FunctionCallbackInfo<v8::Value> &args);
|
|
29
|
+
|
|
30
|
+
static void Create2DContext(const v8::FunctionCallbackInfo<v8::Value> &args);
|
|
31
|
+
|
|
32
|
+
static void Create2DContextWithPointer(const v8::FunctionCallbackInfo<v8::Value> &args);
|
|
33
|
+
|
|
34
|
+
static void ReadFile(const v8::FunctionCallbackInfo<v8::Value> &args);
|
|
35
|
+
|
|
36
|
+
static void CreateWebGLContext(const v8::FunctionCallbackInfo<v8::Value> &args);
|
|
37
|
+
|
|
38
|
+
static void CreateWebGL2Context(const v8::FunctionCallbackInfo<v8::Value> &args);
|
|
39
|
+
|
|
40
|
+
static void AddFontFamily(const v8::FunctionCallbackInfo<v8::Value> &args);
|
|
59
41
|
};
|
|
60
42
|
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Created by Osei Fortune on 10/06/2022.
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
#pragma once
|
|
6
|
+
#include <stdint.h>
|
|
7
|
+
#include <string.h>
|
|
8
|
+
|
|
9
|
+
#ifdef __APPLE__
|
|
10
|
+
#include <NativeScript/include/v8.h>
|
|
11
|
+
|
|
12
|
+
#ifdef __cplusplus
|
|
13
|
+
extern "C" {
|
|
14
|
+
#endif
|
|
15
|
+
|
|
16
|
+
#include <CanvasNative/canvas_ios.h>
|
|
17
|
+
#include <CanvasNative/canvas_native.h>
|
|
18
|
+
|
|
19
|
+
#ifdef __cplusplus
|
|
20
|
+
}
|
|
21
|
+
#endif
|
|
22
|
+
#endif
|
|
23
|
+
|
|
24
|
+
#ifdef __ANDROID__
|
|
25
|
+
#include "include/v8.h"
|
|
26
|
+
#include "include/canvas_android.h"
|
|
27
|
+
#include <android/log.h>
|
|
28
|
+
#include <thread>
|
|
29
|
+
#endif
|
|
30
|
+
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Created by Osei Fortune on 10/06/2022.
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
#pragma once
|
|
6
|
+
|
|
7
|
+
#include <shared_mutex>
|
|
8
|
+
#include "include/robin_hood.h"
|
|
9
|
+
template<class TKey, class TValue>
|
|
10
|
+
class ConcurrentMap {
|
|
11
|
+
public:
|
|
12
|
+
void Insert(TKey &key, TValue value) {
|
|
13
|
+
std::lock_guard <std::mutex> writerLock(this->containerMutex_);
|
|
14
|
+
this->container_[key] = value;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
TValue Get(TKey &key) {
|
|
18
|
+
bool found;
|
|
19
|
+
return this->Get(key, found);
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
TValue Get(TKey &key, bool &found) {
|
|
23
|
+
// std::shared_lock<std::shared_timed_mutex> readerLock(this->containerMutex_);
|
|
24
|
+
std::lock_guard <std::mutex> writerLock(this->containerMutex_);
|
|
25
|
+
auto it = this->container_.find(key);
|
|
26
|
+
found = it != this->container_.end();
|
|
27
|
+
if (found) {
|
|
28
|
+
return it->second;
|
|
29
|
+
}
|
|
30
|
+
return nullptr;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
bool ContainsKey(TKey &key) {
|
|
34
|
+
// std::shared_lock<std::shared_timed_mutex> readerLock(this->containerMutex_);
|
|
35
|
+
std::lock_guard <std::mutex> writerLock(this->containerMutex_);
|
|
36
|
+
auto it = this->container_.find(key);
|
|
37
|
+
return it != this->container_.end();
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
void Remove(TKey &key) {
|
|
41
|
+
std::lock_guard <std::mutex> writerLock(this->containerMutex_);
|
|
42
|
+
this->container_.erase(key);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
ConcurrentMap() = default;
|
|
46
|
+
|
|
47
|
+
ConcurrentMap(const ConcurrentMap &) = delete;
|
|
48
|
+
|
|
49
|
+
ConcurrentMap &operator=(const ConcurrentMap &) = delete;
|
|
50
|
+
|
|
51
|
+
private:
|
|
52
|
+
std::mutex containerMutex_;
|
|
53
|
+
robin_hood::unordered_map<TKey, TValue> container_;
|
|
54
|
+
};
|
|
@@ -5,59 +5,357 @@
|
|
|
5
5
|
#pragma once
|
|
6
6
|
|
|
7
7
|
#include <memory>
|
|
8
|
-
#include "
|
|
9
|
-
#
|
|
8
|
+
#include "Common.h"
|
|
9
|
+
#include "OneByteStringResource.h"
|
|
10
|
+
#include "PerIsolateData.h"
|
|
11
|
+
#include "v8-fast-api-calls.h"
|
|
12
|
+
//#ifdef __APPLE__
|
|
13
|
+
//#ifdef __OBJC__
|
|
14
|
+
//#include <Foundation/Foundation.h>
|
|
15
|
+
//#else
|
|
16
|
+
//#include <CoreFoundation/CoreFoundation.h>
|
|
17
|
+
//extern "C" void NSLog(CFStringRef format, ...);
|
|
18
|
+
//#endif
|
|
19
|
+
//#endif
|
|
10
20
|
|
|
11
|
-
using namespace facebook;
|
|
12
21
|
|
|
13
|
-
|
|
14
|
-
|
|
22
|
+
|
|
23
|
+
static const char *LOG_TAG = "JS";
|
|
24
|
+
static int m_maxLogcatObjectSize = 4096;
|
|
25
|
+
|
|
26
|
+
#ifdef __ANDROID__
|
|
27
|
+
|
|
28
|
+
static void sendToADBLogcat(const std::string &message, android_LogPriority logPriority) {
|
|
29
|
+
// limit the size of the message that we send to logcat using the predefined value in package.json
|
|
30
|
+
auto messageToLog = message;
|
|
31
|
+
if (messageToLog.length() > m_maxLogcatObjectSize) {
|
|
32
|
+
messageToLog = messageToLog.erase(m_maxLogcatObjectSize, std::string::npos);
|
|
33
|
+
messageToLog = messageToLog + "...";
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
// split strings into chunks of 4000 characters
|
|
37
|
+
// __android_log_write can't send more than 4000 to the stdout at a time
|
|
38
|
+
auto messageLength = messageToLog.length();
|
|
39
|
+
int maxStringLength = 4000;
|
|
40
|
+
|
|
41
|
+
if (messageLength < maxStringLength) {
|
|
42
|
+
__android_log_write(logPriority, LOG_TAG, messageToLog.c_str());
|
|
43
|
+
} else {
|
|
44
|
+
for (int i = 0; i < messageLength; i += maxStringLength) {
|
|
45
|
+
auto messagePart = messageToLog.substr(i, maxStringLength);
|
|
46
|
+
|
|
47
|
+
__android_log_write(logPriority, LOG_TAG, messagePart.c_str());
|
|
48
|
+
}
|
|
49
|
+
}
|
|
15
50
|
}
|
|
16
51
|
|
|
17
|
-
|
|
18
|
-
inline static rust::Slice<T>
|
|
19
|
-
GetArrayBufferData(jsi::Runtime &runtime, facebook::jsi::ArrayBuffer &array) {
|
|
20
|
-
auto buf = array.data(runtime);
|
|
21
|
-
auto size = array.size(runtime);
|
|
52
|
+
#endif
|
|
22
53
|
|
|
23
|
-
|
|
24
|
-
|
|
54
|
+
//#ifdef __APPLE__
|
|
55
|
+
//#ifndef __OBJC__
|
|
56
|
+
//#define Log(fmt, ...) NSLog(CFSTR(fmt), ##__VA_ARGS__)
|
|
57
|
+
//#else
|
|
58
|
+
//#define Log(...) NSLog(__VA_ARGS__)
|
|
59
|
+
//#endif
|
|
60
|
+
//#endif
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
|
|
64
|
+
static void LogToConsole(const std::string &message) {
|
|
65
|
+
#ifdef __ANDROID__
|
|
66
|
+
sendToADBLogcat(message, android_LogPriority::ANDROID_LOG_INFO);
|
|
67
|
+
#endif
|
|
68
|
+
|
|
69
|
+
#ifdef __APPLE__
|
|
70
|
+
// Log("%s", message.c_str());
|
|
71
|
+
#endif
|
|
25
72
|
}
|
|
26
73
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
auto buf = array.data(runtime);
|
|
31
|
-
auto offset = array.offset(runtime);
|
|
32
|
-
auto size = array.size(runtime);
|
|
74
|
+
enum class NativeMask {
|
|
75
|
+
Type = 1
|
|
76
|
+
};
|
|
33
77
|
|
|
34
|
-
|
|
78
|
+
enum class NativeType {
|
|
79
|
+
None,
|
|
80
|
+
CanvasGradient,
|
|
81
|
+
CanvasPattern,
|
|
82
|
+
ImageData,
|
|
83
|
+
ImageAsset,
|
|
84
|
+
CanvasRenderingContext2D,
|
|
85
|
+
WebGLRenderingContextBase,
|
|
86
|
+
Path2D,
|
|
87
|
+
Matrix,
|
|
88
|
+
ImageBitmap,
|
|
89
|
+
TextMetrics,
|
|
35
90
|
|
|
36
|
-
|
|
37
|
-
|
|
91
|
+
WebGLQuery,
|
|
92
|
+
WebGLProgram,
|
|
93
|
+
WebGLShader,
|
|
94
|
+
WebGLBuffer,
|
|
95
|
+
WebGLFramebuffer,
|
|
96
|
+
WebGLRenderbuffer,
|
|
97
|
+
WebGLTexture,
|
|
98
|
+
WebGLActiveInfo,
|
|
99
|
+
OES_fbo_render_mipmap,
|
|
100
|
+
EXT_blend_minmax,
|
|
101
|
+
EXT_color_buffer_half_float,
|
|
102
|
+
EXT_disjoint_timer_query,
|
|
103
|
+
EXT_sRGB,
|
|
104
|
+
EXT_shader_texture_lod,
|
|
105
|
+
EXT_texture_filter_anisotropic,
|
|
106
|
+
OES_element_index_uint,
|
|
107
|
+
OES_standard_derivatives,
|
|
108
|
+
OES_texture_float,
|
|
109
|
+
OES_texture_float_linear,
|
|
110
|
+
OES_texture_half_float_linear,
|
|
111
|
+
OES_texture_half_float,
|
|
112
|
+
WEBGL_color_buffer_float,
|
|
113
|
+
OES_vertex_array_object,
|
|
114
|
+
WebGLVertexArrayObject,
|
|
115
|
+
WEBGL_compressed_texture_atc,
|
|
116
|
+
WEBGL_compressed_texture_etc1,
|
|
117
|
+
WEBGL_compressed_texture_s3tc,
|
|
118
|
+
WEBGL_compressed_texture_s3tc_srgb,
|
|
119
|
+
WEBGL_compressed_texture_etc,
|
|
120
|
+
WEBGL_compressed_texture_pvrtc,
|
|
121
|
+
WEBGL_lose_context,
|
|
122
|
+
ANGLE_instanced_arrays,
|
|
123
|
+
WEBGL_depth_texture,
|
|
124
|
+
WEBGL_draw_buffers,
|
|
125
|
+
WebGLShaderPrecisionFormat,
|
|
126
|
+
WebGLUniformLocation,
|
|
127
|
+
WebGLSampler,
|
|
128
|
+
WebGLTransformFeedback,
|
|
129
|
+
WebGLSync
|
|
130
|
+
};
|
|
131
|
+
|
|
132
|
+
inline static v8::Local<v8::String>
|
|
133
|
+
ConvertToV8OneByteString(v8::Isolate *isolate, std::string string) {
|
|
134
|
+
auto value = new OneByteStringResource(std::move(string));
|
|
135
|
+
auto ret = v8::String::NewExternalOneByte(isolate, value);
|
|
136
|
+
return ret.ToLocalChecked();
|
|
38
137
|
}
|
|
39
138
|
|
|
40
|
-
|
|
41
|
-
inline static
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
139
|
+
|
|
140
|
+
inline static v8::Local<v8::String>
|
|
141
|
+
ConvertToV8OneByteString(v8::Isolate *isolate, char *string) {
|
|
142
|
+
auto value = new OneByteStringResource(string);
|
|
143
|
+
auto ret = v8::String::NewExternalOneByte(isolate, value);
|
|
144
|
+
return ret.ToLocalChecked();
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
inline static v8::Local<v8::String>
|
|
148
|
+
ConvertToV8String(v8::Isolate *isolate, const std::string &string) {
|
|
149
|
+
return v8::String::NewFromUtf8(isolate, string.c_str()).ToLocalChecked();
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
inline static std::string
|
|
153
|
+
ConvertFromV8String(v8::Isolate *isolate, const v8::Local<v8::Value> &value) {
|
|
154
|
+
if (value.IsEmpty()) {
|
|
155
|
+
return {};
|
|
50
156
|
}
|
|
51
157
|
|
|
52
|
-
|
|
158
|
+
if (value->IsStringObject()) {
|
|
159
|
+
v8::Local<v8::String> obj = value.As<v8::StringObject>()->ValueOf();
|
|
160
|
+
return ConvertFromV8String(isolate, obj);
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
v8::String::Utf8Value result(isolate, value);
|
|
164
|
+
|
|
165
|
+
const char *val = *result;
|
|
166
|
+
|
|
167
|
+
if (val == nullptr) {
|
|
168
|
+
return {};
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
return {*result};
|
|
53
172
|
}
|
|
54
173
|
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
174
|
+
|
|
175
|
+
static void SetPrivateValue(v8::Isolate *isolate, const v8::Local<v8::Object> &obj,
|
|
176
|
+
const v8::Local<v8::String> &propName,
|
|
177
|
+
const v8::Local<v8::Value> &value) {
|
|
178
|
+
v8::Local<v8::Context> context;
|
|
179
|
+
obj->GetCreationContext().ToLocal(&context);
|
|
180
|
+
v8::Local<v8::Private> privateKey = v8::Private::ForApi(isolate, propName);
|
|
181
|
+
obj->SetPrivate(context, privateKey, value);
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
static v8::Local<v8::Value>
|
|
185
|
+
GetPrivateValue(v8::Isolate *isolate, const v8::Local<v8::Object> &obj,
|
|
186
|
+
const v8::Local<v8::String> &propName) {
|
|
187
|
+
v8::Local<v8::Context> context;
|
|
188
|
+
obj->GetCreationContext().ToLocal(&context);
|
|
189
|
+
v8::Local<v8::Private> privateKey = v8::Private::ForApi(isolate, propName);
|
|
190
|
+
|
|
191
|
+
v8::Maybe<bool> hasPrivate = obj->HasPrivate(context, privateKey);
|
|
192
|
+
|
|
193
|
+
if (!hasPrivate.FromMaybe(false)) {
|
|
194
|
+
return v8::Local<v8::Value>();
|
|
60
195
|
}
|
|
61
|
-
|
|
196
|
+
|
|
197
|
+
v8::Local<v8::Value> result;
|
|
198
|
+
|
|
199
|
+
obj->GetPrivate(context, privateKey).ToLocal(&result);
|
|
200
|
+
|
|
201
|
+
return result;
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
static void SetNativeType(const v8::Local<v8::Object> &obj, NativeType type) {
|
|
205
|
+
auto value = (int32_t) type;
|
|
206
|
+
obj->SetAlignedPointerInInternalField(1, new int32_t(value));
|
|
62
207
|
}
|
|
63
208
|
|
|
209
|
+
inline static NativeType GetNativeType(const v8::Local<v8::Value> &obj) {
|
|
210
|
+
if (!obj->IsNullOrUndefined() && obj->IsObject() &&
|
|
211
|
+
obj.As<v8::Object>()->InternalFieldCount() > 1) {
|
|
212
|
+
auto info = obj.As<v8::Object>()->GetAlignedPointerFromInternalField(1);
|
|
213
|
+
|
|
214
|
+
if (info != nullptr) {
|
|
215
|
+
auto value = *static_cast<int32_t *>(info);
|
|
216
|
+
auto ret = value;
|
|
217
|
+
if (ret >= (int) NativeType::CanvasGradient &&
|
|
218
|
+
ret <= (int) NativeType::WebGLSync) {
|
|
219
|
+
return (NativeType) ret;
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
return NativeType::None;
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
|
|
228
|
+
//template<class T>
|
|
229
|
+
//static inline void Finalizer(const v8::WeakCallbackInfo<T> &data) {
|
|
230
|
+
// auto *pThis = data.GetParameter();
|
|
231
|
+
// pThis->weakHandle_.Reset();
|
|
232
|
+
// delete pThis;
|
|
233
|
+
//}
|
|
234
|
+
|
|
235
|
+
//static inline void BindFinalizer(v8::Isolate *isolate, v8::Global<v8::Object> &weakHandle, const v8::Local<v8::Object> &object) {
|
|
236
|
+
// v8::HandleScope scopedHandle(isolate);
|
|
237
|
+
// weakHandle.Reset(isolate, object);
|
|
238
|
+
// weakHandle.SetWeak(this, Finalizer, v8::WeakCallbackType::kParameter);
|
|
239
|
+
//}
|
|
240
|
+
|
|
241
|
+
|
|
242
|
+
|
|
243
|
+
static void SetFastMethod(v8::Isolate *isolate,
|
|
244
|
+
v8::Local<v8::Template> that,
|
|
245
|
+
const char *name,
|
|
246
|
+
v8::FunctionCallback slow_callback,
|
|
247
|
+
const v8::CFunction *c_function,
|
|
248
|
+
v8::Local<v8::Value> data) {
|
|
249
|
+
v8::Local<v8::FunctionTemplate> t =
|
|
250
|
+
v8::FunctionTemplate::New(isolate,
|
|
251
|
+
slow_callback,
|
|
252
|
+
data,
|
|
253
|
+
v8::Local<v8::Signature>(),
|
|
254
|
+
0,
|
|
255
|
+
v8::ConstructorBehavior::kThrow,
|
|
256
|
+
v8::SideEffectType::kHasSideEffect,
|
|
257
|
+
c_function);
|
|
258
|
+
// kInternalized strings are created in the old space.
|
|
259
|
+
const v8::NewStringType type = v8::NewStringType::kInternalized;
|
|
260
|
+
v8::Local<v8::String> name_string =
|
|
261
|
+
v8::String::NewFromUtf8(isolate, name, type).ToLocalChecked();
|
|
262
|
+
that->Set(name_string, t);
|
|
263
|
+
}
|
|
264
|
+
|
|
265
|
+
|
|
266
|
+
#define NUM(a) (sizeof(a) / sizeof(*a))
|
|
267
|
+
|
|
268
|
+
static void SetFastMethodWithOverLoads(v8::Isolate *isolate,
|
|
269
|
+
v8::Local<v8::Template> that,
|
|
270
|
+
const char *name,
|
|
271
|
+
v8::FunctionCallback slow_callback,
|
|
272
|
+
const v8::CFunction *method_overloads,
|
|
273
|
+
v8::Local<v8::Value> data) {
|
|
274
|
+
|
|
275
|
+
auto len = NUM(&method_overloads);
|
|
276
|
+
v8::Local<v8::FunctionTemplate> t =
|
|
277
|
+
v8::FunctionTemplate::NewWithCFunctionOverloads(isolate,
|
|
278
|
+
slow_callback,
|
|
279
|
+
data,
|
|
280
|
+
v8::Local<v8::Signature>(),
|
|
281
|
+
0,
|
|
282
|
+
v8::ConstructorBehavior::kThrow,
|
|
283
|
+
v8::SideEffectType::kHasSideEffect,
|
|
284
|
+
{method_overloads, len});
|
|
285
|
+
// kInternalized strings are created in the old space.
|
|
286
|
+
const v8::NewStringType type = v8::NewStringType::kInternalized;
|
|
287
|
+
v8::Local<v8::String> name_string =
|
|
288
|
+
v8::String::NewFromUtf8(isolate, name, type).ToLocalChecked();
|
|
289
|
+
that->Set(name_string, t);
|
|
290
|
+
}
|
|
291
|
+
|
|
292
|
+
|
|
293
|
+
static void SetFastMethod(v8::Local<v8::Context> context,
|
|
294
|
+
v8::Local<v8::Object> that,
|
|
295
|
+
const char *name,
|
|
296
|
+
v8::FunctionCallback slow_callback,
|
|
297
|
+
const v8::CFunction *c_function,
|
|
298
|
+
v8::Local<v8::Value> data = v8::Local<v8::Value>()) {
|
|
299
|
+
v8::Isolate *isolate = context->GetIsolate();
|
|
300
|
+
v8::Local<v8::Function> function =
|
|
301
|
+
v8::FunctionTemplate::New(isolate,
|
|
302
|
+
slow_callback,
|
|
303
|
+
data,
|
|
304
|
+
v8::Local<v8::Signature>(),
|
|
305
|
+
0,
|
|
306
|
+
v8::ConstructorBehavior::kThrow,
|
|
307
|
+
v8::SideEffectType::kHasSideEffect,
|
|
308
|
+
c_function)
|
|
309
|
+
->GetFunction(context)
|
|
310
|
+
.ToLocalChecked();
|
|
311
|
+
const v8::NewStringType type = v8::NewStringType::kInternalized;
|
|
312
|
+
v8::Local<v8::String> name_string =
|
|
313
|
+
v8::String::NewFromUtf8(isolate, name, type).ToLocalChecked();
|
|
314
|
+
that->Set(context, name_string, function).Check();
|
|
315
|
+
}
|
|
316
|
+
|
|
317
|
+
static void SetFastMethodNoSideEffect(v8::Local<v8::Context> context,
|
|
318
|
+
v8::Local<v8::Object> that,
|
|
319
|
+
const char *name,
|
|
320
|
+
v8::FunctionCallback slow_callback,
|
|
321
|
+
const v8::CFunction *c_function,
|
|
322
|
+
v8::Local<v8::Value> data) {
|
|
323
|
+
v8::Isolate *isolate = context->GetIsolate();
|
|
324
|
+
v8::Local<v8::Function> function =
|
|
325
|
+
v8::FunctionTemplate::New(isolate,
|
|
326
|
+
slow_callback,
|
|
327
|
+
data,
|
|
328
|
+
v8::Local<v8::Signature>(),
|
|
329
|
+
0,
|
|
330
|
+
v8::ConstructorBehavior::kThrow,
|
|
331
|
+
v8::SideEffectType::kHasNoSideEffect,
|
|
332
|
+
c_function)
|
|
333
|
+
->GetFunction(context)
|
|
334
|
+
.ToLocalChecked();
|
|
335
|
+
const v8::NewStringType type = v8::NewStringType::kInternalized;
|
|
336
|
+
v8::Local<v8::String> name_string =
|
|
337
|
+
v8::String::NewFromUtf8(isolate, name, type).ToLocalChecked();
|
|
338
|
+
that->Set(context, name_string, function).Check();
|
|
339
|
+
}
|
|
340
|
+
|
|
341
|
+
static void SetFastMethodNoSideEffect(v8::Isolate *isolate,
|
|
342
|
+
v8::Local<v8::Template> that,
|
|
343
|
+
const char *name,
|
|
344
|
+
v8::FunctionCallback slow_callback,
|
|
345
|
+
const v8::CFunction *c_function,
|
|
346
|
+
v8::Local<v8::Value> data) {
|
|
347
|
+
v8::Local<v8::FunctionTemplate> t =
|
|
348
|
+
v8::FunctionTemplate::New(isolate,
|
|
349
|
+
slow_callback,
|
|
350
|
+
data,
|
|
351
|
+
v8::Local<v8::Signature>(),
|
|
352
|
+
0,
|
|
353
|
+
v8::ConstructorBehavior::kThrow,
|
|
354
|
+
v8::SideEffectType::kHasNoSideEffect,
|
|
355
|
+
c_function);
|
|
356
|
+
// kInternalized strings are created in the old space.
|
|
357
|
+
const v8::NewStringType type = v8::NewStringType::kInternalized;
|
|
358
|
+
v8::Local<v8::String> name_string =
|
|
359
|
+
v8::String::NewFromUtf8(isolate, name, type).ToLocalChecked();
|
|
360
|
+
that->Set(name_string, t);
|
|
361
|
+
}
|