Skip to content

Commit

Permalink
Address reviews.
Browse files Browse the repository at this point in the history
  • Loading branch information
mandel-macaque committed Sep 30, 2021
1 parent daa50ed commit ba86323
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 8 deletions.
21 changes: 14 additions & 7 deletions src/Metal/MTLRasterizationRateLayerDescriptor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,11 @@
namespace Metal {
public partial class MTLRasterizationRateLayerDescriptor
{
/* Selectors reported as not working by introspection: https://github.com/xamarin/maccore/issues/1976
[NoMac]
#if !NET
[MacCatalyst (15,0)]
#else
[SupportedOSPlatform ("maccatalyst15.0")]
#endif
public double[] HorizontalSampleStorage {
get {
var width = (int)SampleCount.Width;
Expand All @@ -23,7 +26,11 @@ public double[] HorizontalSampleStorage {
}
}

[NoMac]
#if !NET
[MacCatalyst (15,0)]
#else
[SupportedOSPlatform ("maccatalyst15.0")]
#endif
public double[] VerticalSampleStorage {
get {
var height = (int)SampleCount.Height;
Expand All @@ -32,11 +39,11 @@ public double[] VerticalSampleStorage {
return floatArray;
}
}
*/
#if NET
[UnsupportedOSPlatform ("macos")]

#if !NET
[MacCatalyst (15,0)]
#else
[NoMac]
[SupportedOSPlatform ("maccatalyst15.0")]
#endif
static public MTLRasterizationRateLayerDescriptor Create (MTLSize sampleCount, float[] horizontal, float[] vertical)
{
Expand Down
5 changes: 4 additions & 1 deletion tests/monotouch-test/Metal/MTLDeviceTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,13 @@ public void Setup ()
TestRuntime.AssertXcodeVersion (9, 0);
}

#if __MACOS__
#if __MACOS__ || __MACCATALYST__
[Test]
public void GetAllDevicesTest ()
{
#if __MACCATALYST__
TestRuntime.AssertXcodeVersion (13, 0);
#endif
NSObject refObj = new NSObject();
var devices = MTLDevice.GetAllDevices(ref refObj, (IMTLDevice device, NSString notifyName) => { });

Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#if !__WATCHOS__
using Foundation;
using Metal;

Expand Down Expand Up @@ -51,3 +52,4 @@ public void SampleCount ()
});
}
}
#endif
2 changes: 2 additions & 0 deletions tests/monotouch-test/Metal/MTLRenderPipelineDescriptorTest.cs
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#if !__WATCHOS__
using Foundation;
using Metal;

Expand Down Expand Up @@ -136,3 +137,4 @@ public void TessellationControlPointIndexTypeTest ()
});
}
}
#endif

0 comments on commit ba86323

Please sign in to comment.