X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fbeatcounter.cpp;h=2798056753d5f4b9810c733cb6957ad446f8442a;hb=26160b32405b004ecb9ddb5702f877da5881c82c;hp=e984034966b000158593ed9bc2407667ecb65966;hpb=184dc3f14feab183bcd84eca40f89c143ecbe41f;p=libs%2Fdemoscene.git diff --git a/source/beatcounter.cpp b/source/beatcounter.cpp index e984034..2798056 100644 --- a/source/beatcounter.cpp +++ b/source/beatcounter.cpp @@ -1,14 +1,19 @@ #include #include "beatcounter.h" -using namespace Msp; +namespace Msp { +namespace DemoScene { BeatCounter::BeatCounter(Resources &resources): text(resources.get_ui_font(), &resources.get_ui_text_technique()), instance(text) { text.set_alignment(GL::Text::CENTER); - instance.set_matrix(GL::Matrix::scaling(0.02f)); +} + +void BeatCounter::set_matrix(const GL::Matrix &m) +{ + instance.set_matrix(m); } void BeatCounter::beat(int b) @@ -20,3 +25,6 @@ void BeatCounter::render(GL::Renderer &renderer, const GL::Tag &tag) const { instance.render(renderer, tag); } + +} // namespace DemoScene +} // namespace Msp