Skip to content

CoreGraphics iOS xcode14.0 beta1

Manuel de la Pena edited this page Sep 1, 2022 · 4 revisions

#CoreGraphics.framework https://github.com/xamarin/xamarin-macios/pull/15831

diff -ruN /Applications/Xcode_13.3.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGColorSpace.h /Applications/Xcode_14.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGColorSpace.h
--- /Applications/Xcode_13.3.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGColorSpace.h	2022-02-23 10:56:25.000000000 -0500
+++ /Applications/Xcode_14.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGColorSpace.h	2022-06-03 18:09:11.000000000 -0400
@@ -118,6 +118,9 @@
 CG_EXTERN const CFStringRef kCGColorSpaceITUR_709_PQ
 CG_AVAILABLE_STARTING(12.0, 15.1);
 
+CG_EXTERN const CFStringRef kCGColorSpaceITUR_709_HLG
+CG_AVAILABLE_STARTING(12.0, 15.1);
+
 CG_EXTERN const CFStringRef kCGColorSpaceITUR_2020
 CG_AVAILABLE_STARTING(10.11, 9.0);
 
@@ -465,6 +468,9 @@
 CG_EXTERN CGColorSpaceRef  __nullable CGColorSpaceCreateExtendedLinearized(CGColorSpaceRef space)
 CG_AVAILABLE_STARTING(11.0, 14.0);
 
+/* Create a copy of the color space which uses standard range [0.0, 1.0]. */
+CG_EXTERN CGColorSpaceRef CGColorSpaceCreateCopyWithStandardRange(CGColorSpaceRef s)
+CG_AVAILABLE_STARTING(13.0, 16.0);
 
 /* Deprecated functions */
 

diff -ruN /Applications/Xcode_13.3.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGImage.h /Applications/Xcode_14.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGImage.h
--- /Applications/Xcode_13.3.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGImage.h	2022-02-23 07:15:51.000000000 -0500
+++ /Applications/Xcode_14.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGImage.h	2022-05-31 15:04:00.000000000 -0400
@@ -42,10 +42,12 @@
 typedef CF_ENUM(uint32_t, CGImagePixelFormatInfo) {
     kCGImagePixelFormatMask      = 0xF0000,
     kCGImagePixelFormatPacked    = (0 << 16),
-    kCGImagePixelFormatRGB555    = (1 << 16), /* Only for RGB 16 bits per pixel */
-    kCGImagePixelFormatRGB565    = (2 << 16), /* Only for RGB 16 bits per pixel */
-    kCGImagePixelFormatRGB101010 = (3 << 16), /* Only for RGB 32 bits per pixel */
-    kCGImagePixelFormatRGBCIF10  = (4 << 16), /* Only for RGB 32 bits per pixel */
+    kCGImagePixelFormatRGB555    = (1 << 16), /* Only for RGB 16 bits per pixel, alpha != alpha none */
+    kCGImagePixelFormatRGB565    = (2 << 16), /* Only for RGB 16 bits per pixel, alpha none */
+    kCGImagePixelFormatRGB101010 = (3 << 16), /* Only for RGB 32 bits per pixel, alpha != none */
+    kCGImagePixelFormatRGBCIF10  = (4 << 16)  /* Only for RGB 32 bits per pixel,
+                                               * 10 bits per component, kCGImageByteOrder32Little
+                                               * The 2 MSB of the pixel need to be set to 1 */
 } CG_AVAILABLE_STARTING(10.14, 12.0);
 
 typedef CF_OPTIONS(uint32_t, CGBitmapInfo) {
diff -ruN /Applications/Xcode_13.3.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGPDFScanner.h /Applications/Xcode_14.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGPDFScanner.h
--- /Applications/Xcode_13.3.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGPDFScanner.h	2022-02-23 07:55:53.000000000 -0500
+++ /Applications/Xcode_14.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGPDFScanner.h	2022-05-31 14:49:23.000000000 -0400
@@ -112,6 +112,10 @@
     CGPDFStreamRef __nullable * __nullable value)
     CG_AVAILABLE_STARTING(10.4, 2.0);
 
+/* Cleanly stop the scanner on the current operator, releasing any
+   temporary resources. */
+CG_EXTERN void CGPDFScannerStop(CGPDFScannerRef s);
+
 CF_ASSUME_NONNULL_END
 
 CF_IMPLICIT_BRIDGING_DISABLED
diff -ruN /Applications/Xcode_13.3.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGPath.h /Applications/Xcode_14.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGPath.h
--- /Applications/Xcode_13.3.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGPath.h	2022-02-23 10:56:25.000000000 -0500
+++ /Applications/Xcode_14.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGPath.h	2022-05-31 15:02:15.000000000 -0400
@@ -15,6 +15,7 @@
 #include <CoreGraphics/CGBase.h>
 #include <CoreGraphics/CGAffineTransform.h>
 #include <CoreFoundation/CFBase.h>
+#include <CoreFoundation/CFArray.h>
 
 CF_IMPLICIT_BRIDGING_ENABLED
 
@@ -393,6 +394,47 @@
 CG_EXTERN void CGPathApplyWithBlock(CGPathRef path, CGPathApplyBlock CF_NOESCAPE block)
     CG_AVAILABLE_STARTING(10.13, 11.0);
 
+
+/* Returns a new weakly-simple path without self-intersections and with a normalized orientation. Filling the resulting path using even-odd or non-zero filling is identical. */
+
+CG_EXTERN CGPathRef __nullable CGPathCreateCopyByNormalizing(CGPathRef cg_nullable path, bool evenOddFillRule) CG_AVAILABLE_STARTING(13.0, 16.0);
+
+/* Returns a new path created by unioning `path` and `maskPath`. Any unclosed subpaths in either path are assumed to be closed. The resulting path is suitable for either even-odd or non-zero filling. */
+
+CG_EXTERN CGPathRef __nullable CGPathCreateCopyByUnioningPath(CGPathRef cg_nullable path, CGPathRef cg_nullable maskPath, bool evenOddFillRule) CG_AVAILABLE_STARTING(13.0, 16.0);
+
+/* Returns a new path created by intersecting `path` and `maskPath`. Any unclosed subpaths in either path are assumed to be closed. The resulting path is suitable for either even-odd or non-zero filling. */
+
+CG_EXTERN CGPathRef __nullable CGPathCreateCopyByIntersectingPath(CGPathRef cg_nullable path, CGPathRef cg_nullable maskPath, bool evenOddFillRule) CG_AVAILABLE_STARTING(13.0, 16.0);
+
+/* Returns a new path created by subtracting `maskPath` from `path`. Any unclosed subpaths in either path are assumed to be closed. The resulting path is suitable for either even-odd or non-zero filling. */
+
+CG_EXTERN CGPathRef __nullable CGPathCreateCopyBySubtractingPath(CGPathRef cg_nullable path, CGPathRef cg_nullable maskPath, bool evenOddFillRule) CG_AVAILABLE_STARTING(13.0, 16.0);
+
+/* Returns a new path created by exclusive or-ing `path` and `maskPath`. Any unclosed subpaths in either path are assumed to be closed. The resulting path is suitable for either even-odd or non-zero filling. */
+
+CG_EXTERN CGPathRef __nullable CGPathCreateCopyBySymmetricDifferenceOfPath(CGPathRef cg_nullable path, CGPathRef cg_nullable maskPath, bool evenOddFillRule) CG_AVAILABLE_STARTING(13.0, 16.0);
+
+/* Returns a new path created by subtracting the `maskPath` from the line of `path` with the fill of `maskPath`. This returns a potentially open path. */
+
+CG_EXTERN CGPathRef __nullable CGPathCreateCopyOfLineBySubtractingPath(CGPathRef cg_nullable path, CGPathRef cg_nullable maskPath, bool evenOddFillRule) CG_AVAILABLE_STARTING(13.0, 16.0);
+
+/* Returns a new path created by intersecting the line of `path` and the fill of `maskPath`. This returns a potentially open path. */
+
+CG_EXTERN CGPathRef __nullable CGPathCreateCopyOfLineByIntersectingPath(CGPathRef cg_nullable path, CGPathRef cg_nullable maskPath, bool evenOddFillRule) CG_AVAILABLE_STARTING(13.0, 16.0);
+
+/* Return an array of the visually separated components of a path. */
+
+CG_EXTERN CFArrayRef __nullable CGPathCreateSeparateComponents(CGPathRef cg_nullable path, bool evenOddFillRule) CG_AVAILABLE_STARTING(13.0, 16.0);
+
+/* Returns a new path that is flattened, converting all curved line segments into straight line approximations. The granularity of the approximations is controlled by `flatteningThreshold`  the maximum error tolerance (measured in points) for curves. */
+
+CG_EXTERN CGPathRef __nullable CGPathCreateCopyByFlattening(CGPathRef cg_nullable path, CGFloat flatteningThreshold) CG_AVAILABLE_STARTING(13.0, 16.0);
+
+/* Returns true if path1 and path2 overlap. */
+/* The trailing `UsingEvenOdd' will be removed soon. It's here temporarily for backward compatibility with an existing caller of `CGPathIntersectsPath' rdar://89310639. */
+CG_EXTERN bool CGPathIntersectsPathUsingEvenOdd(CGPathRef cg_nullable path1, CGPathRef cg_nullable path2, bool evenOddFillRule) CG_AVAILABLE_STARTING(13.0, 16.0);
+
 CF_ASSUME_NONNULL_END
 
 CF_IMPLICIT_BRIDGING_DISABLED
Clone this wiki locally