@nativescript/canvas 2.0.0-webgpu.5 → 2.0.0-webgpu.7

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.
Files changed (53) hide show
  1. package/Canvas/index.android.d.ts +0 -1
  2. package/Canvas/index.android.js +21 -22
  3. package/Canvas/index.android.js.map +1 -1
  4. package/Canvas/index.ios.js +13 -26
  5. package/Canvas/index.ios.js.map +1 -1
  6. package/Dom/Group.d.ts +1 -2
  7. package/Dom/Group.js.map +1 -1
  8. package/Dom/Image.js +0 -1
  9. package/Dom/Image.js.map +1 -1
  10. package/WebGPU/GPUAdapter.d.ts +3 -2
  11. package/WebGPU/GPUAdapter.js.map +1 -1
  12. package/WebGPU/GPUDevice.d.ts +2 -2
  13. package/WebGPU/GPUDevice.js +26 -6
  14. package/WebGPU/GPUDevice.js.map +1 -1
  15. package/WebGPU/GPURenderPassEncoder.d.ts +1 -1
  16. package/WebGPU/GPURenderPassEncoder.js +2 -2
  17. package/WebGPU/GPURenderPassEncoder.js.map +1 -1
  18. package/WebGPU/Interfaces.d.ts +11 -1
  19. package/WebGPU/Types.d.ts +1 -0
  20. package/package.json +1 -1
  21. package/platforms/android/canvas-release.aar +0 -0
  22. package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/CanvasNative +0 -0
  23. package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Headers/CanvasNative-Swift.h +5 -0
  24. package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Modules/CanvasNative.swiftmodule/Project/arm64-apple-ios.swiftsourceinfo +0 -0
  25. package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios.abi.json +108 -0
  26. package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios.private.swiftinterface +3 -0
  27. package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios.swiftinterface +3 -0
  28. package/platforms/ios/CanvasNative.xcframework/ios-arm64/dSYMs/CanvasNative.framework.dSYM/Contents/Resources/DWARF/CanvasNative +0 -0
  29. package/platforms/ios/CanvasNative.xcframework/ios-arm64/dSYMs/CanvasNative.framework.dSYM/Contents/Resources/Relocations/aarch64/CanvasNative.yml +484 -483
  30. package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/CanvasNative +0 -0
  31. package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Headers/CanvasNative-Swift.h +10 -0
  32. package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/Project/arm64-apple-ios-simulator.swiftsourceinfo +0 -0
  33. package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/Project/x86_64-apple-ios-simulator.swiftsourceinfo +0 -0
  34. package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios-simulator.abi.json +108 -0
  35. package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios-simulator.private.swiftinterface +3 -0
  36. package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios-simulator.swiftinterface +3 -0
  37. package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/x86_64-apple-ios-simulator.abi.json +108 -0
  38. package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/x86_64-apple-ios-simulator.private.swiftinterface +3 -0
  39. package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/x86_64-apple-ios-simulator.swiftinterface +3 -0
  40. package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/_CodeSignature/CodeResources +22 -22
  41. package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/dSYMs/CanvasNative.framework.dSYM/Contents/Resources/DWARF/CanvasNative +0 -0
  42. package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/dSYMs/CanvasNative.framework.dSYM/Contents/Resources/Relocations/aarch64/CanvasNative.yml +645 -644
  43. package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/dSYMs/CanvasNative.framework.dSYM/Contents/Resources/Relocations/x86_64/CanvasNative.yml +683 -682
  44. package/platforms/ios/src/cpp/canvas2d/CanvasRenderingContext2DImpl.cpp +1 -1
  45. package/platforms/ios/src/cpp/canvas2d/Path2D.h +5 -5
  46. package/platforms/ios/src/cpp/webgpu/GPUAdapterImpl.cpp +19 -17
  47. package/platforms/ios/src/cpp/webgpu/GPUBindGroupImpl.h +1 -1
  48. package/platforms/ios/src/cpp/webgpu/GPUDeviceImpl.cpp +1401 -6
  49. package/platforms/ios/src/cpp/webgpu/GPUImpl.h +1 -1
  50. package/platforms/ios/src/cpp/webgpu/GPUPipelineLayoutImpl.h +1 -1
  51. package/platforms/ios/src/cpp/webgpu/GPUQuerySetImpl.h +1 -1
  52. package/platforms/ios/src/cpp/webgpu/GPUQueueImpl.cpp +0 -1
  53. package/platforms/ios/src/cpp/webgpu/GPURenderPassEncoderImpl.cpp +3 -3
@@ -3,7 +3,7 @@ import type { GPUQuerySet } from './GPUQuerySet';
3
3
  import type { GPUShaderModule } from './GPUShaderModule';
4
4
  import type { GPUTexture } from './GPUTexture';
5
5
  import type { GPUTextureView } from './GPUTextureView';
6
- import type { GPUBlendFactor, GPUBlendOperation, GPUColor, GPUCompareFunction, GPUCullMode, GPUFrontFace, GPUIndexFormat, GPULoadOp, GPUOrigin2D, GPUOrigin3D, GPUPrimitiveTopology, GPUStencilOperation, GPUStoreOp, GPUTextureAspect, GPUTextureFormat, GPUTextureViewDimension, GPUVertexFormat, GPUVertexStepMode } from './Types';
6
+ import type { GPUBlendFactor, GPUBlendOperation, GPUColor, GPUCompareFunction, GPUCullMode, GPUFeatureName, GPUFrontFace, GPUIndexFormat, GPULoadOp, GPUOrigin2D, GPUOrigin3D, GPUPrimitiveTopology, GPUStencilOperation, GPUStoreOp, GPUTextureAspect, GPUTextureFormat, GPUTextureViewDimension, GPUVertexFormat, GPUVertexStepMode } from './Types';
7
7
  export interface GPUExternalTextureBindingLayout {
8
8
  }
9
9
  export interface GPUProgrammableStage {
@@ -153,3 +153,13 @@ export interface GPUTextureViewDescriptor {
153
153
  label?: string;
154
154
  mipLevelCount?: number;
155
155
  }
156
+ export interface GPUDeviceDescriptor {
157
+ defaultQueue?: {
158
+ label?: string;
159
+ };
160
+ label?: string;
161
+ requiredFeatures?: GPUFeatureName[];
162
+ requiredLimits?: {
163
+ [name: string]: number;
164
+ };
165
+ }
package/WebGPU/Types.d.ts CHANGED
@@ -37,3 +37,4 @@ export type GPUTextureFormat = 'r8unorm' | 'r8snorm' | 'r8uint' | 'r8sint' | 'r1
37
37
  export type GPUVertexFormat = 'uint8x2' | 'uint8x4' | 'sint8x2' | 'sint8x4' | 'unorm8x2' | 'unorm8x4' | 'snorm8x2' | 'snorm8x4' | 'uint16x2' | 'uint16x4' | 'sint16x2' | 'sint16x4' | 'unorm16x2' | 'unorm16x4' | 'snorm16x2' | 'snorm16x4' | 'float16x2' | 'float16x4' | 'float32' | 'float32x2' | 'float32x3' | 'float32x4' | 'uint32' | 'uint32x2' | 'uint32x3' | 'uint32x4' | 'sint32' | 'sint32x2' | 'sint32x3' | 'sint32x4' | 'unorm10-10-10-2';
38
38
  export type GPUCanvasAlphaMode = 'opaque' | 'premultiplied' | 'postmultiplied' | 'inherit';
39
39
  export type GPUCanvasPresentMode = 'autoVsync' | 'autoNoVsync' | 'fifo' | 'fifoRelaxed' | 'immediate' | 'mailbox';
40
+ export type GPUFeatureName = 'depth-clip-control' | 'depth32float-stencil8' | 'texture-compression-bc' | 'texture-compression-etc2' | 'texture-compression-astc' | 'timestamp-query' | 'indirect-first-instance' | 'shader-f16' | 'rg11b10ufloat-renderable' | 'bgra8unorm-storage' | 'float32-filterable';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nativescript/canvas",
3
- "version": "2.0.0-webgpu.5",
3
+ "version": "2.0.0-webgpu.7",
4
4
  "description": "DOM Canvas API for NativeScript",
5
5
  "main": "index",
6
6
  "typings": "index.d.ts",
@@ -474,6 +474,11 @@ SWIFT_CLASS_NAMED("NSCWebGLRenderingContext")
474
474
  - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
475
475
  @end
476
476
 
477
+
478
+ @interface UIView (SWIFT_EXTENSION(CanvasNative))
479
+ - (void)getBoundingClientRect:(void * _Nonnull)buffer;
480
+ @end
481
+
477
482
  @class AVPlayer;
478
483
  @class AVPlayerItemVideoOutput;
479
484
 
@@ -5510,6 +5510,114 @@
5510
5510
  }
5511
5511
  ]
5512
5512
  },
5513
+ {
5514
+ "kind": "TypeDecl",
5515
+ "name": "UIView",
5516
+ "printedName": "UIView",
5517
+ "children": [
5518
+ {
5519
+ "kind": "Function",
5520
+ "name": "getBoundingClientRect",
5521
+ "printedName": "getBoundingClientRect(_:)",
5522
+ "children": [
5523
+ {
5524
+ "kind": "TypeNominal",
5525
+ "name": "Void",
5526
+ "printedName": "()"
5527
+ },
5528
+ {
5529
+ "kind": "TypeNominal",
5530
+ "name": "UnsafeMutableRawPointer",
5531
+ "printedName": "Swift.UnsafeMutableRawPointer",
5532
+ "usr": "s:Sv"
5533
+ }
5534
+ ],
5535
+ "declKind": "Func",
5536
+ "usr": "c:@CM@CanvasNative@@objc(cs)UIView(im)getBoundingClientRect:",
5537
+ "mangledName": "$sSo6UIViewC12CanvasNativeE21getBoundingClientRectyySvF",
5538
+ "moduleName": "CanvasNative",
5539
+ "declAttributes": ["Dynamic", "Custom", "AccessControl", "ObjC"],
5540
+ "isFromExtension": true,
5541
+ "funcSelfKind": "NonMutating"
5542
+ }
5543
+ ],
5544
+ "declKind": "Class",
5545
+ "usr": "c:objc(cs)UIView",
5546
+ "moduleName": "UIKit",
5547
+ "isOpen": true,
5548
+ "intro_iOS": "2.0",
5549
+ "objc_name": "UIView",
5550
+ "declAttributes": ["Available", "ObjC", "NonSendable", "Custom", "Dynamic"],
5551
+ "superclassUsr": "c:objc(cs)UIResponder",
5552
+ "isExternal": true,
5553
+ "inheritsConvenienceInitializers": true,
5554
+ "superclassNames": ["UIKit.UIResponder", "ObjectiveC.NSObject"],
5555
+ "conformances": [
5556
+ {
5557
+ "kind": "Conformance",
5558
+ "name": "Equatable",
5559
+ "printedName": "Equatable",
5560
+ "usr": "s:SQ",
5561
+ "mangledName": "$sSQ"
5562
+ },
5563
+ {
5564
+ "kind": "Conformance",
5565
+ "name": "Hashable",
5566
+ "printedName": "Hashable",
5567
+ "usr": "s:SH",
5568
+ "mangledName": "$sSH"
5569
+ },
5570
+ {
5571
+ "kind": "Conformance",
5572
+ "name": "CVarArg",
5573
+ "printedName": "CVarArg",
5574
+ "usr": "s:s7CVarArgP",
5575
+ "mangledName": "$ss7CVarArgP"
5576
+ },
5577
+ {
5578
+ "kind": "Conformance",
5579
+ "name": "_KeyValueCodingAndObservingPublishing",
5580
+ "printedName": "_KeyValueCodingAndObservingPublishing",
5581
+ "usr": "s:10Foundation37_KeyValueCodingAndObservingPublishingP",
5582
+ "mangledName": "$s10Foundation37_KeyValueCodingAndObservingPublishingP"
5583
+ },
5584
+ {
5585
+ "kind": "Conformance",
5586
+ "name": "_KeyValueCodingAndObserving",
5587
+ "printedName": "_KeyValueCodingAndObserving",
5588
+ "usr": "s:10Foundation27_KeyValueCodingAndObservingP",
5589
+ "mangledName": "$s10Foundation27_KeyValueCodingAndObservingP"
5590
+ },
5591
+ {
5592
+ "kind": "Conformance",
5593
+ "name": "CustomStringConvertible",
5594
+ "printedName": "CustomStringConvertible",
5595
+ "usr": "s:s23CustomStringConvertibleP",
5596
+ "mangledName": "$ss23CustomStringConvertibleP"
5597
+ },
5598
+ {
5599
+ "kind": "Conformance",
5600
+ "name": "CustomDebugStringConvertible",
5601
+ "printedName": "CustomDebugStringConvertible",
5602
+ "usr": "s:s28CustomDebugStringConvertibleP",
5603
+ "mangledName": "$ss28CustomDebugStringConvertibleP"
5604
+ },
5605
+ {
5606
+ "kind": "Conformance",
5607
+ "name": "UITraitChangeObservable",
5608
+ "printedName": "UITraitChangeObservable",
5609
+ "usr": "s:5UIKit23UITraitChangeObservableP",
5610
+ "mangledName": "$s5UIKit23UITraitChangeObservableP"
5611
+ },
5612
+ {
5613
+ "kind": "Conformance",
5614
+ "name": "__DefaultCustomPlaygroundQuickLookable",
5615
+ "printedName": "__DefaultCustomPlaygroundQuickLookable",
5616
+ "usr": "s:s38__DefaultCustomPlaygroundQuickLookableP",
5617
+ "mangledName": "$ss38__DefaultCustomPlaygroundQuickLookableP"
5618
+ }
5619
+ ]
5620
+ },
5513
5621
  {
5514
5622
  "kind": "TypeDecl",
5515
5623
  "name": "GLKView",
@@ -115,6 +115,9 @@ import _SwiftConcurrencyShims
115
115
  @objc deinit
116
116
  @objc @_Concurrency.MainActor(unsafe) public static func getBoundingClientRect(_ view: UIKit.UIView, _ buffer: Swift.UnsafeMutableRawPointer)
117
117
  }
118
+ extension UIKit.UIView {
119
+ @objc @_Concurrency.MainActor(unsafe) dynamic public func getBoundingClientRect(_ buffer: Swift.UnsafeMutableRawPointer)
120
+ }
118
121
  @_inheritsConvenienceInitializers @objcMembers @objc(NSCRender) public class NSCRender : ObjectiveC.NSObject {
119
122
  @objc override dynamic public init()
120
123
  @objc public func texImage2D(_ target: Swift.Int32, _ level: Swift.Int32, _ internalFormat: Swift.Int32, _ format: Swift.Int32, _ type: Swift.Int32, _ source: CanvasNative.NSCCanvas, _ dest: CanvasNative.NSCCanvas, _ flipYWebGL: Swift.Bool)
@@ -115,6 +115,9 @@ import _SwiftConcurrencyShims
115
115
  @objc deinit
116
116
  @objc @_Concurrency.MainActor(unsafe) public static func getBoundingClientRect(_ view: UIKit.UIView, _ buffer: Swift.UnsafeMutableRawPointer)
117
117
  }
118
+ extension UIKit.UIView {
119
+ @objc @_Concurrency.MainActor(unsafe) dynamic public func getBoundingClientRect(_ buffer: Swift.UnsafeMutableRawPointer)
120
+ }
118
121
  @_inheritsConvenienceInitializers @objcMembers @objc(NSCRender) public class NSCRender : ObjectiveC.NSObject {
119
122
  @objc override dynamic public init()
120
123
  @objc public func texImage2D(_ target: Swift.Int32, _ level: Swift.Int32, _ internalFormat: Swift.Int32, _ format: Swift.Int32, _ type: Swift.Int32, _ source: CanvasNative.NSCCanvas, _ dest: CanvasNative.NSCCanvas, _ flipYWebGL: Swift.Bool)