[svn] / trunk / vfw / src / codec.h Repository:
ViewVC logotype

Diff of /trunk/vfw/src/codec.h

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

revision 3, Fri Mar 8 02:46:11 2002 UTC revision 532, Tue Sep 24 14:25:42 2002 UTC
# Line 8  Line 8 
8    
9  #define DEBUG(X)  #define DEBUG(X)
10  // OutputDebugString(X)  // OutputDebugString(X)
11  #define DEBUG1(X,A)  #define DEBUG1(X,A) { char tmp[120]; wsprintf(tmp, "%s %i", (X), (A)); OutputDebugString(tmp); }
 // { char tmp[100]; wsprintf(tmp, "%s %i", (X), (A)); OutputDebugString(tmp); }  
12  #define DEBUG2(X,A,B)  #define DEBUG2(X,A,B)
13  // { char tmp[100]; wsprintf(tmp, "%s %i %i", (X), (A), (B)); OutputDebugString(tmp); }  // { char tmp[120]; wsprintf(tmp, "%s %i %i", (X), (A), (B)); OutputDebugString(tmp); }
14  #define DEBUG3(X,A,B,C)  #define DEBUG3(X,A,B,C)
15  // { char tmp[100]; wsprintf(tmp, "%s %i %i %i", (X), (A), (B), (C)); OutputDebugString(tmp); }  // { char tmp[120]; wsprintf(tmp, "%s %i %i %i", (X), (A), (B), (C)); OutputDebugString(tmp); }
16  #define DEBUG4(X,A,B,C,D)  #define DEBUG4(X,A,B,C,D)
17  // { char tmp[100]; wsprintf(tmp, "%s %i %i %i %i", (X), (A), (B), (C), (D)); OutputDebugString(tmp); }  // { char tmp[120]; wsprintf(tmp, "%s %i %i %i %i", (X), (A), (B), (C), (D)); OutputDebugString(tmp); }
18  #define DEBUG5(X,A,B,C,D,E)  #define DEBUG5(X,A,B,C,D,E)
19  // { char tmp[100]; wsprintf(tmp, "%s %i %i %i %i %i", (X), (A), (B), (C), (D), (E)); OutputDebugString(tmp); }  // { char tmp[120]; wsprintf(tmp, "%s %i %i %i %i %i", (X), (A), (B), (C), (D), (E)); OutputDebugString(tmp); }
20  #define DEBUGFOURCC(X,Y)  #define DEBUGFOURCC(X,Y)
21  // { char tmp[100]; wsprintf(tmp, "%s %c %c %c %c", (X), (Y)&0xff, ((Y)>>8)&0xff, ((Y)>>16)&0xff, ((Y)>>24)&0xff); OutputDebugString(tmp); }  // { char tmp[120]; wsprintf(tmp, "%s %c %c %c %c", (X), (Y)&0xff, ((Y)>>8)&0xff, ((Y)>>16)&0xff, ((Y)>>24)&0xff); OutputDebugString(tmp); }
22    #define DEBUGERR(X) OutputDebugString(X)
23  #define DEBUG2P(X) OutputDebugString(X)  #define DEBUG2P(X) OutputDebugString(X)
24  #define DEBUG1ST(A,B,C,D,E,F) { char tmp[100]; wsprintf(tmp, "1st-pass: size:%d total-kbytes:%d %s quant:%d kblocks:%d mblocks:%d", (A), (B), (C) ? "intra" : "inter", (D), (E), (F)); OutputDebugString(tmp); }  #define DEBUG1ST(A,B,C,D,E,F,G) { char tmp[120]; wsprintf(tmp, "1st-pass: size:%d total-kbytes:%d %s quant:%d %s kblocks:%d mblocks:%d", (A), (B), (C) ? "intra" : "inter", (D), (E), (F), (G)); OutputDebugString(tmp); }
25  #define DEBUG2ND(A,B,C,D,E,F,G) { char tmp[100]; wsprintf(tmp, "2nd-pass: quant:%d %s stats1:%d scaled:%d actual:%d overflow:%d %s", (A), (B) ? "intra" : "inter", (C), (D), (E), (F), (G) ? "credits" : "movie"); OutputDebugString(tmp); }  #define DEBUG2ND(A,B,C,D,E,F,G,H) { char tmp[120]; wsprintf(tmp, "2nd-pass: quant:%d %s %s stats1:%d scaled:%d actual:%d overflow:%d %s", (A), (B), (C) ? "intra" : "inter", (D), (E), (F), (G), (H) ? "credits" : "movie"); OutputDebugString(tmp); }
26    
27    
28  #define FOURCC_XVID     mmioFOURCC('X','V','I','D')  #define FOURCC_XVID     mmioFOURCC('X','V','I','D')
29  #define FOURCC_DIVX     mmioFOURCC('D','I','V','X')  #define FOURCC_DIVX     mmioFOURCC('D','I','V','X')
30    #define FOURCC_DX50 mmioFOURCC('D','X','5','0')
31  //#define FOURCC_DIV3   mmioFOURCC('D','I','V','3')  //#define FOURCC_DIV3   mmioFOURCC('D','I','V','3')
32  //#define FOURCC_DIV4   mmioFOURCC('D','I','V','4')  //#define FOURCC_DIV4   mmioFOURCC('D','I','V','4')
33    
# Line 90  Line 91 
91    
92  typedef struct  typedef struct
93  {  {
94          HANDLE * stats1;          HANDLE hints;
95          HANDLE * stats2;          HANDLE stats1;
96            HANDLE stats2;
97    
98            void * hintstream;
99    
100          int bytes1;          int bytes1;
101          int bytes2;          int bytes2;
102          int desired_bytes2;          int desired_bytes2;
103    
104          float movie_curve;          int keyframe_locations[20480];
105          float credits_start_curve;          int max_framesize;
106          float credits_end_curve;          int minpsize, minisize;
107            double movie_curve;
108            double credits_start_curve;
109            double credits_end_curve;
110    
111          double average_frame;          double average_frame;
112          double curve_comp_scale;          double curve_comp_scale;
113          int overflow;          double curve_bias_bonus;
114            double alt_curve_low;
115            double alt_curve_high;
116            double alt_curve_low_diff;
117            double alt_curve_high_diff;
118            double alt_curve_mid_qual;
119            double alt_curve_qual_dev;
120            int overflow, KF_idx, KFoverflow, KFoverflow_partial;
121            int quant_count[32];
122    
123          NNSTATS nns1;          NNSTATS nns1;
124          NNSTATS nns2;          NNSTATS nns2;
# Line 131  Line 146 
146  } CODEC;  } CODEC;
147    
148    
149    int get_colorspace(BITMAPINFOHEADER *);
150    
151  LRESULT compress_query(CODEC *, BITMAPINFO *, BITMAPINFO *);  LRESULT compress_query(CODEC *, BITMAPINFO *, BITMAPINFO *);
152  LRESULT compress_get_format(CODEC *, BITMAPINFO *, BITMAPINFO *);  LRESULT compress_get_format(CODEC *, BITMAPINFO *, BITMAPINFO *);
153  LRESULT compress_get_size(CODEC *, BITMAPINFO *, BITMAPINFO *);  LRESULT compress_get_size(CODEC *, BITMAPINFO *, BITMAPINFO *);
# Line 145  Line 162 
162  LRESULT decompress_end(CODEC *);  LRESULT decompress_end(CODEC *);
163  LRESULT decompress(CODEC *, ICDECOMPRESS *);  LRESULT decompress(CODEC *, ICDECOMPRESS *);
164    
 int codec_2pass_init(CODEC *);  
165  int codec_get_quant(CODEC *, XVID_ENC_FRAME *);  int codec_get_quant(CODEC *, XVID_ENC_FRAME *);
 int codec_2pass_get_quant(CODEC *, XVID_ENC_FRAME *);  
 int codec_2pass_update(CODEC *, XVID_ENC_FRAME *, XVID_ENC_STATS *);  
166  int codec_is_in_credits(CONFIG *, int);  int codec_is_in_credits(CONFIG *, int);
167  int codec_get_vbr_quant(CONFIG *, int);  int codec_get_vbr_quant(CONFIG *, int);
168    
169    // added by Koepi for greyscale credits
170    int check_greyscale_mode(CONFIG *, XVID_ENC_FRAME* , int);
171    // end of koepi's additions
172    
173  #endif /* _CODEC_H_ */  #endif /* _CODEC_H_ */

Legend:
Removed from v.3  
changed lines
  Added in v.532

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