@@ -515,7 +515,7 @@ static MTLDepthClipMode SDLToMetal_DepthClipMode(
515
515
516
516
typedef struct MetalPipelineCache
517
517
{
518
- id <MTLBinaryArchive> pipelineCache;
518
+ @ available (macOS 11.0 , iOS 14.0 , tvOS 14.0 , *) id <MTLBinaryArchive> pipelineCache;
519
519
size_t checksumSize;
520
520
void * checksumData;
521
521
size_t cacheBlobSize;
@@ -1120,7 +1120,7 @@ static void METAL_ReleasePipelineCache(
1120
1120
pipelineDescriptor = [MTLRenderPipelineDescriptor new ];
1121
1121
1122
1122
/*
1123
- if(@available(macOS 11.0, *))
1123
+ if(@available(macOS 11.0, iOS 14.0, tvOS 14.0, *))
1124
1124
{
1125
1125
if(pipelineCache->pipelineCache != nil)
1126
1126
{
@@ -1217,7 +1217,7 @@ static void METAL_ReleasePipelineCache(
1217
1217
}
1218
1218
1219
1219
/*
1220
- if(@available(macOS 11.0, *))
1220
+ if(@available(macOS 11.0, iOS 14.0, tvOS 14.0, *))
1221
1221
{
1222
1222
if(pipelineCache != NULL){
1223
1223
[pipelineCache->pipelineCache addRenderPipelineFunctionsWithDescriptor:pipelineDescriptor error:&error];
@@ -1260,7 +1260,7 @@ static void METAL_ReleasePipelineCache(
1260
1260
{
1261
1261
// Implementing it is easy, but there's not way to get the binary data out of MTLBinaryArchive without bouncing it to a file first
1262
1262
/*
1263
- if(@available(macOS 11.0, *)){
1263
+ if(@available(macOS 11.0, iOS 14.0, tvOS 14.0, *)){
1264
1264
@autoreleasepool {
1265
1265
MetalRenderer* renderer = (MetalRenderer*)driverData;
1266
1266
MetalPipelineCache* pipelineCache = (MetalPipelineCache*)SDL_malloc(sizeof(MetalPipelineCache));
0 commit comments