Saad Amin
Saad Amin

Reputation: 33

Is it possible to send uniform data to a struct in GLSL with one function call

Is it possible to send uniform data to a struct with one glUniform function call instead of having to individually setting the components of the struct with multiple glUniform function calls?

Upvotes: 1

Views: 314

Answers (1)

Nicol Bolas
Nicol Bolas

Reputation: 473184

There is no way to upload aggregations of values (outside of arrays of basic types) to a uniform in a single function call. If you need to upload bulk uniform data, it's best done via UBOs.

Upvotes: 2

Related Questions