| 1156 | } |
| 1157 | |
| 1158 | void NativeEngine::SetMatrices(const Napi::CallbackInfo& info) |
| 1159 | { |
| 1160 | const auto uniformData = info[0].As<Napi::External<UniformInfo>>().Data(); |
| 1161 | const auto matricesArray = info[1].As<Napi::Float32Array>(); |
| 1162 | |
| 1163 | const size_t elementLength = matricesArray.ElementLength(); |
| 1164 | assert(elementLength % 16 == 0); |
| 1165 | |
| 1166 | m_currentProgram->SetUniform(uniformData->Handle, gsl::span(matricesArray.Data(), elementLength), elementLength / 16); |
| 1167 | } |
| 1168 | |
| 1169 | void NativeEngine::SetMatrix2x2(const Napi::CallbackInfo& info) |
| 1170 | { |
nothing calls this directly
no test coverage detected