diff --git a/src/video_provider_bestsource.cpp b/src/video_provider_bestsource.cpp index e3859680b..3853d2d73 100644 --- a/src/video_provider_bestsource.cpp +++ b/src/video_provider_bestsource.cpp @@ -84,7 +84,6 @@ public: std::string colormatrix_description(const AVFrame *frame) { // Assuming TV for unspecified std::string str = frame->color_range == AVCOL_RANGE_JPEG ? "PC" : "TV"; - LOG_D("bestsource") << frame->colorspace; switch (frame->colorspace) { case AVCOL_SPC_BT709: @@ -114,21 +113,16 @@ BSVideoProvider::BSVideoProvider(agi::fs::path const& filename, std::string cons has_audio = false; } + br->Run([&](agi::ProgressSink *ps) { + ps->SetTitle(from_wx(_("Exacting"))); + ps->SetMessage(from_wx(_("Creating cache... This can take a while!"))); + ps->SetIndeterminate(); + if (bs.GetExactDuration()) { + LOG_D("provider/video/bestsource") << "File cached and has exact samples."; + } + }); properties = bs.GetVideoProperties(); - if (properties.NumFrames == -1) { - LOG_D("bs") << "File not cached or varying samples, creating cache."; - br->Run([&](agi::ProgressSink *ps) { - ps->SetTitle(from_wx(_("Exacting"))); - ps->SetMessage(from_wx(_("Creating cache... This can take a while!"))); - ps->SetIndeterminate(); - if (bs.GetExactDuration()) { - LOG_D("bs") << "File cached and has exact samples."; - } - }); - properties = bs.GetVideoProperties(); - } - br->Run([&](agi::ProgressSink *ps) { ps->SetTitle(from_wx(_("Scanning"))); ps->SetMessage(from_wx(_("Finding Keyframes and Timecodes...")));