[xiph-cvs] cvs commit: vorbis/include/vorbis vorbisenc.h

Monty xiphmont at xiph.org
Sun Jun 30 01:45:03 PDT 2002



xiphmont    02/06/30 01:45:03

  Modified:    examples encoder_example.c
               include/vorbis vorbisenc.h
  Log:
  Missed the encode ctl headers

Revision  Changes    Path
1.42      +6 -3      vorbis/examples/encoder_example.c

Index: encoder_example.c
===================================================================
RCS file: /usr/local/cvsroot/vorbis/examples/encoder_example.c,v
retrieving revision 1.41
retrieving revision 1.42
diff -u -r1.41 -r1.42
--- encoder_example.c	2002/06/28 22:19:34	1.41
+++ encoder_example.c	2002/06/30 08:45:02	1.42
@@ -11,7 +11,7 @@
  ********************************************************************
 
  function: simple example encoder
- last mod: $Id: encoder_example.c,v 1.41 2002/06/28 22:19:34 xiphmont Exp $
+ last mod: $Id: encoder_example.c,v 1.42 2002/06/30 08:45:02 xiphmont Exp $
 
  ********************************************************************/
 
@@ -97,8 +97,11 @@
   /* (quality mode .4: 44kHz stereo coupled, roughly 128kbps VBR) */
   vorbis_info_init(&vi);
 
-  //vorbis_encode_init(&vi,2,44100,-1,82000,-1);
-  vorbis_encode_init_vbr(&vi,2,44100,.9);
+  vorbis_encode_setup_managed(&vi,2,44100,-1,128000,-1);
+  //vorbis_encode_init(&vi,2,44100,-1,128000,-1);
+  //vorbis_encode_init_vbr(&vi,2,44100,.45);
+  vorbis_encode_ctl(&vi,OV_ECTL_RATEMANAGE_AVG,NULL);
+  vorbis_encode_setup_init(&vi);
 
   /* add a comment */
   vorbis_comment_init(&vc);

<p><p>1.9       +18 -1     vorbis/include/vorbis/vorbisenc.h

Index: vorbisenc.h
===================================================================
RCS file: /usr/local/cvsroot/vorbis/include/vorbis/vorbisenc.h,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- vorbisenc.h	2001/12/20 01:00:25	1.8
+++ vorbisenc.h	2002/06/30 08:45:03	1.9
@@ -11,7 +11,7 @@
  ********************************************************************
 
  function: vorbis encode-engine setup
- last mod: $Id: vorbisenc.h,v 1.8 2001/12/20 01:00:25 segher Exp $
+ last mod: $Id: vorbisenc.h,v 1.9 2002/06/30 08:45:03 xiphmont Exp $
 
  ********************************************************************/
 
@@ -59,7 +59,24 @@
 
 extern int vorbis_encode_ctl(vorbis_info *vi,int number,void *arg);
 
+#define OV_ECTL_RATEMANAGE_GET       0x10
 
+#define OV_ECTL_RATEMANAGE_SET       0x11
+#define OV_ECTL_RATEMANAGE_AVG       0x12
+#define OV_ECTL_RATEMANAGE_HARD      0x13
+
+struct ovectl_ratemanage_arg {
+  int    management_active;
+
+  long   bitrate_hard_min;
+  long   bitrate_hard_max;
+  double bitrate_hard_window;
+
+  long   bitrate_av_lo;
+  long   bitrate_av_hi;
+  double bitrate_av_window;
+  double bitrate_av_window_center;
+};
 
 #ifdef __cplusplus
 }

<p><p><p>--- >8 ----
List archives:  http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'cvs-request at xiph.org'
containing only the word 'unsubscribe' in the body.  No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.



More information about the commits mailing list