source: branches/perian-1.1/CommonUtils.h @ 887

Revision 887, 1.3 KB checked in by astrange, 7 years ago (diff)

Merge trunk to 1.1 branch.

Line 
1/*
2 *  CommonUtils.h
3 *  Perian
4 *
5 *  Created by David Conrad on 10/13/06.
6 *  Copyright 2006 Perian Project. All rights reserved.
7 *
8 */
9
10#ifndef __COMMONUTILS_H__
11#define __COMMONUTILS_H__
12
13#include <QuickTime/QuickTime.h>
14
15#ifdef __cplusplus
16extern "C"
17{
18#endif
19
20// ISO 639-1 to language ID expected by SetMediaLanguage
21short ISO639_1ToQTLangCode(const char *lang);
22
23// ISO 639-2 to language ID expected by SetMediaLanguage
24short ISO639_2ToQTLangCode(const char *lang);
25
26/* write the int32_t data to target & then return a pointer which points after that data */
27uint8_t *write_int32(uint8_t *target, int32_t data);
28
29/* write the int16_t data to target & then return a pointer which points after that data */
30uint8_t *write_int16(uint8_t *target, int16_t data);
31
32/* write the data to the target adress & then return a pointer which points after the written data */
33uint8_t *write_data(uint8_t *target, uint8_t* data, int32_t data_size);
34
35// mallocs the buffer and copies the codec-specific description to it, in the same format
36// as is specified in Matroska and is used in libavcodec
37ComponentResult ReadESDSDescExt(Handle descExt, UInt8 **buffer, int *size);
38
39int isImageDescriptionExtensionPresent(ImageDescriptionHandle desc, long type);
40
41int IsFrameDroppingEnabled();
42
43#ifdef __cplusplus
44}
45#endif
46
47#endif
Note: See TracBrowser for help on using the repository browser.