molecular
|
Compiled shader program. More...
#include <VulkanRenderCmdSinkProgram.h>
Classes | |
struct | ShaderSourceItem |
Public Types | |
enum | ShaderType { kFragmentShader, kVertexShader, kGeometryShader } |
Public Member Functions | |
void | Store (const std::string &vertexShaderSource, const std::string &pixelShaderSource) |
Compile source code. More... | |
void | Store (const ShaderSourceItem items[], size_t count, const char **transformFeedbackOutputs=nullptr, unsigned int tfOutputsCount=0) |
Compile source code. More... | |
const std::unordered_set< Hash > & | GetInputs () const |
Get set of uniforms and attributes. More... | |
void | SetUniform (Hash key, const float *values, int count=1) |
Set uniform values. More... | |
void | SetUniform (Hash key, const int *values, int count=1) |
Set uniform values. More... | |
void | SetUniform (Hash key, const unsigned int values[], int count=1) |
Set uniform values. More... | |
void | SetUniform (Hash key, const Vector2 *values, int count=1) |
Set uniform values. More... | |
void | SetUniform (Hash key, const Vector3 *values, int count=1) |
Set uniform values. More... | |
void | SetUniform (Hash key, const Vector4 *values, int count=1) |
Set uniform values. More... | |
void | SetUniform (Hash key, const IntVector2 *values, int count=1) |
Set uniform values. More... | |
void | SetUniform (Hash key, const IntVector3 *values, int count=1) |
Set uniform values. More... | |
void | SetUniform (Hash key, const IntVector4 *values, int count=1) |
Set uniform values. More... | |
void | SetUniform (Hash key, const UIntVector2 values[], int count=1) |
Set uniform values. More... | |
void | SetUniform (Hash key, const UIntVector3 values[], int count=1) |
Set uniform values. More... | |
void | SetUniform (Hash key, const UIntVector4 values[], int count=1) |
Set uniform values. More... | |
void | SetUniform (Hash key, const Matrix< 3, 3 > *values, int count=1) |
Set uniform values. More... | |
void | SetUniform (Hash key, const Matrix< 4, 4 > *values, int count=1) |
Set uniform values. More... | |
void | SetUniform (Hash key, const Texture *const *textures, int count=1) |
Set texture sampler uniform. More... | |
void | SetAttribute (Hash key, VertexBuffer *buffer, int components, VertexAttributeInfo::Type type, int stride=0, int offset=0, bool normalized=true) |
Set vertex attribute. More... | |
void | SetAttribute (Hash key, VertexBuffer *buffer, const VertexAttributeInfo &info) |
Compiled shader program.
|
inline |
Get set of uniforms and attributes.
void molecular::gfx::VulkanRenderCmdSink::Program::SetAttribute | ( | Hash | key, |
VertexBuffer * | buffer, | ||
int | components, | ||
VertexAttributeInfo::Type | type, | ||
int | stride = 0 , |
||
int | offset = 0 , |
||
bool | normalized = true |
||
) |
Set vertex attribute.
|
inline |
|
inline |
Set uniform values.
key | Hash of the uniform name, |
values | Pointer to the first (or single) value of the array. |
count | Elements in the array (or 1 for non-array uniforms). |
|
inline |
Set uniform values.
key | Hash of the uniform name, |
values | Pointer to the first (or single) value of the array. |
count | Elements in the array (or 1 for non-array uniforms). |
|
inline |
Set uniform values.
key | Hash of the uniform name, |
values | Pointer to the first (or single) value of the array. |
count | Elements in the array (or 1 for non-array uniforms). |
|
inline |
Set uniform values.
key | Hash of the uniform name, |
values | Pointer to the first (or single) value of the array. |
count | Elements in the array (or 1 for non-array uniforms). |
|
inline |
Set uniform values.
key | Hash of the uniform name, |
values | Pointer to the first (or single) value of the array. |
count | Elements in the array (or 1 for non-array uniforms). |
|
inline |
Set uniform values.
key | Hash of the uniform name, |
values | Pointer to the first (or single) value of the array. |
count | Elements in the array (or 1 for non-array uniforms). |
|
inline |
Set uniform values.
key | Hash of the uniform name, |
values | Pointer to the first (or single) value of the array. |
count | Elements in the array (or 1 for non-array uniforms). |
|
inline |
Set uniform values.
key | Hash of the uniform name, |
values | Pointer to the first (or single) value of the array. |
count | Elements in the array (or 1 for non-array uniforms). |
|
inline |
Set uniform values.
key | Hash of the uniform name, |
values | Pointer to the first (or single) value of the array. |
count | Elements in the array (or 1 for non-array uniforms). |
|
inline |
Set uniform values.
key | Hash of the uniform name, |
values | Pointer to the first (or single) value of the array. |
count | Elements in the array (or 1 for non-array uniforms). |
|
inline |
Set uniform values.
key | Hash of the uniform name, |
values | Pointer to the first (or single) value of the array. |
count | Elements in the array (or 1 for non-array uniforms). |
|
inline |
Set uniform values.
key | Hash of the uniform name, |
values | Pointer to the first (or single) value of the array. |
count | Elements in the array (or 1 for non-array uniforms). |
|
inline |
Set uniform values.
key | Hash of the uniform name, |
values | Pointer to the first (or single) value of the array. |
count | Elements in the array (or 1 for non-array uniforms). |
|
inline |
Set uniform values.
key | Hash of the uniform name, |
values | Pointer to the first (or single) value of the array. |
count | Elements in the array (or 1 for non-array uniforms). |
|
inline |
Set texture sampler uniform.
void molecular::gfx::VulkanRenderCmdSink::Program::Store | ( | const std::string & | vertexShaderSource, |
const std::string & | pixelShaderSource | ||
) |
Compile source code.
Legacy interface.
void molecular::gfx::VulkanRenderCmdSink::Program::Store | ( | const ShaderSourceItem | items[], |
size_t | count, | ||
const char ** | transformFeedbackOutputs = nullptr , |
||
unsigned int | tfOutputsCount = 0 |
||
) |
Compile source code.