XLE  v0.02.0
Classes | Public Member Functions | Public Attributes | List of all members
RenderCore::ResourceList< Type, Count > Class Template Reference

Used by the Metal interface to set many objects at once More...

#include <Resource.h>

Classes

struct  Utility< 0, WriteTo, Tuple >
 

Public Member Functions

 ResourceList (const std::initializer_list< const Type * > &initializers)
 
 ResourceList (unsigned offset, const std::initializer_list< const Type * > &initializers)
 
template<typename Tuple >
 ResourceList (const Tuple &initializers)
 
template<typename Tuple >
 ResourceList (unsigned offset, const Tuple &initializers)
 

Public Attributes

Type::UnderlyingType _buffers [Count]
 
unsigned _startingPoint
 

Detailed Description

template<typename Type, int Count>
class RenderCore::ResourceList< Type, Count >

Used by the Metal interface to set many objects at once

Some of the "RenderCore::Metal" interface functions allow the client to bind many of the same type of object to the pipeline, at the same time. For example, we might want to set multiple Metal::ShaderResourceView.

Normally, ResourceList is constructed with MakeResourceList.

For example:

@code
RenderCore::Metal::DeviceContext& context = ...;
RenderCore::Metal::ShaderResourceView& redTexture = ...;
RenderCore::Metal::ShaderResourceView& blueTexture = ...;
// Set redTexture and blueTexture to pixel shader texture slots
// zero and one:
context.BindPS(MakeResourceList(redTexture, blueTexture));
// Set redTexture and blueTexture to vertex shader texture slots
// 10 and 11
context.BindVS(MakeResourceList(10, redTexture, blueTexture));
\endcode
See also
RenderCore::MakeResourceList

The documentation for this class was generated from the following file: