summaryrefslogtreecommitdiff
path: root/rotord/rotor.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'rotord/rotor.cpp')
-rw-r--r--rotord/rotor.cpp14
1 files changed, 11 insertions, 3 deletions
diff --git a/rotord/rotor.cpp b/rotord/rotor.cpp
index f8d48c1..feb4a6c 100644
--- a/rotord/rotor.cpp
+++ b/rotord/rotor.cpp
@@ -326,7 +326,14 @@ static int open_codec_context(int *stream_idx,AVFormatContext *fmt_ctx, enum AVM
bool Render_context::load_audio(string &filename){
- //load audio into memory and create thumbnail
+ //load audio data from file
+ //what's the best way to use this? the model is background processing, and we want to update a progress bar
+ //could pass a function pointer to call when each chunk of data becomes available?
+ //should the data processing be the responsibility of an object or a function?
+ //in the case of the audio thumbnail, there will be just one place where its kept
+ //in the case of audio analysis, the daemon will pass each audio analysis object each chunk of data as it gets it
+ //there could even be an array of audio analysis functions to perform simultaneously?
+ //how about a vector of objects that subclass the base audio processor class?
av_register_all();
@@ -353,11 +360,12 @@ bool Render_context::load_audio(string &filename){
break;
}
}
-
- if (!stream)
+ if (!stream) {
cerr <<"Didn't find any audio stream in the file"<< endl;
return false;
}
+
+
return true;
}