Merge with trunk/2.5 at r25563
[blender-staging.git] / source / blender / quicktime / quicktime_export.h
1 /* $Id$ 
2  *
3  * ***** BEGIN GPL LICENSE BLOCK *****
4  *
5  * This program is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU General Public License
7  * as published by the Free Software Foundation; either version 2
8  * of the License, or (at your option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with this program; if not, write to the Free Software Foundation,
17  * Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
18  *
19  * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
20  * All rights reserved.
21  *
22  * The Original Code is: all of this file.
23  *
24  * Contributor(s): none yet.
25  *
26  * ***** END GPL LICENSE BLOCK *****
27  */
28
29 #ifndef __QUICKTIME_EXPORT_H__
30 #define __QUICKTIME_EXPORT_H__
31
32 #if defined (_WIN32) || (__APPLE__)
33
34 #define __AIFF__
35
36
37 /*Codec list*/
38 typedef struct QuicktimeCodecTypeDesc {
39         int codecType;
40         int rnatmpvalue;
41         char * codecName;
42 } QuicktimeCodecTypeDesc ;
43
44 // quicktime movie output functions
45 struct RenderData;
46 struct Scene;
47 struct wmOperatorType;
48 struct ReportList;
49
50 int start_qt(struct Scene *scene, struct RenderData *rd, int rectx, int recty, struct ReportList *reports);     //for movie handle (BKE writeavi.c now)
51 int append_qt(struct RenderData *rd, int frame, int *pixels, int rectx, int recty, struct ReportList *reports);
52 void end_qt(void);
53
54 /*RNA helper functions */
55 void quicktime_verify_image_type(struct RenderData *rd); //used by RNA for defaults values init, if needed
56 int quicktime_get_num_codecs();
57 QuicktimeCodecTypeDesc* quicktime_get_codecType_desc(int indexValue);
58 int quicktime_rnatmpvalue_from_codectype(int codecType);
59 int quicktime_codecType_from_rnatmpvalue(int rnatmpvalue);
60
61 #ifndef USE_QTKIT
62 void SCENE_OT_render_data_set_quicktime_codec(struct wmOperatorType *ot); //Operator to raise quicktime standard dialog to request codec settings
63 #endif
64
65
66 void free_qtcomponentdata(void);
67 void makeqtstring(struct RenderData *rd, char *string);         //for playanim.c
68
69
70
71 #if (defined(USE_QTKIT) && defined(MAC_OS_X_VERSION_10_6) && __LP64__)
72 //Include the quicktime codec types constants that are missing in QTKitDefines.h in 10.6 / 64bit
73 enum {
74         kRawCodecType                                           = 'raw ',
75         kCinepakCodecType                                       = 'cvid',
76         kGraphicsCodecType                                      = 'smc ',
77         kAnimationCodecType                             = 'rle ',
78         kVideoCodecType                                         = 'rpza',
79         kComponentVideoCodecType                        = 'yuv2',
80         kJPEGCodecType                                          = 'jpeg',
81         kMotionJPEGACodecType                           = 'mjpa',
82         kMotionJPEGBCodecType                           = 'mjpb',
83         kSGICodecType                                           = '.SGI',
84         kPlanarRGBCodecType                             = '8BPS',
85         kMacPaintCodecType                                      = 'PNTG',
86         kGIFCodecType                                           = 'gif ',
87         kPhotoCDCodecType                                       = 'kpcd',
88         kQuickDrawGXCodecType                           = 'qdgx',
89         kAVRJPEGCodecType                                       = 'avr ',
90         kOpenDMLJPEGCodecType                           = 'dmb1',
91         kBMPCodecType                                           = 'WRLE',
92         kWindowsRawCodecType                            = 'WRAW',
93         kVectorCodecType                                        = 'path',
94         kQuickDrawCodecType                             = 'qdrw',
95         kWaterRippleCodecType                           = 'ripl',
96         kFireCodecType                                          = 'fire',
97         kCloudCodecType                                         = 'clou',
98         kH261CodecType                                          = 'h261',
99         kH263CodecType                                          = 'h263',
100         kDVCNTSCCodecType                                       = 'dvc ',       /* DV - NTSC and DVCPRO NTSC (available in QuickTime 6.0 or later)*/
101         /* NOTE: kDVCProNTSCCodecType is deprecated.    */
102         /* Use kDVCNTSCCodecType instead -- as far as the codecs are concerned, */
103         /* the two data formats are identical.*/
104         kDVCPALCodecType                                        = 'dvcp',
105         kDVCProPALCodecType                             = 'dvpp',       /* available in QuickTime 6.0 or later*/
106         kDVCPro50NTSCCodecType                          = 'dv5n',
107         kDVCPro50PALCodecType                           = 'dv5p',
108         kDVCPro100NTSCCodecType                         = 'dv1n',
109         kDVCPro100PALCodecType                          = 'dv1p',
110         kDVCPROHD720pCodecType                          = 'dvhp',
111         kDVCPROHD1080i60CodecType                       = 'dvh6',
112         kDVCPROHD1080i50CodecType                       = 'dvh5',
113         kBaseCodecType                                          = 'base',
114         kFLCCodecType                                           = 'flic',
115         kTargaCodecType                                         = 'tga ',
116         kPNGCodecType                                           = 'png ',
117         kTIFFCodecType                                          = 'tiff',       /* NOTE: despite what might seem obvious from the two constants*/
118         /* below and their names, they really are correct. 'yuvu' really */
119         /* does mean signed, and 'yuvs' really does mean unsigned. Really. */
120         kComponentVideoSigned                           = 'yuvu',
121         kComponentVideoUnsigned                         = 'yuvs',
122         kCMYKCodecType                                          = 'cmyk',
123         kMicrosoftVideo1CodecType                       = 'msvc',
124         kSorensonCodecType                                      = 'SVQ1',
125         kSorenson3CodecType                             = 'SVQ3',       /* available in QuickTime 5 and later*/
126         kIndeo4CodecType                                        = 'IV41',
127         kMPEG4VisualCodecType                           = 'mp4v',
128         k64ARGBCodecType                                        = 'b64a',
129         k48RGBCodecType                                         = 'b48r',
130         k32AlphaGrayCodecType                           = 'b32a',
131         k16GrayCodecType                                        = 'b16g',
132         kMpegYUV420CodecType                            = 'myuv',
133         kYUV420CodecType                                        = 'y420',
134         kSorensonYUV9CodecType                          = 'syv9',
135         k422YpCbCr8CodecType                            = '2vuy',       /* Component Y'CbCr 8-bit 4:2:2 */
136         k444YpCbCr8CodecType                            = 'v308',       /* Component Y'CbCr 8-bit 4:4:4 */
137         k4444YpCbCrA8CodecType                          = 'v408',       /* Component Y'CbCrA 8-bit 4:4:4:4 */
138         k422YpCbCr16CodecType                           = 'v216',       /* Component Y'CbCr 10,12,14,16-bit 4:2:2*/
139         k422YpCbCr10CodecType                           = 'v210',       /* Component Y'CbCr 10-bit 4:2:2 */
140         k444YpCbCr10CodecType                           = 'v410',       /* Component Y'CbCr 10-bit 4:4:4 */
141         k4444YpCbCrA8RCodecType                         = 'r408',       /* Component Y'CbCrA 8-bit 4:4:4:4, rendering format. full range alpha, zero biased yuv*/
142         kJPEG2000CodecType                                      = 'mjp2',
143         kPixletCodecType                                        = 'pxlt',
144         kH264CodecType                                          = 'avc1'
145 };
146 #endif
147
148 #endif //(_WIN32) || (__APPLE__)
149
150 #endif  // __QUICKTIME_IMP_H__