00001 /******************************************************************** 00002 * * 00003 * THIS FILE IS PART OF THE OggTheora SOFTWARE CODEC SOURCE CODE. * 00004 * USE, DISTRIBUTION AND REPRODUCTION OF THIS LIBRARY SOURCE IS * 00005 * GOVERNED BY A BSD-STYLE SOURCE LICENSE INCLUDED WITH THIS SOURCE * 00006 * IN 'COPYING'. PLEASE READ THESE TERMS BEFORE DISTRIBUTING. * 00007 * * 00008 * THE Theora SOURCE CODE IS COPYRIGHT (C) 2002-2003 * 00009 * by the Xiph.Org Foundation http://www.xiph.org/ * 00010 * * 00011 ******************************************************************** 00012 00013 function: 00014 last mod: $Id: theora.h,v 1.8 2004/03/15 22:17:32 derf Exp $ 00015 00016 ********************************************************************/ 00017 00021 #if !defined(_O_THEORA_THEORAENC_H_) 00022 # define _O_THEORA_THEORAENC_H_ (1) 00023 # include <stddef.h> 00024 # include <ogg/ogg.h> 00025 # include "codec.h" 00026 00027 #if defined(__cplusplus) 00028 extern "C" { 00029 #endif 00030 00031 00032 00053 #define TH_ENCCTL_SET_HUFFMAN_CODES (0) 00054 00072 #define TH_ENCCTL_SET_QUANT_PARAMS (2) 00073 00085 #define TH_ENCCTL_SET_KEYFRAME_FREQUENCY_FORCE (4) 00086 00113 #define TH_ENCCTL_SET_VP3_COMPATIBLE (10) 00114 00127 #define TH_ENCCTL_GET_SPLEVEL_MAX (12) 00128 00141 #define TH_ENCCTL_SET_SPLEVEL (14) 00142 00147 extern const th_quant_info TH_VP31_QUANT_INFO; 00148 00150 extern const th_huff_code 00151 TH_VP31_HUFF_CODES[TH_NHUFFMAN_TABLES][TH_NDCT_TOKENS]; 00152 00153 00154 00162 typedef struct th_enc_ctx th_enc_ctx; 00192 extern th_enc_ctx *th_encode_alloc(const th_info *_info); 00201 extern int th_encode_ctl(th_enc_ctx *_enc,int _req,void *_buf,size_t _buf_sz); 00219 extern int th_encode_flushheader(th_enc_ctx *_enc, 00220 th_comment *_comments,ogg_packet *_op); 00229 extern int th_encode_ycbcr_in(th_enc_ctx *_enc,th_ycbcr_buffer _ycbcr); 00253 extern int th_encode_packetout(th_enc_ctx *_enc,int _last,ogg_packet *_op); 00256 extern void th_encode_free(th_enc_ctx *_enc); 00259 00260 00261 00262 #if defined(__cplusplus) 00263 } 00264 #endif 00265 00266 #endif