mosra / magnum

Lightweight and modular C++11 graphics middleware for games and data visualization
https://magnum.graphics/
Other
4.74k stars 439 forks source link

ShaderProgram: Add glUniform for single value calls using non-v variants #592

Closed hugoam closed 1 year ago

hugoam commented 1 year ago

After discussion in this issue: https://github.com/mosra/magnum/issues/591 Here is a draft of adding the setUniform calls mapping to non-v variants of glUniform functions :)

mosra commented 1 year ago

So it was 16 variants after all, not 12 :) Thanks! I'll merge it ASAP, there isn't much else to do here.

codecov[bot] commented 1 year ago

Codecov Report

Merging #592 (6ba47d4) into master (eb382b3) will decrease coverage by 1.81%. The diff coverage is 21.92%.

@@            Coverage Diff             @@
##           master     #592      +/-   ##
==========================================
- Coverage   82.20%   80.38%   -1.82%     
==========================================
  Files         525      530       +5     
  Lines       36417    40738    +4321     
==========================================
+ Hits        29936    32748    +2812     
- Misses       6481     7990    +1509     
Impacted Files Coverage Δ
src/Magnum/GL/AbstractShaderProgram.cpp 26.02% <19.78%> (-14.97%) :arrow_down:
...rc/Magnum/GL/Implementation/ShaderProgramState.cpp 23.28% <27.27%> (-4.08%) :arrow_down:
src/Magnum/GL/AbstractShaderProgram.h 58.53% <100.00%> (-14.44%) :arrow_down:
src/Magnum/GL/Shader.h 40.74% <0.00%> (-50.17%) :arrow_down:
src/Magnum/GL/AbstractObject.h 50.00% <0.00%> (-50.00%) :arrow_down:
src/Magnum/Shaders/VectorGL.cpp 56.87% <0.00%> (-26.34%) :arrow_down:
src/Magnum/Shaders/PhongGL.cpp 55.08% <0.00%> (-24.58%) :arrow_down:
src/Magnum/GL/Implementation/ShaderState.cpp 52.63% <0.00%> (-24.30%) :arrow_down:
src/Magnum/Shaders/VertexColorGL.cpp 55.65% <0.00%> (-24.08%) :arrow_down:
src/Magnum/Shaders/FlatGL.cpp 62.66% <0.00%> (-23.53%) :arrow_down:
... and 53 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

mosra commented 1 year ago

Wow, the codecov reports are utter garbage. What is going on in there.

mosra commented 1 year ago

Merged as 40d132664fd2f2401a94120c915d01907790cbeb (I did a rebase against latest master), thank you!