summaryrefslogtreecommitdiff
path: root/src/lib/ffmpeg_content.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2013-04-02 23:33:46 +0100
committerCarl Hetherington <cth@carlh.net>2013-04-02 23:33:46 +0100
commit7ebb57db2013c9e929d44d0e547ab1f27c59cc7f (patch)
tree19959172e24e2cf097a2814aeb9e2298805d8a2b /src/lib/ffmpeg_content.cc
parent2343509c75673d3fad82a5d0eab9622a4d6902e3 (diff)
Add basic content information, and some other bits.
Diffstat (limited to 'src/lib/ffmpeg_content.cc')
-rw-r--r--src/lib/ffmpeg_content.cc12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/lib/ffmpeg_content.cc b/src/lib/ffmpeg_content.cc
index 5bff1cecc..c6344d567 100644
--- a/src/lib/ffmpeg_content.cc
+++ b/src/lib/ffmpeg_content.cc
@@ -28,6 +28,7 @@
#include "i18n.h"
using std::string;
+using std::stringstream;
using std::vector;
using std::list;
using boost::shared_ptr;
@@ -162,6 +163,17 @@ FFmpegContent::summary () const
return String::compose (_("Movie: %1"), file().filename ());
}
+string
+FFmpegContent::information () const
+{
+ stringstream s;
+
+ s << String::compose (_("%1 frames; %2 frames per second"), video_length(), video_frame_rate()) << "\n";
+ s << VideoContent::information ();
+
+ return s.str ();
+}
+
void
FFmpegContent::set_subtitle_stream (FFmpegSubtitleStream s)
{