MCPcopy Create free account
hub / github.com/SFML/SFML / update

Method update

examples/shader/Shader.cpp:68–73  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

66{
67public:
68 void update(float time, float x, float y) override
69 {
70 m_shader.setUniform("wave_phase", time);
71 m_shader.setUniform("wave_amplitude", sf::Vector2f(x * 40, y * 40));
72 m_shader.setUniform("blur_radius", (x + y) * 0.008f);
73 }
74
75 void draw(sf::RenderTarget& target, sf::RenderStates states) const override
76 {

Callers

nothing calls this directly

Calls 1

setUniformMethod · 0.80

Tested by

no test coverage detected