Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/xcode16' into dev/rolf/xcode16-b…
Browse files Browse the repository at this point in the history
…1-gamekit
  • Loading branch information
rolfbjarne committed Aug 22, 2024
2 parents 600c7cc + 510d872 commit 1778b97
Show file tree
Hide file tree
Showing 18 changed files with 151 additions and 329 deletions.
124 changes: 105 additions & 19 deletions src/coreanimation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -669,6 +669,19 @@ interface CALayer : CAMediaTiming, NSSecureCoding {
[Static]
[Export ("cornerCurveExpansionFactor:")]
nfloat GetCornerCurveExpansionFactor ([BindAs (typeof (CACornerCurve))] NSString curve);

[NoWatch]
[NoTV]
[iOS (17, 0)]
[MacCatalyst (17, 0)]
[Mac (14, 0)]
[Export ("wantsExtendedDynamicRangeContent")]
bool WantsExtendedDynamicRangeContent { get; set; }

[Mac (15, 0), iOS (18, 0), TV (18, 0), MacCatalyst (18, 0), NoWatch]
[Export ("toneMapMode")]
[BindAs (typeof (CAToneMapMode))]
NSString ToneMapMode { get; set; }
}

[NoWatch] // headers not updated
Expand All @@ -683,6 +696,17 @@ enum CACornerCurve {
Continuous,
}

[Mac (15, 0), iOS (18, 0), TV (18, 0), MacCatalyst (18, 0), NoWatch]
enum CAToneMapMode {
[DefaultEnumValue]
[Field ("CAToneMapModeAutomatic")]
Automatic,
[Field ("CAToneMapModeNever")]
Never,
[Field ("CAToneMapModeIfSupported")]
IfSupported,
}

interface ICAMetalDrawable { }

/// <summary>Interface that defines a protocol for a display buffer at the metal layer.</summary>
Expand Down Expand Up @@ -1229,7 +1253,7 @@ interface ICALayerDelegate { }
#elif MONOMAC
[Protocol (FormalSince = "10.12")]
#elif WATCH
[Protocol (FormalSince = "3.0"]
[Protocol (FormalSince = "3.0")]
#else
[Protocol]
#endif
Expand Down Expand Up @@ -1437,7 +1461,7 @@ interface ICAAnimationDelegate { }
#elif MONOMAC
[Protocol (FormalSince = "10.12")]
#elif WATCH
[Protocol (FormalSince = "3.0"]
[Protocol (FormalSince = "3.0")]
#else
[Synthetic]
#endif
Expand Down Expand Up @@ -1530,8 +1554,25 @@ interface CASpringAnimation {
[Export ("initialVelocity")]
nfloat InitialVelocity { get; set; }

[iOS (17, 0), TV (17, 0), MacCatalyst (17, 0), Mac (14, 0), NoWatch]
[Export ("settlingDuration")]
double /* CFTimeInterval */ SettlingDuration { get; }

[iOS (17, 0), TV (17, 0), MacCatalyst (17, 0), Mac (14, 0), NoWatch]
[Export ("allowsOverdamping")]
bool AllowsOverdamping { get; set; }

[iOS (17, 0), TV (17, 0), MacCatalyst (17, 0), Mac (14, 0), NoWatch]
[Export ("initWithPerceptualDuration:bounce:")]
NativeHandle Constructor (double /* CFTimeInterval */ perceptualDuration, nfloat bounce);

[iOS (17, 0), TV (17, 0), MacCatalyst (17, 0), Mac (14, 0), NoWatch]
[Export ("perceptualDuration")]
double /* CFTimeInterval */ PerceptualDuration { get; }

[iOS (17, 0), TV (17, 0), MacCatalyst (17, 0), Mac (14, 0), NoWatch]
[Export ("bounce")]
nfloat Bounce { get; }
}

/// <summary>Keyframe-based animation support.</summary>
Expand Down Expand Up @@ -2195,23 +2236,14 @@ interface CAEmitterBehavior : NSSecureCoding {

[Internal]
[Static]
[NoiOS]
[NoTV]
[NoWatch]
[NoMacCatalyst]
partial interface CARendererOptionKeys {
[Field ("kCARendererColorSpace")]
NSString ColorSpace { get; }

[NoMacCatalyst]
[Field ("kCARendererMetalCommandQueue")]
NSString MetalCommandQueue { get; }
}

[NoiOS]
[NoTV]
[NoWatch]
[NoMacCatalyst]
[StrongDictionary ("CARendererOptionKeys")]
interface CARendererOptions {

Expand All @@ -2223,19 +2255,12 @@ interface CARendererOptions {
IMTLCommandQueue MetalCommandQueue { get; set; }
}

// 10.5 on the Mac
[NoiOS]
[NoTV]
[NoWatch]
[NoMacCatalyst]
[BaseType (typeof (NSObject))]
interface CARenderer {
[NoMacCatalyst]
[Static]
[Export ("rendererWithMTLTexture:options:")]
CARenderer Create (IMTLTexture tex, [NullAllowed] NSDictionary dict);

[NoMacCatalyst]
[Static]
[Wrap ("Create (tex, options.GetDictionary ())")]
CARenderer Create (IMTLTexture tex, [NullAllowed] CARendererOptions options);
Expand Down Expand Up @@ -2272,7 +2297,6 @@ interface CARenderer {
[Export ("endFrame")]
void EndFrame ();

[NoMacCatalyst]
[Export ("setDestination:")]
void SetDestination (IMTLTexture tex);
}
Expand Down Expand Up @@ -2302,5 +2326,67 @@ interface CAEdrMetadata : NSCopying, NSSecureCoding {
[Static]
[Export ("available")]
bool Available { [Bind ("isAvailable")] get; }

[Static]
[Mac (14, 0), iOS (17, 0), MacCatalyst (17, 0)]
[Export ("HLGMetadataWithAmbientViewingEnvironment:")]
CAEdrMetadata GetHlgMetadata (NSData ambientViewingEnvironmentData);
}

[BaseType (typeof (NSObject))]
[iOS (17, 0), TV (17, 0), Mac (14, 0), MacCatalyst (17, 0), NoWatch]
[DisableDefaultCtor]
interface CAMetalDisplayLinkUpdate {
[Export ("drawable")]
ICAMetalDrawable Drawable { get; }

[Export ("targetTimestamp")]
double /* CFTimeInterval */ TargetTimestamp { get; }

[Export ("targetPresentationTimestamp")]
double /* CFTimeInterval */ TargetPresentationTimestamp { get; }
}

[Protocol (BackwardsCompatibleCodeGeneration = false), Model]
[BaseType (typeof (NSObject))]
[iOS (17, 0), TV (17, 0), Mac (14, 0), MacCatalyst (17, 0), NoWatch]
interface CAMetalDisplayLinkDelegate {
[Abstract]
[Export ("metalDisplayLink:needsUpdate:")]
void NeedsUpdate (CAMetalDisplayLink link, CAMetalDisplayLinkUpdate update);
}

interface ICAMetalDisplayLinkDelegate { }

[BaseType (typeof (NSObject))]
[iOS (17, 0), TV (17, 0), Mac (14, 0), MacCatalyst (17, 0), NoWatch]
[DisableDefaultCtor]
interface CAMetalDisplayLink {
[Export ("initWithMetalLayer:")]
NativeHandle Constructor (CAMetalLayer layer);

[Export ("addToRunLoop:forMode:")]
void AddToRunLoop (NSRunLoop runloop, NSRunLoopMode mode);

[Export ("removeFromRunLoop:forMode:")]
void RemoveFromRunLoop (NSRunLoop runloop, NSRunLoopMode mode);

[Export ("invalidate")]
void Invalidate ();

[Export ("delegate", ArgumentSemantic.Weak), NullAllowed]
NSObject WeakDelegate { get; set; }

[Wrap ("WeakDelegate"), NullAllowed]
ICAMetalDisplayLinkDelegate Delegate { get; set; }

[Export ("preferredFrameLatency")]
float PreferredFrameLatency { get; set; }

[Export ("preferredFrameRateRange")]
CAFrameRateRange PreferredFrameRateRange { get; set; }

[Export ("paused")]
bool Paused { [Bind ("isPaused")] get; set; }
}
}
13 changes: 13 additions & 0 deletions src/shazamkit.cs
Original file line number Diff line number Diff line change
Expand Up @@ -82,19 +82,32 @@ interface SHCatalog {
[iOS (15, 0), Mac (12, 0), Watch (8, 0), TV (15, 0), MacCatalyst (15, 0)]
[BaseType (typeof (SHCatalog))]
interface SHCustomCatalog {
[Watch (11, 0), TV (18, 0), Mac (15, 0), iOS (18, 0), MacCatalyst (18, 0)]
[Export ("initWithDataRepresentation:error:")]
NativeHandle Constructor (NSData data, out NSError error);

[Export ("addReferenceSignature:representingMediaItems:error:")]
bool Add (SHSignature signature, SHMediaItem [] mediaItems, [NullAllowed] out NSError error);

[Export ("addCustomCatalogFromURL:error:")]
bool Add (NSUrl url, [NullAllowed] out NSError error);

[Deprecated (PlatformName.MacOSX, 14, 0, message: "Use 'DataRepresentation' instead.")]
[Deprecated (PlatformName.iOS, 17, 0, message: "Use 'DataRepresentation' instead.")]
[Deprecated (PlatformName.TvOS, 17, 0, message: "Use 'DataRepresentation' instead.")]
[Deprecated (PlatformName.WatchOS, 10, 0, message: "Use 'DataRepresentation' instead.")]
[Deprecated (PlatformName.MacCatalyst, 17, 0, message: "Use 'DataRepresentation' instead.")]
[Export ("writeToURL:error:")]
bool Write (NSUrl url, [NullAllowed] out NSError error);

[Static]
[Export ("new")]
[return: Release]
SHCustomCatalog Create ();

[Watch (11, 0), TV (18, 0), Mac (15, 0), iOS (18, 0), MacCatalyst (18, 0)]
[Export ("dataRepresentation", ArgumentSemantic.Strong)]
NSData DataRepresentation { get; }
}

[iOS (15, 0), Mac (12, 0), Watch (8, 0), TV (15, 0), MacCatalyst (15, 0)]
Expand Down
33 changes: 33 additions & 0 deletions tests/cecil-tests/Documentation.KnownFailures.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6179,6 +6179,9 @@ F:CoreAnimation.CATextLayerTruncationMode.End
F:CoreAnimation.CATextLayerTruncationMode.Middle
F:CoreAnimation.CATextLayerTruncationMode.None
F:CoreAnimation.CATextLayerTruncationMode.Start
F:CoreAnimation.CAToneMapMode.Automatic
F:CoreAnimation.CAToneMapMode.IfSupported
F:CoreAnimation.CAToneMapMode.Never
F:CoreAnimation.CATransform3D.Identity
F:CoreAnimation.CATransform3D.M11
F:CoreAnimation.CATransform3D.M12
Expand Down Expand Up @@ -28640,6 +28643,7 @@ M:CoreAnimation.CAEdrMetadata.Copy(Foundation.NSZone)
M:CoreAnimation.CAEdrMetadata.EncodeTo(Foundation.NSCoder)
M:CoreAnimation.CAEdrMetadata.GetHdr10Metadata(Foundation.NSData,Foundation.NSData,System.Single)
M:CoreAnimation.CAEdrMetadata.GetHdr10Metadata(System.Single,System.Single,System.Single)
M:CoreAnimation.CAEdrMetadata.GetHlgMetadata(Foundation.NSData)
M:CoreAnimation.CAEmitterCell.DefaultValueForKey(System.String)
M:CoreAnimation.CAEmitterCell.EmitterCell
M:CoreAnimation.CAEmitterCell.EncodeTo(Foundation.NSCoder)
Expand Down Expand Up @@ -28714,6 +28718,12 @@ M:CoreAnimation.CAMediaTimingFunction.EncodeTo(Foundation.NSCoder)
M:CoreAnimation.CAMediaTimingFunction.FromControlPoints(System.Single,System.Single,System.Single,System.Single)
M:CoreAnimation.CAMediaTimingFunction.FromName(Foundation.NSString)
M:CoreAnimation.CAMediaTimingFunction.GetControlPoint(System.IntPtr)
M:CoreAnimation.CAMetalDisplayLink.#ctor(CoreAnimation.CAMetalLayer)
M:CoreAnimation.CAMetalDisplayLink.AddToRunLoop(Foundation.NSRunLoop,Foundation.NSRunLoopMode)
M:CoreAnimation.CAMetalDisplayLink.Dispose(System.Boolean)
M:CoreAnimation.CAMetalDisplayLink.Invalidate
M:CoreAnimation.CAMetalDisplayLink.RemoveFromRunLoop(Foundation.NSRunLoop,Foundation.NSRunLoopMode)
M:CoreAnimation.CAMetalDisplayLinkDelegate.NeedsUpdate(CoreAnimation.CAMetalDisplayLink,CoreAnimation.CAMetalDisplayLinkUpdate)
M:CoreAnimation.CAMetalLayer.NextDrawable
M:CoreAnimation.CAOpenGLLayer.CanDrawInCGLContext(OpenGL.CGLContext,OpenGL.CGLPixelFormat,System.Double,CoreVideo.CVTimeStamp@)
M:CoreAnimation.CAOpenGLLayer.CopyCGLPixelFormatForDisplayMask(System.UInt32)
Expand All @@ -28725,6 +28735,7 @@ M:CoreAnimation.CAOpenGLLayer.Release(OpenGL.CGLPixelFormat)
M:CoreAnimation.CAPropertyAnimation.FromKeyPath(System.String)
M:CoreAnimation.CARenderer.AddUpdate(CoreGraphics.CGRect)
M:CoreAnimation.CARenderer.BeginFrame(System.Double,CoreVideo.CVTimeStamp@)
M:CoreAnimation.CARenderer.BeginFrame(System.Double,Foundation.NSObject@)
M:CoreAnimation.CARenderer.BeginFrame(System.Double)
M:CoreAnimation.CARenderer.Create(Metal.IMTLTexture,CoreAnimation.CARendererOptions)
M:CoreAnimation.CARenderer.Create(Metal.IMTLTexture,Foundation.NSDictionary)
Expand All @@ -28740,6 +28751,7 @@ M:CoreAnimation.CAScrollLayer.Create
M:CoreAnimation.CAScrollLayer.ScrollToPoint(CoreGraphics.CGPoint)
M:CoreAnimation.CAScrollLayer.ScrollToRect(CoreGraphics.CGRect)
M:CoreAnimation.CAShapeLayer.Create
M:CoreAnimation.CASpringAnimation.#ctor(System.Double,System.Runtime.InteropServices.NFloat)
M:CoreAnimation.CASpringAnimation.FromKeyPath(System.String)
M:CoreAnimation.CATextLayer.Create
M:CoreAnimation.CATextLayer.SetFont(AppKit.NSFont)
Expand Down Expand Up @@ -28782,6 +28794,7 @@ M:CoreAnimation.ICALayerDelegate.DisplayLayer(CoreAnimation.CALayer)
M:CoreAnimation.ICALayerDelegate.DrawLayer(CoreAnimation.CALayer,CoreGraphics.CGContext)
M:CoreAnimation.ICALayerDelegate.LayoutSublayersOfLayer(CoreAnimation.CALayer)
M:CoreAnimation.ICALayerDelegate.WillDrawLayer(CoreAnimation.CALayer)
M:CoreAnimation.ICAMetalDisplayLinkDelegate.NeedsUpdate(CoreAnimation.CAMetalDisplayLink,CoreAnimation.CAMetalDisplayLinkUpdate)
M:CoreAudioKit.AUAudioUnitViewConfiguration.EncodeTo(Foundation.NSCoder)
M:CoreAudioKit.AUAudioUnitViewControllerExtensions.GetSupportedViewConfigurations(AudioUnit.AUAudioUnit,CoreAudioKit.AUAudioUnitViewConfiguration[])
M:CoreAudioKit.AUAudioUnitViewControllerExtensions.SelectViewConfiguration(AudioUnit.AUAudioUnit,CoreAudioKit.AUAudioUnitViewConfiguration)
Expand Down Expand Up @@ -45893,6 +45906,7 @@ M:SharedWithYouCore.SWUpdateCollaborationParticipantsAction.Copy(Foundation.NSZo
M:SharedWithYouCore.SWUpdateCollaborationParticipantsAction.EncodeTo(Foundation.NSCoder)
M:ShazamKit.ISHSessionDelegate.DidFindMatch(ShazamKit.SHSession,ShazamKit.SHMatch)
M:ShazamKit.ISHSessionDelegate.DidNotFindMatch(ShazamKit.SHSession,ShazamKit.SHSignature,Foundation.NSError)
M:ShazamKit.SHCustomCatalog.#ctor(Foundation.NSData,Foundation.NSError@)
M:ShazamKit.SHCustomCatalog.Add(Foundation.NSUrl,Foundation.NSError@)
M:ShazamKit.SHCustomCatalog.Add(ShazamKit.SHSignature,ShazamKit.SHMediaItem[],Foundation.NSError@)
M:ShazamKit.SHCustomCatalog.Create
Expand Down Expand Up @@ -59344,9 +59358,11 @@ P:CoreAnimation.CALayer.Sublayers
P:CoreAnimation.CALayer.SublayerTransform
P:CoreAnimation.CALayer.SuperLayer
P:CoreAnimation.CALayer.TimeOffset
P:CoreAnimation.CALayer.ToneMapMode
P:CoreAnimation.CALayer.Transform
P:CoreAnimation.CALayer.Transition
P:CoreAnimation.CALayer.VisibleRect
P:CoreAnimation.CALayer.WantsExtendedDynamicRangeContent
P:CoreAnimation.CALayer.WeakDelegate
P:CoreAnimation.CALayer.ZPosition
P:CoreAnimation.CAMediaTiming.AutoReverses
Expand All @@ -59362,6 +59378,14 @@ P:CoreAnimation.CAMediaTimingFunction.EaseIn
P:CoreAnimation.CAMediaTimingFunction.EaseInEaseOut
P:CoreAnimation.CAMediaTimingFunction.EaseOut
P:CoreAnimation.CAMediaTimingFunction.Linear
P:CoreAnimation.CAMetalDisplayLink.Delegate
P:CoreAnimation.CAMetalDisplayLink.Paused
P:CoreAnimation.CAMetalDisplayLink.PreferredFrameLatency
P:CoreAnimation.CAMetalDisplayLink.PreferredFrameRateRange
P:CoreAnimation.CAMetalDisplayLink.WeakDelegate
P:CoreAnimation.CAMetalDisplayLinkUpdate.Drawable
P:CoreAnimation.CAMetalDisplayLinkUpdate.TargetPresentationTimestamp
P:CoreAnimation.CAMetalDisplayLinkUpdate.TargetTimestamp
P:CoreAnimation.CAMetalLayer.AllowsNextDrawableTimeout
P:CoreAnimation.CAMetalLayer.ColorSpace
P:CoreAnimation.CAMetalLayer.DeveloperHudProperties
Expand Down Expand Up @@ -59415,9 +59439,12 @@ P:CoreAnimation.CAShapeLayer.Path
P:CoreAnimation.CAShapeLayer.StrokeColor
P:CoreAnimation.CAShapeLayer.StrokeEnd
P:CoreAnimation.CAShapeLayer.StrokeStart
P:CoreAnimation.CASpringAnimation.AllowsOverdamping
P:CoreAnimation.CASpringAnimation.Bounce
P:CoreAnimation.CASpringAnimation.Damping
P:CoreAnimation.CASpringAnimation.InitialVelocity
P:CoreAnimation.CASpringAnimation.Mass
P:CoreAnimation.CASpringAnimation.PerceptualDuration
P:CoreAnimation.CASpringAnimation.SettlingDuration
P:CoreAnimation.CASpringAnimation.Stiffness
P:CoreAnimation.CATextLayer.AllowsFontSubpixelQuantization
Expand Down Expand Up @@ -73709,6 +73736,7 @@ P:SharedWithYouCore.SWCollaborationOption.Selected
P:SharedWithYouCore.SWCollaborationOptionsGroup.TypeIdentifier
P:ShazamKit.SHCatalog.MaximumQuerySignatureDuration
P:ShazamKit.SHCatalog.MinimumQuerySignatureDuration
P:ShazamKit.SHCustomCatalog.DataRepresentation
P:ShazamKit.SHMatch.MediaItems
P:ShazamKit.SHMatch.QuerySignature
P:ShazamKit.SHMatchedMediaItem.FrequencySkew
Expand Down Expand Up @@ -78537,12 +78565,17 @@ T:CoreAnimation.CACornerMask
T:CoreAnimation.CAEdrMetadata
T:CoreAnimation.CAFrameRateRange
T:CoreAnimation.CAGradientLayerType
T:CoreAnimation.CAMetalDisplayLink
T:CoreAnimation.CAMetalDisplayLinkDelegate
T:CoreAnimation.CAMetalDisplayLinkUpdate
T:CoreAnimation.CAOpenGLLayer
T:CoreAnimation.CARenderer
T:CoreAnimation.CARendererOptions
T:CoreAnimation.CATextLayerAlignmentMode
T:CoreAnimation.CATextLayerTruncationMode
T:CoreAnimation.CAToneMapMode
T:CoreAnimation.CATransform3D
T:CoreAnimation.ICAMetalDisplayLinkDelegate
T:CoreAudioKit.AUAudioUnitViewControllerExtensions
T:CoreAudioKit.AUGenericViewDisplayFlags
T:CoreAudioKit.IAUCustomViewPersistentData
Expand Down
Loading

0 comments on commit 1778b97

Please sign in to comment.