X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;ds=sidebyside;f=vv%2FvvMainWindow.cxx;h=986d7b93cfd76cbf727c716d5966250ae5da6a4d;hb=f8d48c8481db84a9f2a9c140bf19c0c987d1bd59;hp=0635d7bd7cc1fb94f17b170563cc4c7098af2b7b;hpb=ea3651a8d897fad6285b84032dd0a121ec8db2dd;p=clitk.git diff --git a/vv/vvMainWindow.cxx b/vv/vvMainWindow.cxx index 0635d7b..986d7b9 100644 --- a/vv/vvMainWindow.cxx +++ b/vv/vvMainWindow.cxx @@ -71,6 +71,9 @@ #include #include #include +#ifdef VTK_USE_VIDEO_FOR_WINDOWS +# include +#endif #ifdef VTK_USE_FFMPEG_ENCODER # include #endif @@ -2776,6 +2779,19 @@ void vvMainWindow::SaveScreenshot(QVTKWidget *widget) // Video vtkGenericMovieWriter *vidwriter = NULL; +#ifdef VTK_USE_VIDEO_FOR_WINDOWS + if (!strcmp(ext, ".avi")) { + vtkAVIWriter *mpg = vtkAVIWriter::New(); + vidwriter = mpg; + mpg->SetQuality(2); + bool ok; + int fps = QInputDialog::getInt(this, tr("Number of frames per second"), + tr("FPS:"), 5, 0, 1024, 1, &ok); + if(!ok) + fps = 5; + mpg->SetRate(fps); + } +#endif #ifdef VTK_USE_FFMPEG_ENCODER if (!strcmp(ext, ".avi")) { vtkFFMPEGWriter *mpg = vtkFFMPEGWriter::New();