Radeon ProRender


Gets an underlying Metal buffer from a tensor.

rml_status rmlGetMTLBufferFromTensor( rml_tensor tensor,
  void** buffer /* id<MTLBuffer>* */);


Metal Interoperation


Parameter Input/Output Description
tensor input A valid tensor handle.
buffer output A pointer to a resulting Metal buffer (id<MTLBuffer>).

Return and Status Codes

Returns a non-NULL Metal buffer in case of success and status:

  • RML_OK if the operation is successful
  • RML_ERROR_BAD_PARAMETER if tensor is invalid or buffer is NULL

To get more details in case of failure, call rmlGetLastError().

The resulting buffer is a reference counted by the tensor.