FFmpegContent::FFmpegContent (shared_ptr<const Film> film, cxml::ConstNodePtr node, int version, list<string>& notes)
: Content (film, node)
{
- video.reset (new VideoContent (this, film, node, version));
- audio.reset (new AudioContent (this, film, node));
- subtitle.reset (new SubtitleContent (this, film, node, version));
+ video = VideoContent::from_xml (this, film, node, version);
+ audio = AudioContent::from_xml (this, film, node);
+ subtitle = SubtitleContent::from_xml (this, film, node, version);
list<cxml::NodePtr> c = node->node_children ("SubtitleStream");
for (list<cxml::NodePtr>::const_iterator i = c.begin(); i != c.end(); ++i) {
DCPTime
FFmpegContent::full_length () const
{
- FrameRateChange const frc (video->frame_rate (), film()->video_frame_rate ());
+ FrameRateChange const frc (active_video_frame_rate (), film()->video_frame_rate ());
return DCPTime::from_frames (llrint (video->length_after_3d_combine() * frc.factor()), film()->video_frame_rate());
}
signal_changed (FFmpegContentProperty::SUBTITLE_STREAM);
}
-void
-FFmpegContent::changed (int property)
-{
- if (property == VideoContentProperty::FRAME_RATE && subtitle) {
- subtitle->set_video_frame_rate (video->frame_rate ());
- }
-}
-
vector<shared_ptr<FFmpegAudioStream> >
FFmpegContent::ffmpeg_audio_streams () const
{