@nativescript/canvas 2.0.0-webgpu.1 → 2.0.0-webgpu.3
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 +2 -16
- package/Canvas/common.js +1 -62
- package/Canvas/common.js.map +1 -1
- package/Canvas/index.android.d.ts +6 -7
- package/Canvas/index.android.js +87 -42
- package/Canvas/index.android.js.map +1 -1
- package/Canvas/index.d.ts +7 -8
- package/Canvas/index.ios.d.ts +3 -2
- package/Canvas/index.ios.js +87 -46
- package/Canvas/index.ios.js.map +1 -1
- package/Canvas2D/CanvasRenderingContext2D/index.js +71 -72
- package/Canvas2D/CanvasRenderingContext2D/index.js.map +1 -1
- package/Canvas2D/DOMMatrix/index.js +1 -1
- package/Canvas2D/DOMMatrix/index.js.map +1 -1
- package/Canvas2D/ImageData/index.js.map +1 -1
- package/Canvas2D/Path2D/index.js.map +1 -1
- package/Dom/Dom.js +8 -1
- package/Dom/Dom.js.map +1 -1
- package/Dom/Group.js.map +1 -1
- package/Dom/Image.d.ts +4 -1
- package/Dom/Image.js +16 -2
- package/Dom/Image.js.map +1 -1
- package/Dom/Paint.js.map +1 -1
- package/Dom/Text.js.map +1 -1
- package/Dom/shaders/LinearGradient.js.map +1 -1
- package/Dom/shaders/TwoPointConicalGradient.js.map +1 -1
- package/Dom/shapes/Atlas.js.map +1 -1
- package/Dom/shapes/Circle.js.map +1 -1
- package/Dom/shapes/Line.js.map +1 -1
- package/Dom/shapes/Oval.js.map +1 -1
- package/Dom/shapes/Path.js.map +1 -1
- package/Dom/shapes/Rect.js.map +1 -1
- package/Dom/shapes/RoundedRect.js.map +1 -1
- package/Dom/shapes/index.js.map +1 -1
- package/ImageAsset/index.d.ts +3 -1
- package/ImageAsset/index.js +38 -6
- package/ImageAsset/index.js.map +1 -1
- package/ImageBitmap/index.js +3 -3
- package/ImageBitmap/index.js.map +1 -1
- package/README.md +64 -3
- package/TextDecoder/index.js +3 -3
- package/TextDecoder/index.js.map +1 -1
- package/TextEncoder/index.js +3 -3
- package/TextEncoder/index.js.map +1 -1
- package/WebGL/WebGLExtensions/index.js +5 -5
- package/WebGL/WebGLExtensions/index.js.map +1 -1
- package/WebGL/WebGLRenderingContext/common.js.map +1 -1
- package/WebGL/WebGLRenderingContext/index.js.map +1 -1
- package/WebGL2/WebGL2RenderingContext/index.js.map +1 -1
- package/WebGPU/Constants.js.map +1 -1
- package/WebGPU/GPU.js.map +1 -1
- package/WebGPU/GPUAdapter.js.map +1 -1
- package/WebGPU/GPUAdapterInfo.js.map +1 -1
- package/WebGPU/GPUBindGroup.js.map +1 -1
- package/WebGPU/GPUBindGroupLayout.js.map +1 -1
- package/WebGPU/GPUBuffer.js +5 -1
- package/WebGPU/GPUBuffer.js.map +1 -1
- package/WebGPU/GPUCanvasContext.js.map +1 -1
- package/WebGPU/GPUCommandBuffer.js.map +1 -1
- package/WebGPU/GPUCommandEncoder.js.map +1 -1
- package/WebGPU/GPUComputePassEncoder.js.map +1 -1
- package/WebGPU/GPUComputePipeline.js.map +1 -1
- package/WebGPU/GPUDevice.d.ts +2 -2
- package/WebGPU/GPUDevice.js +4 -3
- package/WebGPU/GPUDevice.js.map +1 -1
- package/WebGPU/GPUExternalTexture.js.map +1 -1
- package/WebGPU/GPUPipelineLayout.js.map +1 -1
- package/WebGPU/GPUQuerySet.js.map +1 -1
- package/WebGPU/GPUQueue.js.map +1 -1
- package/WebGPU/GPURenderBundle.js.map +1 -1
- package/WebGPU/GPURenderBundleEncoder.js.map +1 -1
- package/WebGPU/GPURenderPassEncoder.js +2 -2
- package/WebGPU/GPURenderPassEncoder.js.map +1 -1
- package/WebGPU/GPURenderPipeline.js.map +1 -1
- package/WebGPU/GPUSampler.js.map +1 -1
- package/WebGPU/GPUShaderModule.js.map +1 -1
- package/WebGPU/GPUTexture.js.map +1 -1
- package/WebGPU/GPUTextureView.js.map +1 -1
- package/WebGPU/Types.d.ts +27 -27
- package/WebGPU/Utils.d.ts +1 -1
- package/WebGPU/Utils.js.map +1 -1
- package/angular/{esm2020 → esm2022}/index.mjs +5 -5
- package/angular/{fesm2015 → fesm2022}/nativescript-canvas-angular.mjs +4 -4
- package/angular/{fesm2020 → fesm2022}/nativescript-canvas-angular.mjs.map +1 -1
- package/angular/package.json +4 -10
- package/helpers.js.map +1 -1
- package/package.json +2 -2
- package/platforms/android/canvas-release.aar +0 -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 +21 -9
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Headers/canvas_native.h +2049 -2061
- 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 +752 -108
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios.private.swiftinterface +35 -9
- 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 +35 -9
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/NSCCanvas.nib +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/dSYMs/CanvasNative.framework.dSYM/Contents/Resources/DWARF/CanvasNative +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/dSYMs/CanvasNative.framework.dSYM/Contents/Resources/Relocations/aarch64/CanvasNative.yml +644 -602
- 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 +42 -18
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Headers/canvas_native.h +2049 -2061
- 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 +752 -108
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios-simulator.private.swiftinterface +35 -9
- 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 +35 -9
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/x86_64-apple-ios-simulator.abi.json +752 -108
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/x86_64-apple-ios-simulator.private.swiftinterface +35 -9
- 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 +35 -9
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/NSCCanvas.nib +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/_CodeSignature/CodeResources +24 -24
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/dSYMs/CanvasNative.framework.dSYM/Contents/Resources/DWARF/CanvasNative +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/dSYMs/CanvasNative.framework.dSYM/Contents/Resources/Relocations/aarch64/CanvasNative.yml +646 -604
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/dSYMs/CanvasNative.framework.dSYM/Contents/Resources/Relocations/x86_64/CanvasNative.yml +684 -638
- package/platforms/ios/src/NSOperationQueueWrapper.h +2 -0
- package/platforms/ios/src/cpp/AsyncCallback.h +206 -0
- package/platforms/ios/src/cpp/CanvasJSIModule.cpp +13 -13
- package/platforms/ios/src/cpp/Helpers.h +2 -164
- package/platforms/ios/src/cpp/ImageAssetImpl.cpp +13 -13
- package/platforms/ios/src/cpp/ImageBitmapImpl.cpp +1 -1
- package/platforms/ios/src/cpp/ImageBitmapImpl.h +2 -1
- package/platforms/ios/src/cpp/JSIReadFileCallback.h +4 -4
- package/platforms/ios/src/cpp/NativeType.h +87 -0
- package/platforms/ios/src/cpp/ObjectWrapperImpl.h +50 -0
- package/platforms/ios/src/cpp/OneByteStringResource.cpp +2 -2
- package/platforms/ios/src/cpp/PromiseCallback.h +198 -0
- package/platforms/ios/src/cpp/RafImpl.h +2 -2
- package/platforms/ios/src/cpp/TextDecoderImpl.cpp +0 -6
- package/platforms/ios/src/cpp/TextDecoderImpl.h +3 -3
- package/platforms/ios/src/cpp/TextEncoderImpl.cpp +1 -1
- package/platforms/ios/src/cpp/TextEncoderImpl.h +3 -3
- package/platforms/ios/src/cpp/canvas2d/CanvasGradient.h +8 -7
- package/platforms/ios/src/cpp/canvas2d/CanvasPattern.cpp +1 -1
- package/platforms/ios/src/cpp/canvas2d/CanvasPattern.h +3 -3
- package/platforms/ios/src/cpp/canvas2d/CanvasRenderingContext2DImpl.cpp +145 -75
- package/platforms/ios/src/cpp/canvas2d/CanvasRenderingContext2DImpl.h +74 -20
- package/platforms/ios/src/cpp/canvas2d/ImageDataImpl.cpp +5 -6
- package/platforms/ios/src/cpp/canvas2d/ImageDataImpl.h +4 -4
- package/platforms/ios/src/cpp/canvas2d/MatrixImpl.cpp +10 -10
- package/platforms/ios/src/cpp/canvas2d/MatrixImpl.h +2 -2
- package/platforms/ios/src/cpp/canvas2d/Path2D.cpp +6 -3
- package/platforms/ios/src/cpp/canvas2d/Path2D.h +2 -2
- package/platforms/ios/src/cpp/canvas2d/TextMetricsImpl.h +3 -3
- package/platforms/ios/src/cpp/webgl/WebGLActiveInfoImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/WebGLBuffer.h +1 -1
- package/platforms/ios/src/cpp/webgl/WebGLFramebuffer.h +1 -1
- package/platforms/ios/src/cpp/webgl/WebGLProgram.h +3 -3
- package/platforms/ios/src/cpp/webgl/WebGLRenderbuffer.h +3 -3
- package/platforms/ios/src/cpp/webgl/WebGLRenderingContext.cpp +8 -8
- package/platforms/ios/src/cpp/webgl/WebGLRenderingContext.h +1 -1
- package/platforms/ios/src/cpp/webgl/WebGLRenderingContextBase.cpp +1 -1
- package/platforms/ios/src/cpp/webgl/WebGLShader.h +1 -1
- package/platforms/ios/src/cpp/webgl/WebGLShaderPrecisionFormatImpl.h +5 -5
- package/platforms/ios/src/cpp/webgl/WebGLTexture.h +3 -2
- package/platforms/ios/src/cpp/webgl/WebGLUniformLocation.h +2 -2
- package/platforms/ios/src/cpp/webgl/extensions/ANGLE_instanced_arraysImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/EXT_blend_minmaxImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/EXT_color_buffer_half_floatImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/EXT_disjoint_timer_queryImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/EXT_sRGBImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/EXT_shader_texture_lodImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/EXT_texture_filter_anisotropicImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/OES_element_index_uintImpl.h +2 -2
- package/platforms/ios/src/cpp/webgl/extensions/OES_fbo_render_mipmap.h +5 -5
- package/platforms/ios/src/cpp/webgl/extensions/OES_standard_derivativesImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/OES_texture_floatImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/OES_texture_float_linearImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/OES_texture_half_floatImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/OES_texture_half_float_linearImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/OES_vertex_array_objectImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_color_buffer_floatImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_compressed_texture_atcImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_compressed_texture_etc1Impl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_compressed_texture_etcImpl.h +2 -2
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_compressed_texture_pvrtcImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_compressed_texture_s3tcImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_compressed_texture_s3tc_srgbImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_depth_textureImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_draw_buffersImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl/extensions/WEBGL_lose_contextImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl2/WebGL2RenderingContext.cpp +722 -722
- package/platforms/ios/src/cpp/webgl2/WebGL2RenderingContext.h +1 -1
- package/platforms/ios/src/cpp/webgl2/WebGLQuery.h +1 -1
- package/platforms/ios/src/cpp/webgl2/WebGLSampler.h +1 -1
- package/platforms/ios/src/cpp/webgl2/WebGLSyncImpl.h +1 -1
- package/platforms/ios/src/cpp/webgl2/WebGLTransformFeedback.h +1 -1
- package/platforms/ios/src/cpp/webgl2/WebGLVertexArrayObject.h +2 -2
- package/platforms/ios/src/cpp/webgpu/GPUAdapterImpl.cpp +124 -58
- package/platforms/ios/src/cpp/webgpu/GPUAdapterImpl.h +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUAdapterInfoImpl.cpp +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUAdapterInfoImpl.h +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUBindGroupImpl.cpp +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUBindGroupImpl.h +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUBindGroupLayoutImpl.cpp +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUBindGroupLayoutImpl.h +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUBufferImpl.cpp +44 -30
- package/platforms/ios/src/cpp/webgpu/GPUBufferImpl.h +4 -4
- package/platforms/ios/src/cpp/webgpu/GPUCanvasContextImpl.cpp +11 -11
- package/platforms/ios/src/cpp/webgpu/GPUCanvasContextImpl.h +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUCommandBufferImpl.cpp +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUCommandBufferImpl.h +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUCommandEncoderImpl.cpp +30 -31
- package/platforms/ios/src/cpp/webgpu/GPUCommandEncoderImpl.h +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUComputePassEncoderImpl.cpp +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUComputePassEncoderImpl.h +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUComputePipelineImpl.cpp +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUComputePipelineImpl.h +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUDeviceImpl.cpp +99 -73
- package/platforms/ios/src/cpp/webgpu/GPUDeviceImpl.h +2 -2
- package/platforms/ios/src/cpp/webgpu/GPUImpl.cpp +54 -41
- package/platforms/ios/src/cpp/webgpu/GPUImpl.h +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUPipelineLayoutImpl.cpp +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUPipelineLayoutImpl.h +5 -4
- package/platforms/ios/src/cpp/webgpu/GPUQuerySetImpl.cpp +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUQuerySetImpl.h +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUQueueImpl.cpp +38 -23
- package/platforms/ios/src/cpp/webgpu/GPUQueueImpl.h +1 -1
- package/platforms/ios/src/cpp/webgpu/GPURenderBundleEncoderImpl.h +1 -1
- package/platforms/ios/src/cpp/webgpu/GPURenderBundleImpl.cpp +1 -1
- package/platforms/ios/src/cpp/webgpu/GPURenderBundleImpl.h +1 -1
- package/platforms/ios/src/cpp/webgpu/GPURenderPassEncoderImpl.cpp +4 -3
- package/platforms/ios/src/cpp/webgpu/GPURenderPassEncoderImpl.h +1 -1
- package/platforms/ios/src/cpp/webgpu/GPURenderPipelineImpl.cpp +1 -1
- package/platforms/ios/src/cpp/webgpu/GPURenderPipelineImpl.h +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUSamplerImpl.cpp +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUSamplerImpl.h +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUShaderModuleImpl.cpp +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUShaderModuleImpl.h +2 -2
- package/platforms/ios/src/cpp/webgpu/GPUSupportedLimitsImpl.cpp +2 -2
- package/platforms/ios/src/cpp/webgpu/GPUSupportedLimitsImpl.h +2 -2
- package/platforms/ios/src/cpp/webgpu/GPUTextureImpl.h +4 -4
- package/platforms/ios/src/cpp/webgpu/GPUTextureViewImpl.cpp +1 -1
- package/platforms/ios/src/cpp/webgpu/GPUTextureViewImpl.h +2 -2
- package/react/index.d.ts +1 -1
- package/utils.js.map +1 -1
- package/angular/fesm2015/nativescript-canvas-angular.mjs.map +0 -1
- package/angular/fesm2020/nativescript-canvas-angular.mjs +0 -24
- package/typings/objc!CanvasNative.d.ts +0 -2038
- package/typings/objc!CanvasNative.js +0 -1
- package/typings/objc!CanvasNative.js.map +0 -1
- /package/angular/{esm2020 → esm2022}/nativescript-canvas-angular.mjs +0 -0
|
@@ -281,7 +281,7 @@ void MatrixImpl::Ctor(const v8::FunctionCallbackInfo<v8::Value> &args) {
|
|
|
281
281
|
|
|
282
282
|
ret->SetAlignedPointerInInternalField(0, object);
|
|
283
283
|
|
|
284
|
-
SetNativeType(
|
|
284
|
+
SetNativeType(object, NativeType::Matrix);
|
|
285
285
|
|
|
286
286
|
object->BindFinalizer(isolate, ret);
|
|
287
287
|
|
|
@@ -307,7 +307,7 @@ void MatrixImpl::Ctor(const v8::FunctionCallbackInfo<v8::Value> &args) {
|
|
|
307
307
|
|
|
308
308
|
ret->SetAlignedPointerInInternalField(0, object);
|
|
309
309
|
|
|
310
|
-
SetNativeType(
|
|
310
|
+
SetNativeType(object, NativeType::Matrix);
|
|
311
311
|
|
|
312
312
|
object->BindFinalizer(isolate, ret);
|
|
313
313
|
|
|
@@ -322,7 +322,7 @@ void MatrixImpl::Ctor(const v8::FunctionCallbackInfo<v8::Value> &args) {
|
|
|
322
322
|
|
|
323
323
|
ret->SetAlignedPointerInInternalField(0, object);
|
|
324
324
|
|
|
325
|
-
SetNativeType(
|
|
325
|
+
SetNativeType(object, NativeType::Matrix);
|
|
326
326
|
|
|
327
327
|
object->BindFinalizer(isolate, ret);
|
|
328
328
|
|
|
@@ -897,7 +897,7 @@ void MatrixImpl::Translate(const v8::FunctionCallbackInfo<v8::Value> &args) {
|
|
|
897
897
|
|
|
898
898
|
ret->SetAlignedPointerInInternalField(0, object);
|
|
899
899
|
|
|
900
|
-
SetNativeType(
|
|
900
|
+
SetNativeType(object, NativeType::Matrix);
|
|
901
901
|
|
|
902
902
|
object->BindFinalizer(isolate, ret);
|
|
903
903
|
|
|
@@ -989,7 +989,7 @@ void MatrixImpl::ScaleNonUniform(const v8::FunctionCallbackInfo<v8::Value> &args
|
|
|
989
989
|
|
|
990
990
|
ret->SetAlignedPointerInInternalField(0, object);
|
|
991
991
|
|
|
992
|
-
SetNativeType(
|
|
992
|
+
SetNativeType(object, NativeType::Matrix);
|
|
993
993
|
|
|
994
994
|
object->BindFinalizer(isolate, ret);
|
|
995
995
|
|
|
@@ -1048,7 +1048,7 @@ void MatrixImpl::Rotate(const v8::FunctionCallbackInfo<v8::Value> &args) {
|
|
|
1048
1048
|
|
|
1049
1049
|
ret->SetAlignedPointerInInternalField(0, object);
|
|
1050
1050
|
|
|
1051
|
-
SetNativeType(
|
|
1051
|
+
SetNativeType(object, NativeType::Matrix);
|
|
1052
1052
|
|
|
1053
1053
|
object->BindFinalizer(isolate, ret);
|
|
1054
1054
|
|
|
@@ -1105,7 +1105,7 @@ void MatrixImpl::SkewX(const v8::FunctionCallbackInfo<v8::Value> &args) {
|
|
|
1105
1105
|
|
|
1106
1106
|
ret->SetAlignedPointerInInternalField(0, object);
|
|
1107
1107
|
|
|
1108
|
-
SetNativeType(
|
|
1108
|
+
SetNativeType(object, NativeType::Matrix);
|
|
1109
1109
|
|
|
1110
1110
|
object->BindFinalizer(isolate, ret);
|
|
1111
1111
|
|
|
@@ -1144,7 +1144,7 @@ void MatrixImpl::SkewY(const v8::FunctionCallbackInfo<v8::Value> &args) {
|
|
|
1144
1144
|
if (type == NativeType::Matrix) {
|
|
1145
1145
|
auto ptr = MatrixImpl::GetPointer(value.As<v8::Object>());
|
|
1146
1146
|
auto matrix = canvas_native_matrix_skew_y(
|
|
1147
|
-
angle->NumberValue(context).ToChecked(),
|
|
1147
|
+
(float) angle->NumberValue(context).ToChecked(),
|
|
1148
1148
|
ptr->GetMatrix());
|
|
1149
1149
|
if (matrix == nullptr) {
|
|
1150
1150
|
args.GetReturnValue().SetUndefined();
|
|
@@ -1158,7 +1158,7 @@ void MatrixImpl::SkewY(const v8::FunctionCallbackInfo<v8::Value> &args) {
|
|
|
1158
1158
|
|
|
1159
1159
|
ret->SetAlignedPointerInInternalField(0, object);
|
|
1160
1160
|
|
|
1161
|
-
SetNativeType(
|
|
1161
|
+
SetNativeType(object, NativeType::Matrix);
|
|
1162
1162
|
|
|
1163
1163
|
object->BindFinalizer(isolate, ret);
|
|
1164
1164
|
|
|
@@ -1198,7 +1198,7 @@ void MatrixImpl::Clone(const v8::FunctionCallbackInfo<v8::Value> &args) {
|
|
|
1198
1198
|
|
|
1199
1199
|
ret->SetAlignedPointerInInternalField(0, object);
|
|
1200
1200
|
|
|
1201
|
-
SetNativeType(
|
|
1201
|
+
SetNativeType(object, NativeType::Matrix);
|
|
1202
1202
|
|
|
1203
1203
|
object->BindFinalizer(isolate, ret);
|
|
1204
1204
|
|
|
@@ -10,9 +10,9 @@
|
|
|
10
10
|
|
|
11
11
|
class MatrixImpl: public ObjectWrapperImpl {
|
|
12
12
|
public:
|
|
13
|
-
MatrixImpl(Matrix* matrix);
|
|
13
|
+
explicit MatrixImpl(Matrix* matrix);
|
|
14
14
|
~MatrixImpl(){
|
|
15
|
-
|
|
15
|
+
canvas_native_matrix_release(this->GetMatrix());
|
|
16
16
|
this->matrix_ = nullptr;
|
|
17
17
|
}
|
|
18
18
|
|
|
@@ -75,8 +75,6 @@ void Path2D::Ctor(const v8::FunctionCallbackInfo<v8::Value> &args) {
|
|
|
75
75
|
|
|
76
76
|
auto ret = args.This();
|
|
77
77
|
|
|
78
|
-
SetNativeType(ret, NativeType::Path2D);
|
|
79
|
-
|
|
80
78
|
if (count > 0) {
|
|
81
79
|
if (value->IsString()) {
|
|
82
80
|
auto d = ConvertFromV8String(isolate, value);
|
|
@@ -87,6 +85,8 @@ void Path2D::Ctor(const v8::FunctionCallbackInfo<v8::Value> &args) {
|
|
|
87
85
|
|
|
88
86
|
object->BindFinalizer(isolate, ret);
|
|
89
87
|
|
|
88
|
+
SetNativeType(object, NativeType::Path2D);
|
|
89
|
+
|
|
90
90
|
args.GetReturnValue().Set(ret);
|
|
91
91
|
|
|
92
92
|
return;
|
|
@@ -102,6 +102,8 @@ void Path2D::Ctor(const v8::FunctionCallbackInfo<v8::Value> &args) {
|
|
|
102
102
|
|
|
103
103
|
object->BindFinalizer(isolate, ret);
|
|
104
104
|
|
|
105
|
+
SetNativeType(object, NativeType::Path2D);
|
|
106
|
+
|
|
105
107
|
args.GetReturnValue().Set(ret);
|
|
106
108
|
return;
|
|
107
109
|
}
|
|
@@ -109,11 +111,12 @@ void Path2D::Ctor(const v8::FunctionCallbackInfo<v8::Value> &args) {
|
|
|
109
111
|
} else {
|
|
110
112
|
auto path = new Path2D(canvas_native_path_create());
|
|
111
113
|
|
|
112
|
-
|
|
113
114
|
ret->SetAlignedPointerInInternalField(0, path);
|
|
114
115
|
|
|
115
116
|
path->BindFinalizer(isolate, ret);
|
|
116
117
|
|
|
118
|
+
SetNativeType(path, NativeType::Path2D);
|
|
119
|
+
|
|
117
120
|
args.GetReturnValue().Set(ret);
|
|
118
121
|
return;
|
|
119
122
|
|
|
@@ -11,10 +11,10 @@
|
|
|
11
11
|
|
|
12
12
|
class Path2D : ObjectWrapperImpl {
|
|
13
13
|
public:
|
|
14
|
-
Path2D(Path *path);
|
|
14
|
+
explicit Path2D(Path *path);
|
|
15
15
|
|
|
16
16
|
~Path2D() {
|
|
17
|
-
|
|
17
|
+
canvas_native_path_release(this->GetPath());
|
|
18
18
|
this->path_ = nullptr;
|
|
19
19
|
}
|
|
20
20
|
|
|
@@ -10,10 +10,10 @@
|
|
|
10
10
|
|
|
11
11
|
class TextMetricsImpl: public ObjectWrapperImpl {
|
|
12
12
|
public:
|
|
13
|
-
TextMetricsImpl(TextMetrics* metrics);
|
|
14
|
-
|
|
13
|
+
explicit TextMetricsImpl(TextMetrics* metrics);
|
|
14
|
+
|
|
15
15
|
~TextMetricsImpl(){
|
|
16
|
-
|
|
16
|
+
canvas_native_text_metrics_release(this->GetTextMetrics());
|
|
17
17
|
this->metrics_ = nullptr;
|
|
18
18
|
}
|
|
19
19
|
|
|
@@ -25,7 +25,7 @@ public:
|
|
|
25
25
|
v8::EscapableHandleScope scope(isolate);
|
|
26
26
|
auto object = WebGLActiveInfoImpl::GetCtor(isolate)->GetFunction(
|
|
27
27
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
28
|
-
SetNativeType(
|
|
28
|
+
SetNativeType( info, NativeType::WebGLActiveInfo);
|
|
29
29
|
object->SetAlignedPointerInInternalField(0, info);
|
|
30
30
|
info->BindFinalizer(isolate, object);
|
|
31
31
|
return scope.Escape(object);
|
|
@@ -35,7 +35,7 @@ public:
|
|
|
35
35
|
v8::EscapableHandleScope scope(isolate);
|
|
36
36
|
auto object = WebGLBuffer::GetCtor(isolate)->GetFunction(
|
|
37
37
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
38
|
-
SetNativeType(
|
|
38
|
+
SetNativeType( buffer, NativeType::WebGLBuffer);
|
|
39
39
|
object->SetAlignedPointerInInternalField(0, buffer);
|
|
40
40
|
buffer->BindFinalizer(isolate, object);
|
|
41
41
|
return scope.Escape(object);
|
|
@@ -35,7 +35,7 @@ public:
|
|
|
35
35
|
v8::EscapableHandleScope scope(isolate);
|
|
36
36
|
auto object = WebGLFramebuffer::GetCtor(isolate)->GetFunction(
|
|
37
37
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
38
|
-
SetNativeType(
|
|
38
|
+
SetNativeType( buffer, NativeType::WebGLFramebuffer);
|
|
39
39
|
object->SetAlignedPointerInInternalField(0, buffer);
|
|
40
40
|
buffer->BindFinalizer(isolate, object);
|
|
41
41
|
return scope.Escape(object);
|
|
@@ -9,9 +9,9 @@
|
|
|
9
9
|
|
|
10
10
|
class WebGLProgram:ObjectWrapperImpl {
|
|
11
11
|
public:
|
|
12
|
-
WebGLProgram(uint32_t program) : program_(program) {}
|
|
12
|
+
explicit WebGLProgram(uint32_t program) : program_(program) {}
|
|
13
13
|
|
|
14
|
-
uint32_t GetProgram() {
|
|
14
|
+
uint32_t GetProgram() const {
|
|
15
15
|
return this->program_;
|
|
16
16
|
}
|
|
17
17
|
|
|
@@ -39,7 +39,7 @@ public:
|
|
|
39
39
|
v8::EscapableHandleScope scope(isolate);
|
|
40
40
|
auto object = WebGLProgram::GetCtor(isolate)->GetFunction(
|
|
41
41
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
42
|
-
SetNativeType(
|
|
42
|
+
SetNativeType( program, NativeType::WebGLProgram);
|
|
43
43
|
object->SetAlignedPointerInInternalField(0, program);
|
|
44
44
|
program->BindFinalizer(isolate, object);
|
|
45
45
|
return scope.Escape(object);
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
#include "ObjectWrapperImpl.h"
|
|
9
9
|
class WebGLRenderbuffer: ObjectWrapperImpl {
|
|
10
10
|
public:
|
|
11
|
-
WebGLRenderbuffer(uint32_t renderbuffer) : renderbuffer_(renderbuffer) {}
|
|
11
|
+
explicit WebGLRenderbuffer(uint32_t renderbuffer) : renderbuffer_(renderbuffer) {}
|
|
12
12
|
|
|
13
13
|
static v8::Local<v8::FunctionTemplate> GetCtor(v8::Isolate *isolate) {
|
|
14
14
|
auto cache = Caches::Get(isolate);
|
|
@@ -34,7 +34,7 @@ public:
|
|
|
34
34
|
v8::EscapableHandleScope scope(isolate);
|
|
35
35
|
auto object = WebGLRenderbuffer::GetCtor(isolate)->GetFunction(
|
|
36
36
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
37
|
-
SetNativeType(
|
|
37
|
+
SetNativeType( buffer, NativeType::WebGLRenderbuffer);
|
|
38
38
|
object->SetAlignedPointerInInternalField(0, buffer);
|
|
39
39
|
buffer->BindFinalizer(isolate, object);
|
|
40
40
|
return scope.Escape(object);
|
|
@@ -48,7 +48,7 @@ public:
|
|
|
48
48
|
return static_cast<WebGLRenderbuffer *>(ptr);
|
|
49
49
|
}
|
|
50
50
|
|
|
51
|
-
uint32_t GetRenderBuffer() {
|
|
51
|
+
uint32_t GetRenderBuffer() const {
|
|
52
52
|
return this->renderbuffer_;
|
|
53
53
|
}
|
|
54
54
|
|
|
@@ -719,7 +719,7 @@ v8::Local<v8::Value> WebGLRenderingContext::GetParameterInternal(v8::Isolate *is
|
|
|
719
719
|
[](void *data, size_t length,
|
|
720
720
|
void *deleter_data) {
|
|
721
721
|
if (deleter_data != nullptr) {
|
|
722
|
-
|
|
722
|
+
canvas_native_f32_buffer_release(
|
|
723
723
|
(F32Buffer *) deleter_data);
|
|
724
724
|
}
|
|
725
725
|
},
|
|
@@ -773,7 +773,7 @@ v8::Local<v8::Value> WebGLRenderingContext::GetParameterInternal(v8::Isolate *is
|
|
|
773
773
|
[](void *data, size_t length,
|
|
774
774
|
void *deleter_data) {
|
|
775
775
|
if (deleter_data != nullptr) {
|
|
776
|
-
|
|
776
|
+
canvas_native_i32_buffer_release(
|
|
777
777
|
(I32Buffer *) deleter_data);
|
|
778
778
|
}
|
|
779
779
|
},
|
|
@@ -2348,7 +2348,7 @@ void WebGLRenderingContext::GetAttachedShaders(const v8::FunctionCallbackInfo<v8
|
|
|
2348
2348
|
}
|
|
2349
2349
|
args.GetReturnValue().Set(array);
|
|
2350
2350
|
|
|
2351
|
-
|
|
2351
|
+
canvas_native_u32_buffer_release(info);
|
|
2352
2352
|
return;
|
|
2353
2353
|
}
|
|
2354
2354
|
}
|
|
@@ -3126,7 +3126,7 @@ WebGLRenderingContext::GetSupportedExtensions(const v8::FunctionCallbackInfo<v8:
|
|
|
3126
3126
|
|
|
3127
3127
|
args.GetReturnValue().Set(array);
|
|
3128
3128
|
|
|
3129
|
-
|
|
3129
|
+
canvas_native_string_buffer_release(exts);
|
|
3130
3130
|
}
|
|
3131
3131
|
|
|
3132
3132
|
void
|
|
@@ -3291,7 +3291,7 @@ WebGLRenderingContext::GetUniform(const v8::FunctionCallbackInfo<v8::Value> &arg
|
|
|
3291
3291
|
void *deleter_data) {
|
|
3292
3292
|
if (deleter_data !=
|
|
3293
3293
|
nullptr) {
|
|
3294
|
-
|
|
3294
|
+
canvas_native_f32_buffer_release(
|
|
3295
3295
|
(F32Buffer *) deleter_data);
|
|
3296
3296
|
}
|
|
3297
3297
|
},
|
|
@@ -3322,7 +3322,7 @@ WebGLRenderingContext::GetUniform(const v8::FunctionCallbackInfo<v8::Value> &arg
|
|
|
3322
3322
|
void *deleter_data) {
|
|
3323
3323
|
if (deleter_data !=
|
|
3324
3324
|
nullptr) {
|
|
3325
|
-
|
|
3325
|
+
canvas_native_i32_buffer_release(
|
|
3326
3326
|
(I32Buffer *) deleter_data);
|
|
3327
3327
|
}
|
|
3328
3328
|
},
|
|
@@ -3353,7 +3353,7 @@ WebGLRenderingContext::GetUniform(const v8::FunctionCallbackInfo<v8::Value> &arg
|
|
|
3353
3353
|
void *deleter_data) {
|
|
3354
3354
|
if (deleter_data !=
|
|
3355
3355
|
nullptr) {
|
|
3356
|
-
|
|
3356
|
+
canvas_native_u32_buffer_release(
|
|
3357
3357
|
(U32Buffer *) deleter_data);
|
|
3358
3358
|
}
|
|
3359
3359
|
},
|
|
@@ -3456,7 +3456,7 @@ WebGLRenderingContext::GetVertexAttrib(const v8::FunctionCallbackInfo<v8::Value>
|
|
|
3456
3456
|
[](void *data, size_t length,
|
|
3457
3457
|
void *deleter_data) {
|
|
3458
3458
|
if (deleter_data != nullptr) {
|
|
3459
|
-
|
|
3459
|
+
canvas_native_f32_buffer_release(
|
|
3460
3460
|
(F32Buffer *) deleter_data);
|
|
3461
3461
|
}
|
|
3462
3462
|
},
|
|
@@ -301,7 +301,7 @@ public:
|
|
|
301
301
|
v8::EscapableHandleScope scope(isolate);
|
|
302
302
|
auto object = WebGLRenderingContext::GetCtor(isolate)->GetFunction(
|
|
303
303
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
304
|
-
SetNativeType(
|
|
304
|
+
SetNativeType(renderingContext, NativeType::WebGLRenderingContextBase);
|
|
305
305
|
object->SetAlignedPointerInInternalField(0, renderingContext);
|
|
306
306
|
renderingContext->BindFinalizer(isolate, object);
|
|
307
307
|
return scope.Escape(object);
|
|
@@ -142,7 +142,7 @@ WebGLRenderingContextBase::~WebGLRenderingContextBase() {
|
|
|
142
142
|
canvas_native_raf_stop(
|
|
143
143
|
_raf->GetRaf());
|
|
144
144
|
}
|
|
145
|
-
|
|
145
|
+
canvas_native_raf_release(_raf->GetRaf());
|
|
146
146
|
this->raf_ = nullptr;
|
|
147
147
|
canvas_native_webgl_state_destroy(this->GetState());
|
|
148
148
|
this->state_ = nullptr;
|
|
@@ -34,7 +34,7 @@ public:
|
|
|
34
34
|
v8::EscapableHandleScope scope(isolate);
|
|
35
35
|
auto object = WebGLShader::GetCtor(isolate)->GetFunction(
|
|
36
36
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
37
|
-
SetNativeType(
|
|
37
|
+
SetNativeType( shader, NativeType::WebGLShader);
|
|
38
38
|
object->SetAlignedPointerInInternalField(0, shader);
|
|
39
39
|
shader->BindFinalizer(isolate, object);
|
|
40
40
|
return scope.Escape(object);
|
|
@@ -10,9 +10,9 @@
|
|
|
10
10
|
#include "Common.h"
|
|
11
11
|
#include "ObjectWrapperImpl.h"
|
|
12
12
|
|
|
13
|
-
class WebGLShaderPrecisionFormatImpl: ObjectWrapperImpl {
|
|
13
|
+
class WebGLShaderPrecisionFormatImpl : ObjectWrapperImpl {
|
|
14
14
|
public:
|
|
15
|
-
WebGLShaderPrecisionFormatImpl(WebGLShaderPrecisionFormat*
|
|
15
|
+
explicit WebGLShaderPrecisionFormatImpl(WebGLShaderPrecisionFormat *shader);
|
|
16
16
|
|
|
17
17
|
~WebGLShaderPrecisionFormatImpl() {
|
|
18
18
|
canvas_native_webgl_shader_precision_format_destroy(this->GetShaderPrecisionFormat());
|
|
@@ -51,7 +51,7 @@ public:
|
|
|
51
51
|
v8::EscapableHandleScope scope(isolate);
|
|
52
52
|
auto object = WebGLShaderPrecisionFormatImpl::GetCtor(isolate)->GetFunction(
|
|
53
53
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
54
|
-
SetNativeType(
|
|
54
|
+
SetNativeType(shaderPrecisionFormat, NativeType::WebGLShaderPrecisionFormat);
|
|
55
55
|
object->SetAlignedPointerInInternalField(0, shaderPrecisionFormat);
|
|
56
56
|
shaderPrecisionFormat->BindFinalizer(isolate, object);
|
|
57
57
|
return scope.Escape(object);
|
|
@@ -75,9 +75,9 @@ public:
|
|
|
75
75
|
static void GetPrecision(v8::Local<v8::Name> property,
|
|
76
76
|
const v8::PropertyCallbackInfo<v8::Value> &info);
|
|
77
77
|
|
|
78
|
-
WebGLShaderPrecisionFormat*
|
|
78
|
+
WebGLShaderPrecisionFormat *GetShaderPrecisionFormat();
|
|
79
79
|
|
|
80
80
|
private:
|
|
81
|
-
WebGLShaderPrecisionFormat*
|
|
81
|
+
WebGLShaderPrecisionFormat *shader_;
|
|
82
82
|
};
|
|
83
83
|
|
|
@@ -6,7 +6,8 @@
|
|
|
6
6
|
|
|
7
7
|
#include "Helpers.h"
|
|
8
8
|
#include "ObjectWrapperImpl.h"
|
|
9
|
-
|
|
9
|
+
|
|
10
|
+
class WebGLTexture : ObjectWrapperImpl {
|
|
10
11
|
public:
|
|
11
12
|
WebGLTexture(uint32_t texture) : texture_(texture) {}
|
|
12
13
|
|
|
@@ -34,7 +35,7 @@ public:
|
|
|
34
35
|
v8::EscapableHandleScope scope(isolate);
|
|
35
36
|
auto object = WebGLTexture::GetCtor(isolate)->GetFunction(
|
|
36
37
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
37
|
-
SetNativeType(
|
|
38
|
+
SetNativeType(texture, NativeType::WebGLTexture);
|
|
38
39
|
object->SetAlignedPointerInInternalField(0, texture);
|
|
39
40
|
texture->BindFinalizer(isolate, object);
|
|
40
41
|
return scope.Escape(object);
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
#include "Caches.h"
|
|
10
10
|
#include "ObjectWrapperImpl.h"
|
|
11
11
|
|
|
12
|
-
class WebGLUniformLocation: ObjectWrapperImpl {
|
|
12
|
+
class WebGLUniformLocation : ObjectWrapperImpl {
|
|
13
13
|
public:
|
|
14
14
|
WebGLUniformLocation(int32_t
|
|
15
15
|
uniformLocation) :
|
|
@@ -41,7 +41,7 @@ public:
|
|
|
41
41
|
v8::EscapableHandleScope scope(isolate);
|
|
42
42
|
auto object = WebGLUniformLocation::GetCtor(isolate)->GetFunction(
|
|
43
43
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
44
|
-
SetNativeType(
|
|
44
|
+
SetNativeType(uniformLocation, NativeType::WebGLUniformLocation);
|
|
45
45
|
object->SetAlignedPointerInInternalField(0, uniformLocation);
|
|
46
46
|
uniformLocation->BindFinalizer(isolate, object);
|
|
47
47
|
return scope.Escape(object);
|
|
@@ -30,7 +30,7 @@ public:
|
|
|
30
30
|
v8::EscapableHandleScope scope(isolate);
|
|
31
31
|
auto object = ANGLE_instanced_arraysImpl::GetCtor(isolate)->GetFunction(
|
|
32
32
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
33
|
-
SetNativeType(
|
|
33
|
+
SetNativeType(arrays, NativeType::ANGLE_instanced_arrays);
|
|
34
34
|
object->SetAlignedPointerInInternalField(0, arrays);
|
|
35
35
|
arrays->BindFinalizer(isolate, object);
|
|
36
36
|
return scope.Escape(object);
|
|
@@ -18,7 +18,7 @@ public:
|
|
|
18
18
|
v8::EscapableHandleScope scope(isolate);
|
|
19
19
|
auto object = EXT_blend_minmaxImpl::GetCtor(isolate)->GetFunction(
|
|
20
20
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
21
|
-
SetNativeType(
|
|
21
|
+
SetNativeType( minmax, NativeType::EXT_blend_minmax);
|
|
22
22
|
object->SetAlignedPointerInInternalField(0, minmax);
|
|
23
23
|
object->Set(context, ConvertToV8String(isolate, "ext_name"),
|
|
24
24
|
ConvertToV8String(isolate, "EXT_blend_minmax"));
|
|
@@ -18,7 +18,7 @@ public:
|
|
|
18
18
|
v8::EscapableHandleScope scope(isolate);
|
|
19
19
|
auto object = EXT_color_buffer_half_floatImpl::GetCtor(isolate)->GetFunction(
|
|
20
20
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
21
|
-
SetNativeType(
|
|
21
|
+
SetNativeType( buffer, NativeType::EXT_color_buffer_half_float);
|
|
22
22
|
object->SetAlignedPointerInInternalField(0, buffer);
|
|
23
23
|
object->Set(context, ConvertToV8String(isolate, "ext_name"),
|
|
24
24
|
ConvertToV8String(isolate, "EXT_color_buffer_half_float"));
|
|
@@ -28,7 +28,7 @@ public:
|
|
|
28
28
|
v8::EscapableHandleScope scope(isolate);
|
|
29
29
|
auto object = EXT_disjoint_timer_queryImpl::GetCtor(isolate)->GetFunction(
|
|
30
30
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
31
|
-
SetNativeType(
|
|
31
|
+
SetNativeType( query, NativeType::EXT_disjoint_timer_query);
|
|
32
32
|
object->SetAlignedPointerInInternalField(0, query);
|
|
33
33
|
object->Set(context, ConvertToV8String(isolate, "ext_name"),
|
|
34
34
|
ConvertToV8String(isolate, "EXT_disjoint_timer_query"));
|
|
@@ -45,7 +45,7 @@ public:
|
|
|
45
45
|
v8::EscapableHandleScope scope(isolate);
|
|
46
46
|
auto object = EXT_sRGBImpl::GetCtor(isolate)->GetFunction(
|
|
47
47
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
48
|
-
SetNativeType(
|
|
48
|
+
SetNativeType( extSrgb, NativeType::EXT_sRGB);
|
|
49
49
|
object->SetAlignedPointerInInternalField(0, extSrgb);
|
|
50
50
|
extSrgb->BindFinalizer(isolate, object);
|
|
51
51
|
return scope.Escape(object);
|
|
@@ -35,7 +35,7 @@ public:
|
|
|
35
35
|
v8::EscapableHandleScope scope(isolate);
|
|
36
36
|
auto object = EXT_shader_texture_lodImpl::GetCtor(isolate)->GetFunction(
|
|
37
37
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
38
|
-
SetNativeType(
|
|
38
|
+
SetNativeType( texture, NativeType::EXT_shader_texture_lod);
|
|
39
39
|
object->SetAlignedPointerInInternalField(0, texture);
|
|
40
40
|
texture->BindFinalizer(isolate, object);
|
|
41
41
|
return scope.Escape(object);
|
|
@@ -43,7 +43,7 @@ public:
|
|
|
43
43
|
v8::EscapableHandleScope scope(isolate);
|
|
44
44
|
auto object = EXT_texture_filter_anisotropicImpl::GetCtor(isolate)->GetFunction(
|
|
45
45
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
46
|
-
SetNativeType(
|
|
46
|
+
SetNativeType( filterAnisotropic, NativeType::EXT_texture_filter_anisotropic);
|
|
47
47
|
object->SetAlignedPointerInInternalField(0, filterAnisotropic);
|
|
48
48
|
filterAnisotropic->BindFinalizer(isolate, object);
|
|
49
49
|
return scope.Escape(object);
|
|
@@ -43,10 +43,10 @@ public:
|
|
|
43
43
|
v8::EscapableHandleScope scope(isolate);
|
|
44
44
|
auto object = OES_element_index_uintImpl::GetCtor(isolate)->GetFunction(
|
|
45
45
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
46
|
-
SetNativeType(
|
|
46
|
+
SetNativeType( element, NativeType::OES_element_index_uint);
|
|
47
47
|
object->SetAlignedPointerInInternalField(0, element);
|
|
48
48
|
object->Set(context, ConvertToV8String(isolate, "ext_name"),
|
|
49
|
-
ConvertToV8String(isolate, "OES_element_index_uint"));
|
|
49
|
+
ConvertToV8String(isolate, "OES_element_index_uint")).FromJust();
|
|
50
50
|
element->BindFinalizer(isolate, object);
|
|
51
51
|
return scope.Escape(object);
|
|
52
52
|
}
|
|
@@ -32,16 +32,16 @@ public:
|
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
static v8::Local<v8::Object>
|
|
35
|
-
NewInstance(v8::Isolate *isolate, OES_fbo_render_mipmapImpl *
|
|
35
|
+
NewInstance(v8::Isolate *isolate, OES_fbo_render_mipmapImpl *mipmap) {
|
|
36
36
|
auto context = isolate->GetCurrentContext();
|
|
37
37
|
v8::EscapableHandleScope scope(isolate);
|
|
38
38
|
auto object = OES_fbo_render_mipmapImpl::GetCtor(isolate)->GetFunction(
|
|
39
39
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
40
|
-
SetNativeType(
|
|
41
|
-
object->SetAlignedPointerInInternalField(0,
|
|
40
|
+
SetNativeType( mipmap, NativeType::OES_fbo_render_mipmap);
|
|
41
|
+
object->SetAlignedPointerInInternalField(0, mipmap);
|
|
42
42
|
object->Set(context, ConvertToV8String(isolate, "ext_name"),
|
|
43
|
-
ConvertToV8String(isolate, "OES_fbo_render_mipmap"));
|
|
44
|
-
|
|
43
|
+
ConvertToV8String(isolate, "OES_fbo_render_mipmap")).FromJust();
|
|
44
|
+
mipmap->BindFinalizer(isolate, object);
|
|
45
45
|
return scope.Escape(object);
|
|
46
46
|
}
|
|
47
47
|
|
|
@@ -40,7 +40,7 @@ public:
|
|
|
40
40
|
v8::EscapableHandleScope scope(isolate);
|
|
41
41
|
auto object = OES_standard_derivativesImpl::GetCtor(isolate)->GetFunction(
|
|
42
42
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
43
|
-
SetNativeType(
|
|
43
|
+
SetNativeType( derivatives, NativeType::OES_standard_derivatives);
|
|
44
44
|
object->SetAlignedPointerInInternalField(0, derivatives);
|
|
45
45
|
derivatives->BindFinalizer(isolate, object);
|
|
46
46
|
return scope.Escape(object);
|
|
@@ -36,7 +36,7 @@ public:
|
|
|
36
36
|
v8::EscapableHandleScope scope(isolate);
|
|
37
37
|
auto object = WebGLShader::GetCtor(isolate)->GetFunction(
|
|
38
38
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
39
|
-
SetNativeType(
|
|
39
|
+
SetNativeType( texture, NativeType::OES_texture_float);
|
|
40
40
|
object->SetAlignedPointerInInternalField(0, texture);
|
|
41
41
|
texture->BindFinalizer(isolate, object);
|
|
42
42
|
return scope.Escape(object);
|
|
@@ -35,7 +35,7 @@ public:
|
|
|
35
35
|
v8::EscapableHandleScope scope(isolate);
|
|
36
36
|
auto object = OES_texture_float_linearImpl::GetCtor(isolate)->GetFunction(
|
|
37
37
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
38
|
-
SetNativeType(
|
|
38
|
+
SetNativeType( texture, NativeType::OES_texture_float_linear);
|
|
39
39
|
object->SetAlignedPointerInInternalField(0, texture);
|
|
40
40
|
texture->BindFinalizer(isolate, object);
|
|
41
41
|
return scope.Escape(object);
|
|
@@ -38,7 +38,7 @@ public:
|
|
|
38
38
|
v8::EscapableHandleScope scope(isolate);
|
|
39
39
|
auto object = OES_texture_half_floatImpl::GetCtor(isolate)->GetFunction(
|
|
40
40
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
41
|
-
SetNativeType(
|
|
41
|
+
SetNativeType( texture, NativeType::OES_texture_half_float);
|
|
42
42
|
object->SetAlignedPointerInInternalField(0, texture);
|
|
43
43
|
texture->BindFinalizer(isolate, object);
|
|
44
44
|
return scope.Escape(object);
|
|
@@ -38,7 +38,7 @@ public:
|
|
|
38
38
|
v8::EscapableHandleScope scope(isolate);
|
|
39
39
|
auto object = OES_texture_half_float_linearImpl::GetCtor(isolate)->GetFunction(
|
|
40
40
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
41
|
-
SetNativeType(
|
|
41
|
+
SetNativeType( texture, NativeType::OES_texture_half_float_linear);
|
|
42
42
|
object->SetAlignedPointerInInternalField(0, texture);
|
|
43
43
|
texture->BindFinalizer(isolate, object);
|
|
44
44
|
return scope.Escape(object);
|
|
@@ -71,7 +71,7 @@ public:
|
|
|
71
71
|
v8::EscapableHandleScope scope(isolate);
|
|
72
72
|
auto object = OES_vertex_array_objectImpl::GetCtor(isolate)->GetFunction(
|
|
73
73
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
74
|
-
SetNativeType(
|
|
74
|
+
SetNativeType(vertexArrayObject, NativeType::OES_vertex_array_object);
|
|
75
75
|
object->SetAlignedPointerInInternalField(0, vertexArrayObject);
|
|
76
76
|
vertexArrayObject->BindFinalizer(isolate, object);
|
|
77
77
|
return scope.Escape(object);
|
|
@@ -47,7 +47,7 @@ public:
|
|
|
47
47
|
v8::EscapableHandleScope scope(isolate);
|
|
48
48
|
auto object = WEBGL_color_buffer_floatImpl::GetCtor(isolate)->GetFunction(
|
|
49
49
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
50
|
-
SetNativeType(
|
|
50
|
+
SetNativeType( buffer, NativeType::WEBGL_color_buffer_float);
|
|
51
51
|
object->SetAlignedPointerInInternalField(0, buffer);
|
|
52
52
|
buffer->BindFinalizer(isolate, object);
|
|
53
53
|
return scope.Escape(object);
|
|
@@ -45,7 +45,7 @@ public:
|
|
|
45
45
|
v8::EscapableHandleScope scope(isolate);
|
|
46
46
|
auto object = WEBGL_compressed_texture_atcImpl::GetCtor(isolate)->GetFunction(
|
|
47
47
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
48
|
-
SetNativeType(
|
|
48
|
+
SetNativeType( compressedTextureAtc, NativeType::WEBGL_compressed_texture_atc);
|
|
49
49
|
object->SetAlignedPointerInInternalField(0, compressedTextureAtc);
|
|
50
50
|
compressedTextureAtc->BindFinalizer(isolate, object);
|
|
51
51
|
return scope.Escape(object);
|
|
@@ -43,7 +43,7 @@ public:
|
|
|
43
43
|
v8::EscapableHandleScope scope(isolate);
|
|
44
44
|
auto object = WEBGL_compressed_texture_etc1Impl::GetCtor(isolate)->GetFunction(
|
|
45
45
|
context).ToLocalChecked()->NewInstance(context).ToLocalChecked();
|
|
46
|
-
SetNativeType(
|
|
46
|
+
SetNativeType( compressedTextureEtc1, NativeType::WEBGL_compressed_texture_etc1);
|
|
47
47
|
object->SetAlignedPointerInInternalField(0, compressedTextureEtc1);
|
|
48
48
|
compressedTextureEtc1->BindFinalizer(isolate, object);
|
|
49
49
|
return scope.Escape(object);
|