Change serialized name for wrapped Metal Objects

Change WrappedMTL<TYPE>* -> MTL<TYPE>

Before

<ResourceId name="Device" typename="WrappedMTLDevice *" width="8">4</ResourceId>
<ResourceId name="Library" typename="WrappedMTLLibrary *" width="8">9</ResourceId>
<ResourceId name="vertexFunction" typename="WrappedMTLFunction *" width="8">10</ResourceId>

After
<ResourceId name="Device" typename="MTLDevice" width="8">4</ResourceId>
<ResourceId name="Library" typename="MTLLibrary" width="8">9</ResourceId>
<ResourceId name="vertexFunction" typename="MTLFunction" width="8">10</ResourceId>
This commit is contained in:
Jake Turner
2022-04-04 08:54:54 +01:00
committed by Baldur Karlsson
parent 823ecdbbf7
commit ea5cfa6e95
+9 -3
View File
@@ -37,9 +37,15 @@
// These serialise overloads will fetch the ID during capture, serialise the ID
// directly as-if it were the original type, then on replay load up the resource if available.
#define DECLARE_WRAPPED_TYPE_SERIALISE(CPPTYPE) \
class WrappedMTL##CPPTYPE; \
DECLARE_REFLECTION_STRUCT(WrappedMTL##CPPTYPE *)
#define DECLARE_WRAPPED_TYPE_SERIALISE(CPPTYPE) \
class WrappedMTL##CPPTYPE; \
template <> \
inline rdcliteral TypeName<WrappedMTL##CPPTYPE *>() \
{ \
return STRING_LITERAL(STRINGIZE(MTL##CPPTYPE)); \
} \
template <class SerialiserType> \
void DoSerialise(SerialiserType &ser, WrappedMTL##CPPTYPE *&el);
METALCPP_WRAPPED_PROTOCOLS(DECLARE_WRAPPED_TYPE_SERIALISE);
#undef DECLARE_WRAPPED_TYPE_SERIALISE