mirror of
https://github.com/AxioDL/boo.git
synced 2025-12-16 00:17:06 +00:00
Metal platform fixes
This commit is contained in:
@@ -621,10 +621,6 @@ struct MetalShaderDataBinding : IShaderDataBinding
|
||||
}
|
||||
for (size_t i=0 ; i<texCount ; ++i)
|
||||
{
|
||||
#ifndef NDEBUG
|
||||
if (!texs[i])
|
||||
Log.report(logvisor::Fatal, "null texture %d provided to newShaderDataBinding", int(i));
|
||||
#endif
|
||||
m_texs[i] = texs[i];
|
||||
}
|
||||
}
|
||||
@@ -653,7 +649,8 @@ struct MetalShaderDataBinding : IShaderDataBinding
|
||||
[enc setVertexBuffer:GetBufferGPUResource(m_ubufs[i], b) offset:0 atIndex:i+2];
|
||||
}
|
||||
for (size_t i=0 ; i<m_texCount ; ++i)
|
||||
[enc setFragmentTexture:GetTextureGPUResource(m_texs[i], b) atIndex:i];
|
||||
if (m_texs[i])
|
||||
[enc setFragmentTexture:GetTextureGPUResource(m_texs[i], b) atIndex:i];
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -6,10 +6,7 @@
|
||||
#error ARC Required
|
||||
#endif
|
||||
|
||||
#include <Availability.h>
|
||||
|
||||
#if __MAC_OS_X_VERSION_MAX_ALLOWED >= 101100
|
||||
#define BOO_HAS_METAL 1
|
||||
#if BOO_HAS_METAL
|
||||
|
||||
#include <Metal/Metal.h>
|
||||
#include <QuartzCore/CAMetalLayer.h>
|
||||
@@ -35,7 +32,6 @@ struct MetalContext
|
||||
}
|
||||
|
||||
#else
|
||||
#define BOO_HAS_METAL 0
|
||||
namespace boo
|
||||
{
|
||||
struct MetalContext {};
|
||||
|
||||
Reference in New Issue
Block a user