From 8941b58c8737d948f4c925955506da666ceb60ed Mon Sep 17 00:00:00 2001 From: David Robillard Date: Sun, 13 Jan 2013 01:05:24 +0000 Subject: Remove pointless typedef. git-svn-id: http://svn.drobilla.net/lad/trunk/machina@4944 a436a847-0d15-0410-975c-d299462d15a1 --- src/engine/Controller.cpp | 2 +- src/engine/Machine.cpp | 14 +++++++------- src/engine/SMFDriver.cpp | 2 +- src/engine/Updates.cpp | 16 ++++++++-------- src/engine/machina/Controller.hpp | 2 +- src/engine/machina/Driver.hpp | 10 +++++----- src/engine/machina/Machine.hpp | 14 +++++++------- src/engine/machina/Updates.hpp | 16 ++++++++-------- src/engine/machina/types.hpp | 2 -- 9 files changed, 38 insertions(+), 40 deletions(-) (limited to 'src/engine') diff --git a/src/engine/Controller.cpp b/src/engine/Controller.cpp index df60c97..ffe30e1 100644 --- a/src/engine/Controller.cpp +++ b/src/engine/Controller.cpp @@ -31,7 +31,7 @@ Controller::Controller(SPtr engine, Client::ClientModel& client_model) : _engine(engine) , _client_model(client_model) - , _updates(new UpdateBuffer(4096)) + , _updates(new Raul::RingBuffer(4096)) { _engine->driver()->set_update_sink(_updates); } diff --git a/src/engine/Machine.cpp b/src/engine/Machine.cpp index 3e5cf4d..63c37b8 100644 --- a/src/engine/Machine.cpp +++ b/src/engine/Machine.cpp @@ -212,9 +212,9 @@ Machine::earliest_node() const * Returns true if node was entered, or false if the maximum active nodes has been reached. */ bool -Machine::enter_node(Context& context, - SPtr node, - SPtr updates) +Machine::enter_node(Context& context, + SPtr node, + SPtr updates) { assert(!node->is_active()); @@ -243,9 +243,9 @@ Machine::enter_node(Context& context, /** Exit an active node at the current _time. */ void -Machine::exit_node(Context& context, - SPtr node, - SPtr updates) +Machine::exit_node(Context& context, + SPtr node, + SPtr updates) { node->exit(context.sink(), _time); write_set(updates, @@ -313,7 +313,7 @@ Machine::exit_node(Context& context, * with sample accuracy if necessary). */ uint32_t -Machine::run(Context& context, SPtr updates) +Machine::run(Context& context, SPtr updates) { if (_is_finished) { return 0; diff --git a/src/engine/SMFDriver.cpp b/src/engine/SMFDriver.cpp index 7401755..923c2fa 100644 --- a/src/engine/SMFDriver.cpp +++ b/src/engine/SMFDriver.cpp @@ -162,7 +162,7 @@ SMFDriver::run(SPtr machine, Raul::TimeStamp max_time) context.set_sink(this); context.time().set_slice(TimeStamp(max_time.unit(), 0, 0), context.time().beats_to_ticks(max_time)); - machine->run(context, SPtr()); + machine->run(context, SPtr()); } } // namespace Machina diff --git a/src/engine/Updates.cpp b/src/engine/Updates.cpp index 275ca2b..2775292 100644 --- a/src/engine/Updates.cpp +++ b/src/engine/Updates.cpp @@ -25,10 +25,10 @@ namespace Machina { void -write_set(SPtr buf, - uint64_t subject, - URIInt key, - const Raul::Atom& value) +write_set(SPtr buf, + uint64_t subject, + URIInt key, + const Raul::Atom& value) { const uint32_t update_type = UPDATE_SET; buf->write(sizeof(update_type), &update_type); @@ -41,10 +41,10 @@ write_set(SPtr buf, } uint32_t -read_set(SPtr buf, - uint64_t* subject, - URIInt* key, - Raul::Atom* value) +read_set(SPtr buf, + uint64_t* subject, + URIInt* key, + Raul::Atom* value) { uint32_t update_type; buf->read(sizeof(update_type), &update_type); diff --git a/src/engine/machina/Controller.hpp b/src/engine/machina/Controller.hpp index eb04c59..d5a7928 100644 --- a/src/engine/machina/Controller.hpp +++ b/src/engine/machina/Controller.hpp @@ -81,7 +81,7 @@ private: SPtr _engine; Client::ClientModel& _client_model; - SPtr _updates; + SPtr _updates; }; } diff --git a/src/engine/machina/Driver.hpp b/src/engine/machina/Driver.hpp index ea0bf8f..1ef0a7f 100644 --- a/src/engine/machina/Driver.hpp +++ b/src/engine/machina/Driver.hpp @@ -45,9 +45,9 @@ public: _machine = machine; } - SPtr update_sink() { return _updates; } + SPtr update_sink() { return _updates; } - void set_update_sink(SPtr b) { + void set_update_sink(SPtr b) { _updates = b; } @@ -65,9 +65,9 @@ public: virtual void finish_record() {} protected: - Raul::Forge& _forge; - SPtr _machine; - SPtr _updates; + Raul::Forge& _forge; + SPtr _machine; + SPtr _updates; }; } // namespace Machina diff --git a/src/engine/machina/Machine.hpp b/src/engine/machina/Machine.hpp index 1a8f267..d65cec4 100644 --- a/src/engine/machina/Machine.hpp +++ b/src/engine/machina/Machine.hpp @@ -67,7 +67,7 @@ public: // Audio context void reset(MIDISink* sink, Raul::TimeStamp time); - uint32_t run(Context& context, SPtr updates); + uint32_t run(Context& context, SPtr updates); // Any context inline Raul::TimeStamp time() const { return _time; } @@ -86,13 +86,13 @@ private: // Audio context SPtr earliest_node() const; - bool enter_node(Context& context, - SPtr node, - SPtr updates); + bool enter_node(Context& context, + SPtr node, + SPtr updates); - void exit_node(Context& context, - SPtr node, - SPtr updates); + void exit_node(Context& context, + SPtr node, + SPtr updates); static const size_t MAX_ACTIVE_NODES = 128; diff --git a/src/engine/machina/Updates.hpp b/src/engine/machina/Updates.hpp index cf29886..5f6a324 100644 --- a/src/engine/machina/Updates.hpp +++ b/src/engine/machina/Updates.hpp @@ -31,16 +31,16 @@ enum UpdateType { }; void -write_set(SPtr buf, - uint64_t subject, - URIInt key, - const Raul::Atom& value); +write_set(SPtr buf, + uint64_t subject, + URIInt key, + const Raul::Atom& value); uint32_t -read_set(SPtr buf, - uint64_t* subject, - URIInt* key, - Raul::Atom* value); +read_set(SPtr buf, + uint64_t* subject, + URIInt* key, + Raul::Atom* value); } // namespace Machina diff --git a/src/engine/machina/types.hpp b/src/engine/machina/types.hpp index d71e144..23d5f1c 100644 --- a/src/engine/machina/types.hpp +++ b/src/engine/machina/types.hpp @@ -26,8 +26,6 @@ namespace Machina { typedef unsigned char byte; -typedef Raul::RingBuffer UpdateBuffer; - typedef uint32_t URIInt; template -- cgit v1.2.1