update Features5.pdf, fixes for awindowgui
[goodguy/history.git] / cinelerra-5.1 / cinelerra / filempeg.C
index cef98f4dab2df6629b2ff85af1a385ac71efeca7..d1eb02c15dbeb04fe532c49c5794f51e843ceab3 100644 (file)
@@ -490,9 +490,9 @@ int FileMPEG::open_file(int rd, int wr)
 // Construct command line
                        if(!result)
                        {
-                               char string[BCTEXTLEN];
-                               get_exe_path(string);
-                               sprintf(mjpeg_command, "%s/%s", string, HVPEG_EXE);
+                               const char *exec_path = File::get_cinlib_path();
+                               sprintf(mjpeg_command, "%s/%s", exec_path, HVPEG_EXE);
+                               append_vcommand_line(mjpeg_command);
 
                                if(asset->aspect_ratio > 0)
                                {
@@ -516,7 +516,7 @@ int FileMPEG::open_file(int rd, int wr)
                                append_vcommand_line(asset->vmpeg_cmodel == BC_YUV422P ? "-422" : "");
                                if(asset->vmpeg_fix_bitrate)
                                {
-                                       append_vcommand_line("--cbr -b");
+                                       append_vcommand_line("-b");
                                        append_vcommand_line(bitrate_string);
                                }
                                else
@@ -540,9 +540,8 @@ int FileMPEG::open_file(int rd, int wr)
 // mjpegtools encoder
 //  this one is cinelerra-x.x.x/thirdparty/mjpegtools/mpeg2enc
                {
-                       char string[BCTEXTLEN];
-                       get_exe_path(string);
-                       sprintf(mjpeg_command, "%s/%s -v 0 ", string, MJPEG_EXE);
+                       const char *exec_path = File::get_cinlib_path();
+                       sprintf(mjpeg_command, "%s/%s -v 0 ", exec_path, MJPEG_EXE);
 
 // Must disable interlacing if MPEG-1
                        switch (asset->vmpeg_preset)
@@ -555,6 +554,7 @@ int FileMPEG::open_file(int rd, int wr)
 // Be quiet
                        strcat(mjpeg_command, " -v0");
 
+                       char string[BCTEXTLEN];
 // The current usage of mpeg2enc requires bitrate of 0 when quantization is fixed and
 // quantization of 1 when bitrate is fixed.  Perfectly intuitive.
                        if(asset->vmpeg_fix_bitrate)