@nativescript/canvas 2.0.0-webgpu.31 → 2.0.0-webgpu.34
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/index.android.d.ts +6 -4
- package/Canvas/index.android.js +21 -7
- package/Canvas/index.android.js.map +1 -1
- package/Canvas/index.d.ts +2 -0
- package/Canvas/index.ios.d.ts +2 -0
- package/Canvas/index.ios.js +22 -20
- package/Canvas/index.ios.js.map +1 -1
- package/Canvas/utils.js +2 -2
- package/Canvas/utils.js.map +1 -1
- package/WebGL2/WebGL2RenderingContext/index.js.map +1 -1
- package/WebGPU/GPUDevice.js +17 -18
- package/WebGPU/GPUDevice.js.map +1 -1
- package/index.d.ts +1 -1
- package/index.js +2 -2
- package/index.js.map +1 -1
- package/package.json +1 -1
- package/platforms/android/canvas-release.aar +0 -0
- 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 -19
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Headers/CanvasNative.h +1 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Headers/NSCMTLView.h +32 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Headers/canvas_ios.h +143 -182
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Headers/canvas_native.h +30 -10
- 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 +380 -519
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios.private.swiftinterface +20 -20
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios.swiftinterface +20 -20
- 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 +675 -650
- 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 -38
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Headers/CanvasNative.h +1 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Headers/NSCMTLView.h +32 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Headers/canvas_ios.h +143 -182
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Headers/canvas_native.h +30 -10
- 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 +380 -519
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios-simulator.private.swiftinterface +20 -20
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios-simulator.swiftinterface +20 -20
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/x86_64-apple-ios-simulator.abi.json +380 -519
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/x86_64-apple-ios-simulator.private.swiftinterface +20 -20
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/x86_64-apple-ios-simulator.swiftinterface +20 -20
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/_CodeSignature/CodeResources +39 -28
- 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 +677 -652
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/dSYMs/CanvasNative.framework.dSYM/Contents/Resources/Relocations/x86_64/CanvasNative.yml +730 -704
- package/platforms/ios/src/cpp/CanvasJSIModule.cpp +17 -55
- package/platforms/ios/src/cpp/canvas2d/CanvasRenderingContext2DImpl.cpp +6 -10
- package/platforms/ios/src/cpp/webgl/WebGLRenderingContextBase.cpp +5 -5
- package/platforms/ios/src/cpp/webgpu/GPUDeviceImpl.cpp +33 -33
- package/utils.d.ts +1 -1
|
Binary file
|
|
@@ -346,23 +346,20 @@ SWIFT_CLASS_NAMED("CanvasHelpers")
|
|
|
346
346
|
+ (BOOL)drawImageWithContext:(int64_t)context image:(UIImage * _Nonnull)image dx:(float)dx dy:(float)dy SWIFT_WARN_UNUSED_RESULT;
|
|
347
347
|
+ (BOOL)drawImageWithContext:(int64_t)context image:(UIImage * _Nonnull)image dx:(float)dx dy:(float)dy dw:(float)dw dh:(float)dh SWIFT_WARN_UNUSED_RESULT;
|
|
348
348
|
+ (BOOL)drawImageWithContext:(int64_t)context image:(UIImage * _Nonnull)image sx:(float)sx sy:(float)sy sw:(float)sw sh:(float)sh dx:(float)dx dy:(float)dy dw:(float)dw dh:(float)dh SWIFT_WARN_UNUSED_RESULT;
|
|
349
|
-
+ (int64_t)initWebGPUWithViewLayer:(int64_t)instance :(
|
|
350
|
-
+ (int64_t)initWebGPUWithView:(int64_t)instance :(
|
|
351
|
-
+ (void)resizeWebGPUWithView:(int64_t)context :(
|
|
352
|
-
+ (int64_t)
|
|
353
|
-
+ (int64_t)
|
|
354
|
-
+ (int64_t)initGLWithWidthAndHeight:(int32_t)width :(int32_t)height :(BOOL)alpha :(BOOL)antialias :(BOOL)depth :(BOOL)fail_if_major_performance_caveat :(int32_t)power_preference :(BOOL)premultiplied_alpha :(BOOL)preserve_drawing_buffer :(BOOL)stencil :(BOOL)desynchronized :(BOOL)xr_compatible :(int32_t)version :(BOOL)is_canvas SWIFT_METHOD_FAMILY(none) SWIFT_WARN_UNUSED_RESULT;
|
|
355
|
-
+ (int64_t)initSharedGLWidthAndHeight:(int32_t)width :(int32_t)height :(BOOL)alpha :(BOOL)antialias :(BOOL)depth :(BOOL)fail_if_major_performance_caveat :(int32_t)power_preference :(BOOL)premultiplied_alpha :(BOOL)preserve_drawing_buffer :(BOOL)stencil :(BOOL)desynchronized :(BOOL)xr_compatible :(int32_t)version :(BOOL)is_canvas :(int64_t)shared_context SWIFT_METHOD_FAMILY(none) SWIFT_WARN_UNUSED_RESULT;
|
|
349
|
+
+ (int64_t)initWebGPUWithViewLayer:(int64_t)instance :(NSCCanvas * _Nonnull)view :(uint32_t)width :(uint32_t)height SWIFT_METHOD_FAMILY(none) SWIFT_WARN_UNUSED_RESULT;
|
|
350
|
+
+ (int64_t)initWebGPUWithView:(int64_t)instance :(NSCCanvas * _Nonnull)view :(uint32_t)width :(uint32_t)height SWIFT_METHOD_FAMILY(none) SWIFT_WARN_UNUSED_RESULT;
|
|
351
|
+
+ (void)resizeWebGPUWithView:(int64_t)context :(NSCCanvas * _Nonnull)view :(uint32_t)width :(uint32_t)height;
|
|
352
|
+
+ (int64_t)initWebGLWithView:(NSCCanvas * _Nonnull)view :(BOOL)alpha :(BOOL)antialias :(BOOL)depth :(BOOL)fail_if_major_performance_caveat :(int32_t)power_preference :(BOOL)premultiplied_alpha :(BOOL)preserve_drawing_buffer :(BOOL)stencil :(BOOL)desynchronized :(BOOL)xr_compatible :(int32_t)version SWIFT_METHOD_FAMILY(none) SWIFT_WARN_UNUSED_RESULT;
|
|
353
|
+
+ (int64_t)initWebGLWithWidthAndHeight:(int32_t)width :(int32_t)height :(BOOL)alpha :(BOOL)antialias :(BOOL)depth :(BOOL)fail_if_major_performance_caveat :(int32_t)power_preference :(BOOL)premultiplied_alpha :(BOOL)preserve_drawing_buffer :(BOOL)stencil :(BOOL)desynchronized :(BOOL)xr_compatible :(int32_t)version SWIFT_METHOD_FAMILY(none) SWIFT_WARN_UNUSED_RESULT;
|
|
356
354
|
+ (void)resize2DContext:(int64_t)context :(float)width :(float)height;
|
|
357
355
|
+ (void)flush2DContext:(int64_t)context;
|
|
358
|
-
+ (
|
|
359
|
-
+ (void)
|
|
360
|
-
+ (
|
|
361
|
-
+ (void)
|
|
362
|
-
+ (int64_t)create2DContext:(
|
|
363
|
-
+ (
|
|
364
|
-
+ (void)
|
|
365
|
-
+ (NSString * _Nonnull)testToDataURL:(int64_t)context SWIFT_WARN_UNUSED_RESULT;
|
|
356
|
+
+ (void)flush2DContextAndSyncCPU:(int64_t)context;
|
|
357
|
+
+ (void)presentDrawable:(int64_t)context;
|
|
358
|
+
+ (BOOL)flushWebGL:(int64_t)context SWIFT_WARN_UNUSED_RESULT;
|
|
359
|
+
+ (void)releaseWebGL:(int64_t)context;
|
|
360
|
+
+ (int64_t)create2DContext:(NSCCanvas * _Nonnull)view :(int32_t)width :(int32_t)height :(BOOL)alpha :(float)density :(int32_t)fontColor :(float)ppi :(int32_t)direction SWIFT_WARN_UNUSED_RESULT;
|
|
361
|
+
+ (int64_t)create2DContextMetal:(NSCCanvas * _Nonnull)view :(BOOL)alpha :(float)density :(int32_t)fontColor :(float)ppi :(int32_t)direction SWIFT_WARN_UNUSED_RESULT;
|
|
362
|
+
+ (void)updateWebGLSurfaceWithView:(int64_t)view :(int32_t)width :(int32_t)height :(int64_t)context;
|
|
366
363
|
+ (void)writeFile:(NSData * _Nonnull)data :(NSString * _Nonnull)path :(void (^ _Nonnull)(NSString * _Nullable, NSString * _Nullable))callback;
|
|
367
364
|
+ (void)readFile:(NSString * _Nonnull)path :(void (^ _Nonnull)(NSString * _Nullable, NSData * _Nullable))callback;
|
|
368
365
|
+ (void)deleteFile:(NSString * _Nonnull)path :(void (^ _Nonnull)(NSError * _Nullable, BOOL))callback;
|
|
@@ -383,15 +380,19 @@ enum CanvasFit : NSInteger;
|
|
|
383
380
|
|
|
384
381
|
SWIFT_CLASS_NAMED("NSCCanvas")
|
|
385
382
|
@interface NSCCanvas : UIView
|
|
383
|
+
SWIFT_CLASS_PROPERTY(@property (nonatomic, class) BOOL forceGL;)
|
|
384
|
+
+ (BOOL)forceGL SWIFT_WARN_UNUSED_RESULT;
|
|
385
|
+
+ (void)setForceGL:(BOOL)value;
|
|
386
386
|
@property (nonatomic) enum CanvasFit fit;
|
|
387
387
|
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) NSMutableDictionary * _Nonnull store;)
|
|
388
388
|
+ (NSMutableDictionary * _Nonnull)store SWIFT_WARN_UNUSED_RESULT;
|
|
389
389
|
+ (NSMapTable<NSString *, NSCCanvas *> * _Nonnull)getViews SWIFT_WARN_UNUSED_RESULT;
|
|
390
|
-
- (void * _Nonnull)
|
|
390
|
+
- (void * _Nonnull)getGlViewPtr SWIFT_WARN_UNUSED_RESULT;
|
|
391
391
|
- (void * _Nonnull)getMtlViewPtr SWIFT_WARN_UNUSED_RESULT;
|
|
392
|
+
- (void * _Nonnull)getMtlLayerPtr SWIFT_WARN_UNUSED_RESULT;
|
|
392
393
|
@property (nonatomic) BOOL autoScale;
|
|
393
|
-
@property (nonatomic, readonly) int64_t nativeGL;
|
|
394
394
|
@property (nonatomic, readonly) int64_t nativeContext;
|
|
395
|
+
@property (nonatomic, readonly) BOOL is2D;
|
|
395
396
|
@property (nonatomic, readonly) CGFloat drawingBufferWidth;
|
|
396
397
|
@property (nonatomic, readonly) CGFloat drawingBufferHeight;
|
|
397
398
|
@property (nonatomic, readonly) float width;
|
|
@@ -401,8 +402,6 @@ SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) NSMutableDic
|
|
|
401
402
|
- (int64_t)create2DContext:(BOOL)alpha :(BOOL)antialias :(BOOL)depth :(BOOL)failIfMajorPerformanceCaveat :(int32_t)powerPreference :(BOOL)premultipliedAlpha :(BOOL)preserveDrawingBuffer :(BOOL)stencil :(BOOL)desynchronized :(BOOL)xrCompatible :(int32_t)fontColor SWIFT_WARN_UNUSED_RESULT;
|
|
402
403
|
- (UIImage * _Nullable)snapshot:(BOOL)flip SWIFT_WARN_UNUSED_RESULT;
|
|
403
404
|
- (BOOL)render;
|
|
404
|
-
- (void)context2DTest:(int64_t)context;
|
|
405
|
-
- (NSString * _Nonnull)context2DTestToDataURL:(int64_t)context SWIFT_WARN_UNUSED_RESULT;
|
|
406
405
|
@property (nonatomic, copy) void (^ _Nullable touchEventListener)(NSString * _Nonnull, UIGestureRecognizer * _Nonnull);
|
|
407
406
|
- (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder SWIFT_UNAVAILABLE;
|
|
408
407
|
- (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
|
|
@@ -411,6 +410,9 @@ SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) NSMutableDic
|
|
|
411
410
|
@property (nonatomic) NSInteger surfaceWidth;
|
|
412
411
|
@property (nonatomic) NSInteger surfaceHeight;
|
|
413
412
|
- (void)forceLayout:(CGFloat)width :(CGFloat)height;
|
|
413
|
+
- (void)context2DTest:(int64_t)context;
|
|
414
|
+
- (void)context2DPathTest:(int64_t)context;
|
|
415
|
+
- (void)context2DConic:(int64_t)context;
|
|
414
416
|
- (void)layoutSubviews;
|
|
415
417
|
+ (void)getBoundingClientRect:(UIView * _Nonnull)view :(void * _Nonnull)buffer;
|
|
416
418
|
@end
|
|
@@ -871,23 +873,20 @@ SWIFT_CLASS_NAMED("CanvasHelpers")
|
|
|
871
873
|
+ (BOOL)drawImageWithContext:(int64_t)context image:(UIImage * _Nonnull)image dx:(float)dx dy:(float)dy SWIFT_WARN_UNUSED_RESULT;
|
|
872
874
|
+ (BOOL)drawImageWithContext:(int64_t)context image:(UIImage * _Nonnull)image dx:(float)dx dy:(float)dy dw:(float)dw dh:(float)dh SWIFT_WARN_UNUSED_RESULT;
|
|
873
875
|
+ (BOOL)drawImageWithContext:(int64_t)context image:(UIImage * _Nonnull)image sx:(float)sx sy:(float)sy sw:(float)sw sh:(float)sh dx:(float)dx dy:(float)dy dw:(float)dw dh:(float)dh SWIFT_WARN_UNUSED_RESULT;
|
|
874
|
-
+ (int64_t)initWebGPUWithViewLayer:(int64_t)instance :(
|
|
875
|
-
+ (int64_t)initWebGPUWithView:(int64_t)instance :(
|
|
876
|
-
+ (void)resizeWebGPUWithView:(int64_t)context :(
|
|
877
|
-
+ (int64_t)
|
|
878
|
-
+ (int64_t)
|
|
879
|
-
+ (int64_t)initGLWithWidthAndHeight:(int32_t)width :(int32_t)height :(BOOL)alpha :(BOOL)antialias :(BOOL)depth :(BOOL)fail_if_major_performance_caveat :(int32_t)power_preference :(BOOL)premultiplied_alpha :(BOOL)preserve_drawing_buffer :(BOOL)stencil :(BOOL)desynchronized :(BOOL)xr_compatible :(int32_t)version :(BOOL)is_canvas SWIFT_METHOD_FAMILY(none) SWIFT_WARN_UNUSED_RESULT;
|
|
880
|
-
+ (int64_t)initSharedGLWidthAndHeight:(int32_t)width :(int32_t)height :(BOOL)alpha :(BOOL)antialias :(BOOL)depth :(BOOL)fail_if_major_performance_caveat :(int32_t)power_preference :(BOOL)premultiplied_alpha :(BOOL)preserve_drawing_buffer :(BOOL)stencil :(BOOL)desynchronized :(BOOL)xr_compatible :(int32_t)version :(BOOL)is_canvas :(int64_t)shared_context SWIFT_METHOD_FAMILY(none) SWIFT_WARN_UNUSED_RESULT;
|
|
876
|
+
+ (int64_t)initWebGPUWithViewLayer:(int64_t)instance :(NSCCanvas * _Nonnull)view :(uint32_t)width :(uint32_t)height SWIFT_METHOD_FAMILY(none) SWIFT_WARN_UNUSED_RESULT;
|
|
877
|
+
+ (int64_t)initWebGPUWithView:(int64_t)instance :(NSCCanvas * _Nonnull)view :(uint32_t)width :(uint32_t)height SWIFT_METHOD_FAMILY(none) SWIFT_WARN_UNUSED_RESULT;
|
|
878
|
+
+ (void)resizeWebGPUWithView:(int64_t)context :(NSCCanvas * _Nonnull)view :(uint32_t)width :(uint32_t)height;
|
|
879
|
+
+ (int64_t)initWebGLWithView:(NSCCanvas * _Nonnull)view :(BOOL)alpha :(BOOL)antialias :(BOOL)depth :(BOOL)fail_if_major_performance_caveat :(int32_t)power_preference :(BOOL)premultiplied_alpha :(BOOL)preserve_drawing_buffer :(BOOL)stencil :(BOOL)desynchronized :(BOOL)xr_compatible :(int32_t)version SWIFT_METHOD_FAMILY(none) SWIFT_WARN_UNUSED_RESULT;
|
|
880
|
+
+ (int64_t)initWebGLWithWidthAndHeight:(int32_t)width :(int32_t)height :(BOOL)alpha :(BOOL)antialias :(BOOL)depth :(BOOL)fail_if_major_performance_caveat :(int32_t)power_preference :(BOOL)premultiplied_alpha :(BOOL)preserve_drawing_buffer :(BOOL)stencil :(BOOL)desynchronized :(BOOL)xr_compatible :(int32_t)version SWIFT_METHOD_FAMILY(none) SWIFT_WARN_UNUSED_RESULT;
|
|
881
881
|
+ (void)resize2DContext:(int64_t)context :(float)width :(float)height;
|
|
882
882
|
+ (void)flush2DContext:(int64_t)context;
|
|
883
|
-
+ (
|
|
884
|
-
+ (void)
|
|
885
|
-
+ (
|
|
886
|
-
+ (void)
|
|
887
|
-
+ (int64_t)create2DContext:(
|
|
888
|
-
+ (
|
|
889
|
-
+ (void)
|
|
890
|
-
+ (NSString * _Nonnull)testToDataURL:(int64_t)context SWIFT_WARN_UNUSED_RESULT;
|
|
883
|
+
+ (void)flush2DContextAndSyncCPU:(int64_t)context;
|
|
884
|
+
+ (void)presentDrawable:(int64_t)context;
|
|
885
|
+
+ (BOOL)flushWebGL:(int64_t)context SWIFT_WARN_UNUSED_RESULT;
|
|
886
|
+
+ (void)releaseWebGL:(int64_t)context;
|
|
887
|
+
+ (int64_t)create2DContext:(NSCCanvas * _Nonnull)view :(int32_t)width :(int32_t)height :(BOOL)alpha :(float)density :(int32_t)fontColor :(float)ppi :(int32_t)direction SWIFT_WARN_UNUSED_RESULT;
|
|
888
|
+
+ (int64_t)create2DContextMetal:(NSCCanvas * _Nonnull)view :(BOOL)alpha :(float)density :(int32_t)fontColor :(float)ppi :(int32_t)direction SWIFT_WARN_UNUSED_RESULT;
|
|
889
|
+
+ (void)updateWebGLSurfaceWithView:(int64_t)view :(int32_t)width :(int32_t)height :(int64_t)context;
|
|
891
890
|
+ (void)writeFile:(NSData * _Nonnull)data :(NSString * _Nonnull)path :(void (^ _Nonnull)(NSString * _Nullable, NSString * _Nullable))callback;
|
|
892
891
|
+ (void)readFile:(NSString * _Nonnull)path :(void (^ _Nonnull)(NSString * _Nullable, NSData * _Nullable))callback;
|
|
893
892
|
+ (void)deleteFile:(NSString * _Nonnull)path :(void (^ _Nonnull)(NSError * _Nullable, BOOL))callback;
|
|
@@ -908,15 +907,19 @@ enum CanvasFit : NSInteger;
|
|
|
908
907
|
|
|
909
908
|
SWIFT_CLASS_NAMED("NSCCanvas")
|
|
910
909
|
@interface NSCCanvas : UIView
|
|
910
|
+
SWIFT_CLASS_PROPERTY(@property (nonatomic, class) BOOL forceGL;)
|
|
911
|
+
+ (BOOL)forceGL SWIFT_WARN_UNUSED_RESULT;
|
|
912
|
+
+ (void)setForceGL:(BOOL)value;
|
|
911
913
|
@property (nonatomic) enum CanvasFit fit;
|
|
912
914
|
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) NSMutableDictionary * _Nonnull store;)
|
|
913
915
|
+ (NSMutableDictionary * _Nonnull)store SWIFT_WARN_UNUSED_RESULT;
|
|
914
916
|
+ (NSMapTable<NSString *, NSCCanvas *> * _Nonnull)getViews SWIFT_WARN_UNUSED_RESULT;
|
|
915
|
-
- (void * _Nonnull)
|
|
917
|
+
- (void * _Nonnull)getGlViewPtr SWIFT_WARN_UNUSED_RESULT;
|
|
916
918
|
- (void * _Nonnull)getMtlViewPtr SWIFT_WARN_UNUSED_RESULT;
|
|
919
|
+
- (void * _Nonnull)getMtlLayerPtr SWIFT_WARN_UNUSED_RESULT;
|
|
917
920
|
@property (nonatomic) BOOL autoScale;
|
|
918
|
-
@property (nonatomic, readonly) int64_t nativeGL;
|
|
919
921
|
@property (nonatomic, readonly) int64_t nativeContext;
|
|
922
|
+
@property (nonatomic, readonly) BOOL is2D;
|
|
920
923
|
@property (nonatomic, readonly) CGFloat drawingBufferWidth;
|
|
921
924
|
@property (nonatomic, readonly) CGFloat drawingBufferHeight;
|
|
922
925
|
@property (nonatomic, readonly) float width;
|
|
@@ -926,8 +929,6 @@ SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) NSMutableDic
|
|
|
926
929
|
- (int64_t)create2DContext:(BOOL)alpha :(BOOL)antialias :(BOOL)depth :(BOOL)failIfMajorPerformanceCaveat :(int32_t)powerPreference :(BOOL)premultipliedAlpha :(BOOL)preserveDrawingBuffer :(BOOL)stencil :(BOOL)desynchronized :(BOOL)xrCompatible :(int32_t)fontColor SWIFT_WARN_UNUSED_RESULT;
|
|
927
930
|
- (UIImage * _Nullable)snapshot:(BOOL)flip SWIFT_WARN_UNUSED_RESULT;
|
|
928
931
|
- (BOOL)render;
|
|
929
|
-
- (void)context2DTest:(int64_t)context;
|
|
930
|
-
- (NSString * _Nonnull)context2DTestToDataURL:(int64_t)context SWIFT_WARN_UNUSED_RESULT;
|
|
931
932
|
@property (nonatomic, copy) void (^ _Nullable touchEventListener)(NSString * _Nonnull, UIGestureRecognizer * _Nonnull);
|
|
932
933
|
- (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder SWIFT_UNAVAILABLE;
|
|
933
934
|
- (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
|
|
@@ -936,6 +937,9 @@ SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong) NSMutableDic
|
|
|
936
937
|
@property (nonatomic) NSInteger surfaceWidth;
|
|
937
938
|
@property (nonatomic) NSInteger surfaceHeight;
|
|
938
939
|
- (void)forceLayout:(CGFloat)width :(CGFloat)height;
|
|
940
|
+
- (void)context2DTest:(int64_t)context;
|
|
941
|
+
- (void)context2DPathTest:(int64_t)context;
|
|
942
|
+
- (void)context2DConic:(int64_t)context;
|
|
939
943
|
- (void)layoutSubviews;
|
|
940
944
|
+ (void)getBoundingClientRect:(UIView * _Nonnull)view :(void * _Nonnull)buffer;
|
|
941
945
|
@end
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
//
|
|
2
|
+
// NSCMTLView.h
|
|
3
|
+
// CanvasNative
|
|
4
|
+
//
|
|
5
|
+
// Created by Osei Fortune on 08/10/2024.
|
|
6
|
+
//
|
|
7
|
+
#ifndef NSCMTLView_h
|
|
8
|
+
#define NSCMTLView_h
|
|
9
|
+
|
|
10
|
+
#import <Foundation/Foundation.h>
|
|
11
|
+
#import <UIKit/UIKit.h>
|
|
12
|
+
#import <MetalKit/MetalKit.h>
|
|
13
|
+
typedef enum {
|
|
14
|
+
kNone,
|
|
15
|
+
kPending,
|
|
16
|
+
kInvalidating
|
|
17
|
+
} NSCSurfaceState;
|
|
18
|
+
|
|
19
|
+
@interface NSCMTLView : UIView
|
|
20
|
+
@property(weak, nonatomic) UIView* canvas;
|
|
21
|
+
@property id<MTLCommandQueue> queue;
|
|
22
|
+
@property int state;
|
|
23
|
+
@property (nonatomic) CGSize drawableSize;
|
|
24
|
+
@property NSUInteger sampleCount;
|
|
25
|
+
-(void) present;
|
|
26
|
+
-(void) setup;
|
|
27
|
+
-(void*) getDevicePtr;
|
|
28
|
+
-(void*) getQueuePtr;
|
|
29
|
+
@end
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
#endif /* NSCMTLView_h */
|
|
@@ -8,196 +8,107 @@
|
|
|
8
8
|
#include <stdint.h>
|
|
9
9
|
#include <stdlib.h>
|
|
10
10
|
|
|
11
|
-
long long
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
11
|
+
long long canvas_native_ios_create_webgl_context(void *view,
|
|
12
|
+
bool alpha,
|
|
13
|
+
bool antialias,
|
|
14
|
+
bool depth,
|
|
15
|
+
bool fail_if_major_performance_caveat,
|
|
16
|
+
int32_t power_preference,
|
|
17
|
+
bool premultiplied_alpha,
|
|
18
|
+
bool preserve_drawing_buffer,
|
|
19
|
+
bool stencil,
|
|
20
|
+
bool desynchronized,
|
|
21
|
+
bool xr_compatible,
|
|
22
|
+
uint32_t version);
|
|
23
|
+
|
|
24
|
+
bool canvas_native_ios_flush_webgl(int64_t context);
|
|
15
25
|
|
|
16
|
-
|
|
17
|
-
long long canvas_native_init_ios_webgpu_uiview(int64_t instance,
|
|
18
|
-
int64_t view,
|
|
19
|
-
uint32_t width,
|
|
20
|
-
uint32_t height);
|
|
21
|
-
#endif
|
|
26
|
+
void canvas_native_ios_flush_2d_context(int64_t context);
|
|
22
27
|
|
|
23
|
-
|
|
24
|
-
void canvas_native_resize_ios_webgpu_uiview(int64_t context,
|
|
25
|
-
int64_t view,
|
|
26
|
-
uint32_t width,
|
|
27
|
-
uint32_t height);
|
|
28
|
-
#endif
|
|
28
|
+
void canvas_native_ios_present_drawable(int64_t context);
|
|
29
29
|
|
|
30
|
-
|
|
31
|
-
bool alpha,
|
|
32
|
-
bool antialias,
|
|
33
|
-
bool depth,
|
|
34
|
-
bool fail_if_major_performance_caveat,
|
|
35
|
-
int32_t power_preference,
|
|
36
|
-
bool premultiplied_alpha,
|
|
37
|
-
bool preserve_drawing_buffer,
|
|
38
|
-
bool stencil,
|
|
39
|
-
bool desynchronized,
|
|
40
|
-
bool xr_compatible,
|
|
41
|
-
int32_t version,
|
|
42
|
-
bool is_canvas);
|
|
43
|
-
|
|
44
|
-
long long canvas_native_init_ios_gl_with_shared_gl(int64_t view,
|
|
45
|
-
bool alpha,
|
|
46
|
-
bool antialias,
|
|
47
|
-
bool depth,
|
|
48
|
-
bool fail_if_major_performance_caveat,
|
|
49
|
-
int32_t power_preference,
|
|
50
|
-
bool premultiplied_alpha,
|
|
51
|
-
bool preserve_drawing_buffer,
|
|
52
|
-
bool stencil,
|
|
53
|
-
bool desynchronized,
|
|
54
|
-
bool xr_compatible,
|
|
55
|
-
int32_t version,
|
|
56
|
-
bool is_canvas,
|
|
57
|
-
int64_t shared_context);
|
|
58
|
-
|
|
59
|
-
long long canvas_native_init_offscreen_ios_gl(int32_t width,
|
|
60
|
-
int32_t height,
|
|
61
|
-
bool alpha,
|
|
62
|
-
bool antialias,
|
|
63
|
-
bool depth,
|
|
64
|
-
bool fail_if_major_performance_caveat,
|
|
65
|
-
int32_t power_preference,
|
|
66
|
-
bool premultiplied_alpha,
|
|
67
|
-
bool preserve_drawing_buffer,
|
|
68
|
-
bool stencil,
|
|
69
|
-
bool desynchronized,
|
|
70
|
-
bool xr_compatible,
|
|
71
|
-
int32_t version,
|
|
72
|
-
bool is_canvas);
|
|
73
|
-
|
|
74
|
-
long long canvas_native_init_offscreen_ios_gl_with_shared_gl(int32_t width,
|
|
75
|
-
int32_t height,
|
|
76
|
-
bool alpha,
|
|
77
|
-
bool antialias,
|
|
78
|
-
bool depth,
|
|
79
|
-
bool fail_if_major_performance_caveat,
|
|
80
|
-
int32_t power_preference,
|
|
81
|
-
bool premultiplied_alpha,
|
|
82
|
-
bool preserve_drawing_buffer,
|
|
83
|
-
bool stencil,
|
|
84
|
-
bool desynchronized,
|
|
85
|
-
bool xr_compatible,
|
|
86
|
-
int32_t version,
|
|
87
|
-
bool is_canvas,
|
|
88
|
-
int64_t shared_context);
|
|
89
|
-
|
|
90
|
-
bool canvas_native_ios_flush_gl(int64_t context);
|
|
30
|
+
void canvas_native_ios_flush_2d_context_and_sync_cpu(int64_t context);
|
|
91
31
|
|
|
92
|
-
void
|
|
32
|
+
void canvas_native_ios_resize_context_2d(int64_t context, float width, float height);
|
|
33
|
+
|
|
34
|
+
int64_t canvas_native_ios_create_2d_context(void *view,
|
|
35
|
+
int32_t width,
|
|
36
|
+
int32_t height,
|
|
37
|
+
bool alpha,
|
|
38
|
+
float density,
|
|
39
|
+
int32_t font_color,
|
|
40
|
+
float ppi,
|
|
41
|
+
int32_t direction);
|
|
42
|
+
|
|
43
|
+
void canvas_native_ios_update_webgl_surface(int64_t view,
|
|
44
|
+
int32_t _width,
|
|
45
|
+
int32_t _height,
|
|
46
|
+
int64_t context);
|
|
47
|
+
|
|
48
|
+
void canvas_native_ios_release_webgl(int64_t context);
|
|
49
|
+
|
|
50
|
+
void canvas_native_ios_gl_make_current(int64_t context);
|
|
93
51
|
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
int64_t
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
void canvas_native_gl_make_current(int64_t gl_context);
|
|
117
|
-
|
|
118
|
-
char *canvas_native_context_2d_test_to_data_url(int64_t context);
|
|
119
|
-
|
|
120
|
-
void canvas_native_context_2d_destroy_string(char *string);
|
|
121
|
-
|
|
122
|
-
bool canvas_native_imageasset_load_from_bytes(int64_t asset, uint8_t *bytes, uintptr_t size);
|
|
123
|
-
|
|
124
|
-
int64_t canvas_native_context_create_pattern_raw(int64_t context,
|
|
125
|
-
int32_t width,
|
|
126
|
-
int32_t height,
|
|
127
|
-
uint8_t *bytes,
|
|
128
|
-
uintptr_t size,
|
|
129
|
-
const char *repetition);
|
|
130
|
-
|
|
131
|
-
bool canvas_native_context_draw_image_dx_dy_with_bytes(int64_t context,
|
|
132
|
-
uint8_t *bytes,
|
|
133
|
-
uintptr_t size,
|
|
134
|
-
float width,
|
|
135
|
-
float height,
|
|
136
|
-
float dx,
|
|
137
|
-
float dy);
|
|
138
|
-
|
|
139
|
-
bool canvas_native_context_draw_image_dx_dy_dw_dh_with_bytes(int64_t context,
|
|
140
|
-
uint8_t *bytes,
|
|
141
|
-
uintptr_t size,
|
|
142
|
-
float width,
|
|
143
|
-
float height,
|
|
144
|
-
float dx,
|
|
145
|
-
float dy,
|
|
146
|
-
float d_width,
|
|
147
|
-
float d_height);
|
|
148
|
-
|
|
149
|
-
bool canvas_native_context_draw_image_with_bytes(int64_t context,
|
|
150
|
-
uint8_t *bytes,
|
|
151
|
-
uintptr_t size,
|
|
152
|
-
float width,
|
|
153
|
-
float height,
|
|
154
|
-
float sx,
|
|
155
|
-
float sy,
|
|
156
|
-
float s_width,
|
|
157
|
-
float s_height,
|
|
158
|
-
float dx,
|
|
159
|
-
float dy,
|
|
160
|
-
float d_width,
|
|
161
|
-
float d_height);
|
|
162
|
-
|
|
163
|
-
void canvas_native_context_custom_with_buffer_flush(int64_t context,
|
|
164
|
-
uint8_t *bytes,
|
|
165
|
-
uintptr_t size,
|
|
166
|
-
float width,
|
|
167
|
-
float height,
|
|
168
|
-
bool alpha);
|
|
169
|
-
|
|
170
|
-
long long canvas_native_context_init_context_with_custom_surface(float width,
|
|
52
|
+
bool canvas_native_ios_image_asset_load_from_bytes(int64_t asset, uint8_t *bytes, uintptr_t size);
|
|
53
|
+
|
|
54
|
+
int64_t canvas_native_ios_context_create_pattern_raw(int64_t context,
|
|
55
|
+
int32_t width,
|
|
56
|
+
int32_t height,
|
|
57
|
+
uint8_t *bytes,
|
|
58
|
+
uintptr_t size,
|
|
59
|
+
const char *repetition);
|
|
60
|
+
|
|
61
|
+
bool canvas_native_ios_context_draw_image_dx_dy_with_bytes(int64_t context,
|
|
62
|
+
uint8_t *bytes,
|
|
63
|
+
uintptr_t size,
|
|
64
|
+
float width,
|
|
65
|
+
float height,
|
|
66
|
+
float dx,
|
|
67
|
+
float dy);
|
|
68
|
+
|
|
69
|
+
bool canvas_native_ios_context_draw_image_dx_dy_dw_dh_with_bytes(int64_t context,
|
|
70
|
+
uint8_t *bytes,
|
|
71
|
+
uintptr_t size,
|
|
72
|
+
float width,
|
|
171
73
|
float height,
|
|
172
|
-
float
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
float
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
74
|
+
float dx,
|
|
75
|
+
float dy,
|
|
76
|
+
float d_width,
|
|
77
|
+
float d_height);
|
|
78
|
+
|
|
79
|
+
bool canvas_native_ios_context_draw_image_with_bytes(int64_t context,
|
|
80
|
+
uint8_t *bytes,
|
|
81
|
+
uintptr_t size,
|
|
82
|
+
float width,
|
|
83
|
+
float height,
|
|
84
|
+
float sx,
|
|
85
|
+
float sy,
|
|
86
|
+
float s_width,
|
|
87
|
+
float s_height,
|
|
88
|
+
float dx,
|
|
89
|
+
float dy,
|
|
90
|
+
float d_width,
|
|
91
|
+
float d_height);
|
|
92
|
+
|
|
93
|
+
void canvas_native_ios_context_custom_with_buffer_flush(int64_t context,
|
|
94
|
+
uint8_t *bytes,
|
|
95
|
+
uintptr_t size,
|
|
96
|
+
float width,
|
|
97
|
+
float height,
|
|
98
|
+
bool alpha);
|
|
99
|
+
|
|
100
|
+
long long canvas_native_ios_context_init_context_with_custom_surface(float width,
|
|
101
|
+
float height,
|
|
102
|
+
float density,
|
|
103
|
+
bool alpha,
|
|
104
|
+
int font_color,
|
|
105
|
+
float ppi,
|
|
106
|
+
int direction);
|
|
107
|
+
|
|
108
|
+
void canvas_native_ios_webgl_tex_image_2d(int64_t context,
|
|
197
109
|
int32_t target,
|
|
198
110
|
int32_t level,
|
|
199
|
-
int32_t
|
|
200
|
-
int32_t yoffset,
|
|
111
|
+
int32_t internalformat,
|
|
201
112
|
int32_t format,
|
|
202
113
|
int32_t type_,
|
|
203
114
|
uint8_t *bytes,
|
|
@@ -206,4 +117,54 @@ void canvas_native_webgl_tex_sub_image_2d(int64_t context,
|
|
|
206
117
|
float height,
|
|
207
118
|
bool flip_y);
|
|
208
119
|
|
|
120
|
+
void canvas_native_ios_webgl_tex_sub_image_2d(int64_t context,
|
|
121
|
+
int32_t target,
|
|
122
|
+
int32_t level,
|
|
123
|
+
int32_t xoffset,
|
|
124
|
+
int32_t yoffset,
|
|
125
|
+
int32_t format,
|
|
126
|
+
int32_t type_,
|
|
127
|
+
uint8_t *bytes,
|
|
128
|
+
uintptr_t size,
|
|
129
|
+
float width,
|
|
130
|
+
float height,
|
|
131
|
+
bool flip_y);
|
|
132
|
+
|
|
133
|
+
int64_t canvas_native_ios_create_2d_context_metal(void *view,
|
|
134
|
+
bool alpha,
|
|
135
|
+
float density,
|
|
136
|
+
uintptr_t samples,
|
|
137
|
+
int32_t font_color,
|
|
138
|
+
float ppi,
|
|
139
|
+
int32_t direction);
|
|
140
|
+
|
|
141
|
+
int64_t canvas_native_ios_create_2d_context_metal_device_queue(void *view,
|
|
142
|
+
void *device,
|
|
143
|
+
void *queue,
|
|
144
|
+
bool alpha,
|
|
145
|
+
float density,
|
|
146
|
+
uintptr_t samples,
|
|
147
|
+
int32_t font_color,
|
|
148
|
+
float ppi,
|
|
149
|
+
int32_t direction);
|
|
150
|
+
|
|
151
|
+
long long canvas_native_init_ios_webgpu(int64_t instance,
|
|
152
|
+
void *view,
|
|
153
|
+
uint32_t width,
|
|
154
|
+
uint32_t height);
|
|
155
|
+
|
|
156
|
+
#if defined(TARGET_OS_MACOS)
|
|
157
|
+
long long canvas_native_init_ios_webgpu_nsview(int64_t instance,
|
|
158
|
+
void *view,
|
|
159
|
+
uint32_t width,
|
|
160
|
+
uint32_t height);
|
|
161
|
+
#endif
|
|
162
|
+
|
|
163
|
+
#if defined(TARGET_OS_IOS)
|
|
164
|
+
void canvas_native_resize_ios_webgpu_uiview(int64_t context,
|
|
165
|
+
void *view,
|
|
166
|
+
uint32_t width,
|
|
167
|
+
uint32_t height);
|
|
168
|
+
#endif
|
|
169
|
+
|
|
209
170
|
#endif /* CANVAS_IOS_H */
|
|
@@ -1844,6 +1844,12 @@ void canvas_native_font_add_family(const char *alias,
|
|
|
1844
1844
|
const char *const *filenames,
|
|
1845
1845
|
uintptr_t length);
|
|
1846
1846
|
|
|
1847
|
+
void canvas_native_context_2d_test(int64_t context);
|
|
1848
|
+
|
|
1849
|
+
void canvas_native_context_2d_path_test(int64_t context);
|
|
1850
|
+
|
|
1851
|
+
void canvas_native_context_2d_conic_test(int64_t context);
|
|
1852
|
+
|
|
1847
1853
|
void canvas_native_context_release(struct CanvasRenderingContext2D *value);
|
|
1848
1854
|
|
|
1849
1855
|
#if (defined(TARGET_OS_ANDROID) || defined(TARGET_OS_IOS))
|
|
@@ -1879,11 +1885,10 @@ struct CanvasRenderingContext2D *canvas_native_context_create(float width,
|
|
|
1879
1885
|
float ppi,
|
|
1880
1886
|
uint32_t direction);
|
|
1881
1887
|
|
|
1882
|
-
struct CanvasRenderingContext2D *canvas_native_context_create_gl(
|
|
1888
|
+
struct CanvasRenderingContext2D *canvas_native_context_create_gl(void *view,
|
|
1889
|
+
float width,
|
|
1883
1890
|
float height,
|
|
1884
1891
|
float density,
|
|
1885
|
-
int64_t gl_context,
|
|
1886
|
-
int32_t samples,
|
|
1887
1892
|
bool alpha,
|
|
1888
1893
|
int32_t font_color,
|
|
1889
1894
|
float ppi,
|
|
@@ -3640,10 +3645,6 @@ struct U8Buffer *canvas_native_text_encoder_encode(const struct TextEncoder *enc
|
|
|
3640
3645
|
|
|
3641
3646
|
const char *canvas_native_text_encoder_get_encoding(const struct TextEncoder *encoder);
|
|
3642
3647
|
|
|
3643
|
-
bool canvas_native_context_gl_make_current(const struct CanvasRenderingContext2D *context);
|
|
3644
|
-
|
|
3645
|
-
bool canvas_native_context_gl_swap_buffers(const struct CanvasRenderingContext2D *context);
|
|
3646
|
-
|
|
3647
3648
|
struct PaintStyle *canvas_native_context_create_pattern_webgl(struct WebGLState *source,
|
|
3648
3649
|
struct CanvasRenderingContext2D *context,
|
|
3649
3650
|
enum CanvasRepetition repetition);
|
|
@@ -3865,7 +3866,25 @@ bool canvas_native_webgl_oes_vertex_array_object_is_vertex_array_oes(uint32_t ar
|
|
|
3865
3866
|
void canvas_native_webgl_oes_vertex_array_object_bind_vertex_array_oes(uint32_t array_object,
|
|
3866
3867
|
const struct OES_vertex_array_object *object);
|
|
3867
3868
|
|
|
3868
|
-
|
|
3869
|
+
#if defined(TARGET_OS_ANDROID)
|
|
3870
|
+
struct WebGLState *canvas_native_webgl_create(void *view,
|
|
3871
|
+
int32_t width,
|
|
3872
|
+
int32_t height,
|
|
3873
|
+
int32_t version,
|
|
3874
|
+
bool alpha,
|
|
3875
|
+
bool antialias,
|
|
3876
|
+
bool depth,
|
|
3877
|
+
bool fail_if_major_performance_caveat,
|
|
3878
|
+
int32_t power_preference,
|
|
3879
|
+
bool premultiplied_alpha,
|
|
3880
|
+
bool preserve_drawing_buffer,
|
|
3881
|
+
bool stencil,
|
|
3882
|
+
bool desynchronized,
|
|
3883
|
+
bool xr_compatible);
|
|
3884
|
+
#endif
|
|
3885
|
+
|
|
3886
|
+
#if !defined(TARGET_OS_ANDROID)
|
|
3887
|
+
struct WebGLState *canvas_native_webgl_create(void *view,
|
|
3869
3888
|
int32_t version,
|
|
3870
3889
|
bool alpha,
|
|
3871
3890
|
bool antialias,
|
|
@@ -3877,6 +3896,7 @@ struct WebGLState *canvas_native_webgl_create(int64_t gl_context,
|
|
|
3877
3896
|
bool stencil,
|
|
3878
3897
|
bool desynchronized,
|
|
3879
3898
|
bool xr_compatible);
|
|
3899
|
+
#endif
|
|
3880
3900
|
|
|
3881
3901
|
struct WebGLState *canvas_native_webgl_create_no_window(int32_t width,
|
|
3882
3902
|
int32_t height,
|
|
@@ -5045,8 +5065,8 @@ void canvas_native_webgl2_tex_sub_image3d_canvas2d(uint32_t target,
|
|
|
5045
5065
|
int32_t xoffset,
|
|
5046
5066
|
int32_t yoffset,
|
|
5047
5067
|
int32_t zoffset,
|
|
5048
|
-
int32_t
|
|
5049
|
-
int32_t
|
|
5068
|
+
int32_t _width,
|
|
5069
|
+
int32_t _height,
|
|
5050
5070
|
int32_t depth,
|
|
5051
5071
|
uint32_t format,
|
|
5052
5072
|
uint32_t type_,
|
|
Binary file
|