add --mp4fps=30 command line parameter for ExampleBrowser (and using pybullet.connect(p.GUI, options="--mp4fps=30 --mp4=\"testvideo.mp4\"")

This commit is contained in:
Erwin Coumans
2020-01-11 12:19:42 -08:00
parent 8ebdf7862c
commit 83bdef8254
4 changed files with 22 additions and 5 deletions

View File

@@ -921,6 +921,13 @@ bool OpenGLExampleBrowser::init(int argc, char* argv[])
m_internalData->m_app = s_app;
char* gVideoFileName = 0;
args.GetCmdLineArgument("mp4", gVideoFileName);
int gVideoFps = 0;
args.GetCmdLineArgument("mp4fps", gVideoFps);
if (gVideoFps)
{
simpleApp->setMp4Fps(gVideoFps);
}
#ifndef NO_OPENGL3
if (gVideoFileName)
simpleApp->dumpFramesToVideo(gVideoFileName);