#include "src/gpu/ganesh/gl/GrGLProgramDataManager.h"
#include "include/gpu/ganesh/gl/GrGLFunctions.h"
#include "include/gpu/ganesh/gl/GrGLInterface.h"
#include "include/private/base/SkAssert.h"
#include "src/core/SkSLTypeShared.h"
#include "src/gpu/ganesh/gl/GrGLGpu.h"
#include "src/gpu/ganesh/gl/GrGLUtil.h"
#define ASSERT_ARRAY_UPLOAD_IN_BOUNDS(UNI, COUNT) …
static constexpr GrGLint kUnusedUniform = …;
GrGLProgramDataManager::GrGLProgramDataManager(GrGLGpu* gpu, const UniformInfoArray& uniforms)
: … { … }
void GrGLProgramDataManager::setSamplerUniforms(const UniformInfoArray& samplers,
int startUnit) const { … }
void GrGLProgramDataManager::set1i(UniformHandle u, int32_t i) const { … }
void GrGLProgramDataManager::set1iv(UniformHandle u,
int arrayCount,
const int32_t v[]) const { … }
void GrGLProgramDataManager::set1f(UniformHandle u, float v0) const { … }
void GrGLProgramDataManager::set1fv(UniformHandle u,
int arrayCount,
const float v[]) const { … }
void GrGLProgramDataManager::set2i(UniformHandle u, int32_t i0, int32_t i1) const { … }
void GrGLProgramDataManager::set2iv(UniformHandle u,
int arrayCount,
const int32_t v[]) const { … }
void GrGLProgramDataManager::set2f(UniformHandle u, float v0, float v1) const { … }
void GrGLProgramDataManager::set2fv(UniformHandle u,
int arrayCount,
const float v[]) const { … }
void GrGLProgramDataManager::set3i(UniformHandle u, int32_t i0, int32_t i1, int32_t i2) const { … }
void GrGLProgramDataManager::set3iv(UniformHandle u,
int arrayCount,
const int32_t v[]) const { … }
void GrGLProgramDataManager::set3f(UniformHandle u, float v0, float v1, float v2) const { … }
void GrGLProgramDataManager::set3fv(UniformHandle u,
int arrayCount,
const float v[]) const { … }
void GrGLProgramDataManager::set4i(UniformHandle u,
int32_t i0,
int32_t i1,
int32_t i2,
int32_t i3) const { … }
void GrGLProgramDataManager::set4iv(UniformHandle u,
int arrayCount,
const int32_t v[]) const { … }
void GrGLProgramDataManager::set4f(UniformHandle u,
float v0,
float v1,
float v2,
float v3) const { … }
void GrGLProgramDataManager::set4fv(UniformHandle u,
int arrayCount,
const float v[]) const { … }
void GrGLProgramDataManager::setMatrix2f(UniformHandle u, const float matrix[]) const { … }
void GrGLProgramDataManager::setMatrix3f(UniformHandle u, const float matrix[]) const { … }
void GrGLProgramDataManager::setMatrix4f(UniformHandle u, const float matrix[]) const { … }
void GrGLProgramDataManager::setMatrix2fv(UniformHandle u, int arrayCount, const float m[]) const { … }
void GrGLProgramDataManager::setMatrix3fv(UniformHandle u, int arrayCount, const float m[]) const { … }
void GrGLProgramDataManager::setMatrix4fv(UniformHandle u, int arrayCount, const float m[]) const { … }
template<int N> struct set_uniform_matrix;
template<int N> inline void GrGLProgramDataManager::setMatrices(UniformHandle u,
int arrayCount,
const float matrices[]) const { … }
template<> struct set_uniform_matrix<2> { … };
template<> struct set_uniform_matrix<3> { … };
template<> struct set_uniform_matrix<4> { … };