metal: add all the files
This commit is contained in:
16
include/renderer_mtl/objc_helper.hpp
Normal file
16
include/renderer_mtl/objc_helper.hpp
Normal file
@@ -0,0 +1,16 @@
|
||||
#pragma once
|
||||
|
||||
#include <string>
|
||||
|
||||
#include <Metal/Metal.hpp>
|
||||
|
||||
namespace Metal {
|
||||
|
||||
dispatch_data_t createDispatchData(const void* data, size_t size);
|
||||
|
||||
} // namespace Metal
|
||||
|
||||
// Cast from std::string to NS::String*
|
||||
inline NS::String* toNSString(const std::string& str) {
|
||||
return NS::String::string(str.c_str(), NS::ASCIIStringEncoding);
|
||||
}
|
||||
Reference in New Issue
Block a user