_player = f->make_player ();
_player->disable_audio ();
- _player->Video.connect (boost::bind (&FilmViewer::process_video, this, _1, _2, _4));
+ _player->Video.connect (boost::bind (&FilmViewer::process_video, this, _1, _2, _5));
_player->Changed.connect (boost::bind (&FilmViewer::player_changed, this, _1));
calculate_sizes ();
Ratio const * container = _film->container ();
- float const panel_ratio = static_cast<float> (_panel_size.width) / _panel_size.height;
+ float const panel_ratio = _panel_size.ratio ();
float const film_ratio = container ? container->ratio () : 1.78;
if (panel_ratio < film_ratio) {
/* Player::video_position is the time after the last frame that we received.
We want to see the one before it, so we need to go back 2.
*/
+
+ Time p = _player->video_position() - _film->video_frames_to_time (2);
+ if (p < 0) {
+ p = 0;
+ }
- _player->seek (_player->video_position() - _film->video_frames_to_time(2), true);
+ _player->seek (p, true);
fetch_next_frame ();
}