From 1f8aca919df6ab2d2636cddaa30de1e388b4c09d Mon Sep 17 00:00:00 2001 From: Tim Redfern Date: Wed, 7 Aug 2013 17:20:03 +0100 Subject: adding logging --- rotord/src/rotor.cpp | 29 ++++++++++++++++++----------- rotord/src/rotor.h | 3 ++- 2 files changed, 20 insertions(+), 12 deletions(-) (limited to 'rotord') diff --git a/rotord/src/rotor.cpp b/rotord/src/rotor.cpp index 647313f..f96fbc3 100755 --- a/rotord/src/rotor.cpp +++ b/rotord/src/rotor.cpp @@ -62,7 +62,9 @@ void Node::update_params(const Time_spec& time){ //compute connected parameters } bool Signal_output::render(const float duration, const float framerate,string &xml_out){ //testing signal routes - cerr << "Rotor: Signal_output rendering " << duration << " seconds at " << framerate << " frames per second" << endl; + Logger& logger = Logger::get("Rotor"); + logger.information("SIgnal_output rendering "+ofToString(duration)+" seconds at "+ofToString(framerate)+" fps"); + float step=1.0f/framerate; float v=0.0f; float min=10000000.0f; @@ -210,7 +212,8 @@ bool Video_output::render(const float duration, const float framerate,const stri bool usingaudio=audioloader.setup(audio_filename); - cerr << "Rotor: Video_output rendering " << duration << " seconds at " << framerate << " fps, audio frame size: " << exporter.get_audio_framesize()<0) return ℑ //just return the previous frame if possible else return nullptr; }; diff --git a/rotord/src/rotor.h b/rotord/src/rotor.h index f9cafa2..85e7ac4 100755 --- a/rotord/src/rotor.h +++ b/rotord/src/rotor.h @@ -1043,7 +1043,7 @@ namespace Rotor { Video_loader(map &settings) { base_settings(settings); isLoaded=false; - string filename=find_setting(settings,"filename",""); + filename=find_setting(settings,"filename",""); if (filename!="") { load(find_setting(settings,"media_path","")+filename); } @@ -1056,6 +1056,7 @@ namespace Rotor { private: libav::decoder player; Image image; + string filename; }; /* class CVideo_loader: public Image_node { -- cgit v1.2.3