[svn] / branches / release-1_3-branch / xvidcore / examples / xvid_encraw.c Repository:
ViewVC logotype

Diff of /branches/release-1_3-branch/xvidcore/examples/xvid_encraw.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1932, Thu Dec 30 11:47:06 2010 UTC revision 1947, Thu Feb 3 15:01:14 2011 UTC
# Line 22  Line 22 
22   *  along with this program; if not, write to the Free Software   *  along with this program; if not, write to the Free Software
23   *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA   *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
24   *   *
25   * $Id: xvid_encraw.c,v 1.46.2.2 2010-12-30 11:47:06 Isibaar Exp $   * $Id: xvid_encraw.c,v 1.46.2.3 2011-02-03 15:01:06 Isibaar Exp $
26   *   *
27   ****************************************************************************/   ****************************************************************************/
28    
# Line 200  Line 200 
200  static  char *ARG_PASS2 = 0;  static  char *ARG_PASS2 = 0;
201  //static int ARG_QUALITY = ME_ELEMENTS - 1;  //static int ARG_QUALITY = ME_ELEMENTS - 1;
202  static  int ARG_QUALITY = 6;  static  int ARG_QUALITY = 6;
203  static  float ARG_FRAMERATE = 25.00f;  static  float ARG_FRAMERATE = 0.f;
204  static  int ARG_DWRATE = 25;  static  int ARG_DWRATE = 25;
205  static  int ARG_DWSCALE = 1;  static  int ARG_DWSCALE = 1;
206  static  int ARG_MAXFRAMENR = ABS_MAXFRAMENR;  static  int ARG_MAXFRAMENR = ABS_MAXFRAMENR;
# Line 353  Line 353 
353    
354          /* Is there a dumb Xvid coder ? */          /* Is there a dumb Xvid coder ? */
355          if(ME_ELEMENTS != VOP_ELEMENTS) {          if(ME_ELEMENTS != VOP_ELEMENTS) {
356                  fprintf(stderr, "Presets' arrays should have the same number of elements -- Please fill a bug to xvid-devel@xvid.org\n");                  fprintf(stderr, "Presets' arrays should have the same number of elements -- Please file a bug to xvid-devel@xvid.org\n");
357                  return(-1);                  return(-1);
358          }          }
359    
# Line 753  Line 753 
753                                  i++;                                  i++;
754                          else                          else
755                                  ARG_PROGRESS = 10;                                  ARG_PROGRESS = 10;
756                  } else if (strcmp("-help", argv[i])) {                  } else if (strcmp("-help", argv[i]) == 0) {
757                          usage();                          usage();
758                          return (0);                          return (0);
759                  } else {                  } else {
# Line 951  Line 951 
951          }          }
952    
953          if (ARG_FRAMERATE <= 0) {          if (ARG_FRAMERATE <= 0) {
954                  fprintf(stderr, "Wrong Framerate %f\n", ARG_FRAMERATE);                  ARG_FRAMERATE = 25.00f; /* default value */
                 return (-1);  
955          }          }
956    
957          if (ARG_TARGETSIZE) {          if (ARG_TARGETSIZE) {
# Line 1410  Line 1409 
1409                          myAVIStreamInfo.dwRate = ARG_DWRATE;                          myAVIStreamInfo.dwRate = ARG_DWRATE;
1410                          myAVIStreamInfo.dwLength = ARG_MAXFRAMENR;                          myAVIStreamInfo.dwLength = ARG_MAXFRAMENR;
1411                          myAVIStreamInfo.dwQuality = 10000;                          myAVIStreamInfo.dwQuality = 10000;
1412                          SetRect(&myAVIStreamInfo.rcFrame, 0, 0, YDIM, XDIM);                          SetRect(&myAVIStreamInfo.rcFrame, 0, 0, XDIM, YDIM);
1413    
1414                          if (avierr=AVIFileOpen(&myAVIFile, ARG_AVIOUTPUTFILE, OF_CREATE|OF_WRITE, NULL)) {                          if (avierr=AVIFileOpen(&myAVIFile, ARG_AVIOUTPUTFILE, OF_CREATE|OF_WRITE, NULL)) {
1415                                  fprintf(stderr, "AVIFileOpen failed opening output file %s, error code %d\n", ARG_AVIOUTPUTFILE, avierr);                                  fprintf(stderr, "AVIFileOpen failed opening output file %s, error code %d\n", ARG_AVIOUTPUTFILE, avierr);
# Line 1839  Line 1838 
1838          fprintf(stderr, " -bquant_offset integer: bframe quantizer offset (100)\n");          fprintf(stderr, " -bquant_offset integer: bframe quantizer offset (100)\n");
1839          fprintf(stderr, "\n");          fprintf(stderr, "\n");
1840          fprintf(stderr, "Rate control options:\n");          fprintf(stderr, "Rate control options:\n");
1841          fprintf(stderr, " -framerate float               : target framerate (25.0)\n");          fprintf(stderr, " -framerate float               : target framerate (auto)\n");
1842          fprintf(stderr, " -bitrate   [integer]           : target bitrate in kbps (700)\n");          fprintf(stderr, " -bitrate   [integer]           : target bitrate in kbps (700)\n");
1843          fprintf(stderr, " -size      integer                     : target size in kilobytes\n");          fprintf(stderr, " -size      integer                     : target size in kilobytes\n");
1844      fprintf(stderr,     " -single                        : single pass mode (default)\n");      fprintf(stderr,     " -single                        : single pass mode (default)\n");

Legend:
Removed from v.1932  
changed lines
  Added in v.1947

No admin address has been configured
ViewVC Help
Powered by ViewVC 1.0.4