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

Method onDraw

examples/sound_effects/SoundEffects.cpp:563–573  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

561 }
562
563 void onDraw(sf::RenderTarget& target, sf::RenderStates states) const override
564 {
565 auto statesCopy(states);
566 statesCopy.transform = sf::Transform::Identity;
567 statesCopy.transform.translate(m_position - sf::Vector2f({20.f, 0.f}));
568
569 target.draw(m_listener, states);
570 target.draw(m_soundShape, statesCopy);
571 target.draw(m_currentVelocity, states);
572 target.draw(m_currentFactor, states);
573 }
574
575 void onStart() override
576 {

Callers

nothing calls this directly

Calls 1

drawMethod · 0.45

Tested by

no test coverage detected