From 834835c99dd9fd182ca3116b5bc3e7ae8b3815ad Mon Sep 17 00:00:00 2001 From: Tim Redfern Date: Thu, 31 Oct 2013 12:57:59 +0000 Subject: thumbnail stills and svgs --- install_dependencies_linux.sh | 9 ++++++++- rotord/src/graph.h | 38 ++++++++++++++++++++++++++++++++++++- rotord/src/nodes_audio_analysis.cpp | 2 +- rotord/src/nodes_drawing.h | 7 +++++-- rotord/src/rotor.h | 1 + 5 files changed, 52 insertions(+), 5 deletions(-) diff --git a/install_dependencies_linux.sh b/install_dependencies_linux.sh index b9ca61f..c9fdfbf 100755 --- a/install_dependencies_linux.sh +++ b/install_dependencies_linux.sh @@ -69,4 +69,11 @@ sudo apt-get -y install libjsoncpp0 libjsoncpp-dev sudo mkdir /usr/lib/vamp sudo cp qm-vamp-plugins-1.7-amd64-linux/* /usr/lib/vamp -sudo apt-get install librsvg2-2 librsvg2-dev +git clone https://github.com/bbcrd/bbc-vamp-plugins.git +cd bbc-vamp-plugins +make -f Makefile.linux +sudo mv bbc-vamp-plugins.so bbc-vamp-plugins.cat bbc-vamp-plugins.n3 /usr/local/lib/vamp/ +cd .. +sudo rm -r bbc-vamp-plugins + +sudo apt-get -y install librsvg2-2 librsvg2-dev diff --git a/rotord/src/graph.h b/rotord/src/graph.h index 6f2ee79..2f8843d 100644 --- a/rotord/src/graph.h +++ b/rotord/src/graph.h @@ -97,6 +97,43 @@ namespace Rotor { class Thumbnailer{ public: bool make(const string &inputfilename,int w,int h,const string &outputfilename) { + Poco::StringTokenizer t1(inputfilename,"."); + if (t1.count()>1) { + if (t1[t1.count()-1]=="svg"){ + cerr<<"found an svg"< tempos; vector intensities; vector times; + auto g=++analysers["segmenter"].features.begin(); for (auto f=analysers["segmenter"].features.begin();g!=analysers["segmenter"].features.end();f++,g++,i++){ cerr<<"segment "<first<<" to "<first<first); diff --git a/rotord/src/nodes_drawing.h b/rotord/src/nodes_drawing.h index b26841e..1bd6375 100644 --- a/rotord/src/nodes_drawing.h +++ b/rotord/src/nodes_drawing.h @@ -3,7 +3,6 @@ #include "rotor.h" #include -#include namespace Rotor { class Draw_node: public Image_node { @@ -217,6 +216,7 @@ namespace Rotor { }; class Svg: public Draw_node { public: + //rsvg should be cleanup? Svg(){ title="SVG"; description="Draws svg files"; @@ -238,7 +238,10 @@ namespace Rotor { } else cerr<<"Rotor: SVG failed to load "<value< &_settings) { return new Svg(_settings);}; void vector_output(cairo_t * cr,const Frame_spec &frame){ //to make it resolution independent diff --git a/rotord/src/rotor.h b/rotord/src/rotor.h index f179efd..50ae266 100644 --- a/rotord/src/rotor.h +++ b/rotord/src/rotor.h @@ -75,6 +75,7 @@ Requirements #include #include +#include #include "Poco/Net/HTTPResponse.h" #include "Poco/Logger.h" -- cgit v1.2.3