~ubuntu-branches/ubuntu/trusty/blender/trusty

« back to all changes in this revision

Viewing changes to intern/opencolorio/ocio_capi.h

  • Committer: Package Import Robot
  • Author(s): Jeremy Bicha
  • Date: 2013-03-06 12:08:47 UTC
  • mfrom: (1.5.1) (14.1.8 experimental)
  • Revision ID: package-import@ubuntu.com-20130306120847-frjfaryb2zrotwcg
Tags: 2.66a-1ubuntu1
* Resynchronize with Debian (LP: #1076930, #1089256, #1052743, #999024,
  #1122888, #1147084)
* debian/control:
  - Lower build-depends on libavcodec-dev since we're not
    doing the libav9 transition in Ubuntu yet

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 * ***** BEGIN GPL LICENSE BLOCK *****
 
3
 *
 
4
 * This program is free software; you can redistribute it and/or
 
5
 * modify it under the terms of the GNU General Public License
 
6
 * as published by the Free Software Foundation; either version 2
 
7
 * of the License, or (at your option) any later version.
 
8
 *
 
9
 * This program is distributed in the hope that it will be useful,
 
10
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
11
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
12
 * GNU General Public License for more details.
 
13
 *
 
14
 * You should have received a copy of the GNU General Public License
 
15
 * along with this program; if not, write to the Free Software Foundation,
 
16
 * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
 
17
 *
 
18
 * The Original Code is Copyright (C) 2012 Blender Foundation.
 
19
 * All rights reserved.
 
20
 *
 
21
 * Contributor(s): Xavier Thomas
 
22
 *                 Lukas Toene
 
23
 *                 Sergey Sharybin
 
24
 *
 
25
 * ***** END GPL LICENSE BLOCK *****
 
26
 */
 
27
 
 
28
#ifndef __OCIO_CAPI_H__
 
29
#define __OCIO_CAPI_H__
 
30
 
 
31
#ifdef __cplusplus
 
32
extern "C" {
 
33
#endif
 
34
 
 
35
#define OCIO_DECLARE_HANDLE(name) typedef struct name##__ { int unused; } *name
 
36
 
 
37
#define OCIO_ROLE_SCENE_LINEAR       "scene_linear"
 
38
#define OCIO_ROLE_COLOR_PICKING      "color_picking"
 
39
#define OCIO_ROLE_TEXTURE_PAINT      "texture_paint"
 
40
#define OCIO_ROLE_DEFAULT_BYTE       "default_byte"
 
41
#define OCIO_ROLE_DEFAULT_FLOAT      "default_float"
 
42
#define OCIO_ROLE_DEFAULT_SEQUENCER  "default_sequencer"
 
43
 
 
44
OCIO_DECLARE_HANDLE(OCIO_ConstConfigRcPtr);
 
45
OCIO_DECLARE_HANDLE(OCIO_ConstColorSpaceRcPtr);
 
46
OCIO_DECLARE_HANDLE(OCIO_ConstProcessorRcPtr);
 
47
OCIO_DECLARE_HANDLE(OCIO_ConstContextRcPtr);
 
48
OCIO_DECLARE_HANDLE(OCIO_PackedImageDesc);
 
49
OCIO_DECLARE_HANDLE(OCIO_DisplayTransformRcPtr);
 
50
OCIO_DECLARE_HANDLE(OCIO_ConstTransformRcPtr);
 
51
OCIO_DECLARE_HANDLE(OCIO_ExponentTransformRcPtr);
 
52
OCIO_DECLARE_HANDLE(OCIO_MatrixTransformRcPtr);
 
53
 
 
54
void OCIO_init(void);
 
55
void OCIO_exit(void);
 
56
 
 
57
OCIO_ConstConfigRcPtr *OCIO_getCurrentConfig(void);
 
58
void OCIO_setCurrentConfig(const OCIO_ConstConfigRcPtr *config);
 
59
 
 
60
OCIO_ConstConfigRcPtr *OCIO_configCreateFromEnv(void);
 
61
OCIO_ConstConfigRcPtr *OCIO_configCreateFromFile(const char* filename);
 
62
OCIO_ConstConfigRcPtr *OCIO_configCreateFallback(void);
 
63
 
 
64
void OCIO_configRelease(OCIO_ConstConfigRcPtr *config);
 
65
 
 
66
int OCIO_configGetNumColorSpaces(OCIO_ConstConfigRcPtr *config);
 
67
const char *OCIO_configGetColorSpaceNameByIndex(OCIO_ConstConfigRcPtr *config, int index);
 
68
OCIO_ConstColorSpaceRcPtr *OCIO_configGetColorSpace(OCIO_ConstConfigRcPtr *config, const char *name);
 
69
int OCIO_configGetIndexForColorSpace(OCIO_ConstConfigRcPtr *config, const char *name);
 
70
 
 
71
int OCIO_colorSpaceIsInvertible(OCIO_ConstColorSpaceRcPtr *cs);
 
72
int OCIO_colorSpaceIsData(OCIO_ConstColorSpaceRcPtr *cs);
 
73
 
 
74
void OCIO_colorSpaceRelease(OCIO_ConstColorSpaceRcPtr *cs);
 
75
 
 
76
const char *OCIO_configGetDefaultDisplay(OCIO_ConstConfigRcPtr *config);
 
77
int         OCIO_configGetNumDisplays(OCIO_ConstConfigRcPtr *config);
 
78
const char *OCIO_configGetDisplay(OCIO_ConstConfigRcPtr *config, int index);
 
79
const char *OCIO_configGetDefaultView(OCIO_ConstConfigRcPtr *config, const char *display);
 
80
int         OCIO_configGetNumViews(OCIO_ConstConfigRcPtr *config, const char *display);
 
81
const char *OCIO_configGetView(OCIO_ConstConfigRcPtr *config, const char *display, int index);
 
82
const char *OCIO_configGetDisplayColorSpaceName(OCIO_ConstConfigRcPtr *config, const char *display, const char *view);
 
83
 
 
84
OCIO_ConstProcessorRcPtr *OCIO_configGetProcessorWithNames(OCIO_ConstConfigRcPtr *config, const char *srcName, const char *dstName);
 
85
OCIO_ConstProcessorRcPtr *OCIO_configGetProcessor(OCIO_ConstConfigRcPtr *config, OCIO_ConstTransformRcPtr *transform);
 
86
 
 
87
void OCIO_processorApply(OCIO_ConstProcessorRcPtr *processor, OCIO_PackedImageDesc *img);
 
88
void OCIO_processorApply_predivide(OCIO_ConstProcessorRcPtr *processor, OCIO_PackedImageDesc *img);
 
89
void OCIO_processorApplyRGB(OCIO_ConstProcessorRcPtr *processor, float *pixel);
 
90
void OCIO_processorApplyRGBA(OCIO_ConstProcessorRcPtr *processor, float *pixel);
 
91
void OCIO_processorApplyRGBA_predivide(OCIO_ConstProcessorRcPtr *processor, float *pixel);
 
92
 
 
93
void OCIO_processorRelease(OCIO_ConstProcessorRcPtr *p);
 
94
 
 
95
const char *OCIO_colorSpaceGetName(OCIO_ConstColorSpaceRcPtr *cs);
 
96
const char *OCIO_colorSpaceGetDescription(OCIO_ConstColorSpaceRcPtr *cs);
 
97
const char *OCIO_colorSpaceGetFamily(OCIO_ConstColorSpaceRcPtr *cs);
 
98
 
 
99
OCIO_DisplayTransformRcPtr *OCIO_createDisplayTransform(void);
 
100
void OCIO_displayTransformSetInputColorSpaceName(OCIO_DisplayTransformRcPtr *dt, const char *name);
 
101
void OCIO_displayTransformSetDisplay(OCIO_DisplayTransformRcPtr *dt, const char *name);
 
102
void OCIO_displayTransformSetView(OCIO_DisplayTransformRcPtr *dt, const char *name);
 
103
void OCIO_displayTransformSetDisplayCC(OCIO_DisplayTransformRcPtr *dt, OCIO_ConstTransformRcPtr *et);
 
104
void OCIO_displayTransformSetLinearCC(OCIO_DisplayTransformRcPtr *dt, OCIO_ConstTransformRcPtr *et);
 
105
void OCIO_displayTransformRelease(OCIO_DisplayTransformRcPtr *dt);
 
106
 
 
107
OCIO_PackedImageDesc *OCIO_createOCIO_PackedImageDesc(float *data, long width, long height, long numChannels,
 
108
                                                      long chanStrideBytes, long xStrideBytes, long yStrideBytes);
 
109
 
 
110
void OCIO_PackedImageDescRelease(OCIO_PackedImageDesc *p);
 
111
 
 
112
OCIO_ExponentTransformRcPtr *OCIO_createExponentTransform(void);
 
113
void OCIO_exponentTransformSetValue(OCIO_ExponentTransformRcPtr *et, const float *exponent);
 
114
void OCIO_exponentTransformRelease(OCIO_ExponentTransformRcPtr *et);
 
115
 
 
116
OCIO_MatrixTransformRcPtr *OCIO_createMatrixTransform(void);
 
117
void OCIO_matrixTransformSetValue(OCIO_MatrixTransformRcPtr *et, const float *m44, const float *offset4);
 
118
void OCIO_matrixTransformRelease(OCIO_MatrixTransformRcPtr *mt);
 
119
 
 
120
void OCIO_matrixTransformScale(float * m44, float * offset4, const float * scale4);
 
121
 
 
122
#ifdef __cplusplus
 
123
}
 
124
#endif
 
125
 
 
126
#endif /* OCIO_CAPI_H */