HDK
Main Page
Related Pages
Modules
Namespaces
Classes
Files
Examples
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
openexr_errors.h
Go to the documentation of this file.
1
/*
2
** SPDX-License-Identifier: BSD-3-Clause
3
** Copyright Contributors to the OpenEXR Project.
4
*/
5
6
#ifndef OPENEXR_ERRORS_H
7
#define OPENEXR_ERRORS_H
8
9
#include "
openexr_config.h
"
10
11
#include <stdint.h>
12
13
#ifdef __cplusplus
14
extern
"C"
{
15
#endif
16
17
/** @file */
18
19
/**
20
* @defgroup ErrorCodes Error Handling
21
* @brief These are a group of definitions related to error handling.
22
*
23
* All functions in the C layer will return a result, which will
24
* correspond to one of these codes. To ensure binary stability, the
25
* return type is separate from the error code, and is a fixed size.
26
*
27
* @{
28
*/
29
30
/** Error codes that may be returned by various functions. */
31
typedef
enum
32
{
33
EXR_ERR_SUCCESS
= 0,
34
EXR_ERR_OUT_OF_MEMORY
,
35
EXR_ERR_MISSING_CONTEXT_ARG
,
36
EXR_ERR_INVALID_ARGUMENT
,
37
EXR_ERR_ARGUMENT_OUT_OF_RANGE
,
38
EXR_ERR_FILE_ACCESS
,
39
EXR_ERR_FILE_BAD_HEADER
,
40
EXR_ERR_NOT_OPEN_READ
,
41
EXR_ERR_NOT_OPEN_WRITE
,
42
EXR_ERR_HEADER_NOT_WRITTEN
,
43
EXR_ERR_READ_IO
,
44
EXR_ERR_WRITE_IO
,
45
EXR_ERR_NAME_TOO_LONG
,
46
EXR_ERR_MISSING_REQ_ATTR
,
47
EXR_ERR_INVALID_ATTR
,
48
EXR_ERR_NO_ATTR_BY_NAME
,
49
EXR_ERR_ATTR_TYPE_MISMATCH
,
50
EXR_ERR_ATTR_SIZE_MISMATCH
,
51
EXR_ERR_SCAN_TILE_MIXEDAPI
,
52
EXR_ERR_TILE_SCAN_MIXEDAPI
,
53
EXR_ERR_MODIFY_SIZE_CHANGE
,
54
EXR_ERR_ALREADY_WROTE_ATTRS
,
55
EXR_ERR_BAD_CHUNK_LEADER
,
56
EXR_ERR_CORRUPT_CHUNK
,
57
EXR_ERR_INCORRECT_PART
,
58
EXR_ERR_INCORRECT_CHUNK
,
59
EXR_ERR_USE_SCAN_DEEP_WRITE
,
60
EXR_ERR_USE_TILE_DEEP_WRITE
,
61
EXR_ERR_USE_SCAN_NONDEEP_WRITE
,
62
EXR_ERR_USE_TILE_NONDEEP_WRITE
,
63
EXR_ERR_INVALID_SAMPLE_DATA
,
64
EXR_ERR_FEATURE_NOT_IMPLEMENTED
,
65
EXR_ERR_UNKNOWN
66
}
exr_error_code_t
;
67
68
/** Return type for all functions. */
69
typedef
int32_t
exr_result_t
;
70
71
/** @brief Return a static string corresponding to the specified error code.
72
*
73
* The string should not be freed (it is compiled into the binary).
74
*/
75
EXR_EXPORT
const
char
*
exr_get_default_error_message
(exr_result_t code);
76
77
/** @brief Return a static string corresponding to the specified error code.
78
*
79
* The string should not be freed (it is compiled into the binary).
80
*/
81
EXR_EXPORT
const
char
*
exr_get_error_code_as_string
(exr_result_t code);
82
83
/** @} */
84
85
#ifdef __cplusplus
86
}
/* extern "C" */
87
#endif
88
89
#endif
/* OPENEXR_ERRORS_H */
EXR_ERR_SUCCESS
Definition:
openexr_errors.h:33
EXR_ERR_NO_ATTR_BY_NAME
Definition:
openexr_errors.h:48
EXR_ERR_INCORRECT_CHUNK
Definition:
openexr_errors.h:58
EXR_ERR_INVALID_SAMPLE_DATA
Definition:
openexr_errors.h:63
EXR_ERR_MISSING_REQ_ATTR
Definition:
openexr_errors.h:46
EXR_ERR_FILE_ACCESS
Definition:
openexr_errors.h:38
EXR_ERR_USE_SCAN_DEEP_WRITE
Definition:
openexr_errors.h:59
EXR_ERR_USE_TILE_DEEP_WRITE
Definition:
openexr_errors.h:60
EXR_ERR_NAME_TOO_LONG
Definition:
openexr_errors.h:45
EXR_ERR_ATTR_TYPE_MISMATCH
Definition:
openexr_errors.h:49
EXR_ERR_FILE_BAD_HEADER
Definition:
openexr_errors.h:39
EXR_ERR_INVALID_ATTR
Definition:
openexr_errors.h:47
EXR_ERR_UNKNOWN
Definition:
openexr_errors.h:65
EXR_ERR_USE_TILE_NONDEEP_WRITE
Definition:
openexr_errors.h:62
EXR_ERR_FEATURE_NOT_IMPLEMENTED
Definition:
openexr_errors.h:64
EXR_ERR_NOT_OPEN_WRITE
Definition:
openexr_errors.h:41
openexr_config.h
EXR_ERR_INVALID_ARGUMENT
Definition:
openexr_errors.h:36
EXR_ERR_MODIFY_SIZE_CHANGE
Definition:
openexr_errors.h:53
EXR_ERR_SCAN_TILE_MIXEDAPI
Definition:
openexr_errors.h:51
EXR_ERR_INCORRECT_PART
Definition:
openexr_errors.h:57
exr_result_t
int32_t exr_result_t
Definition:
openexr_errors.h:69
EXR_ERR_ALREADY_WROTE_ATTRS
Definition:
openexr_errors.h:54
EXR_EXPORT
#define EXR_EXPORT
Definition:
openexr_config.h:31
EXR_ERR_READ_IO
Definition:
openexr_errors.h:43
exr_error_code_t
exr_error_code_t
Definition:
openexr_errors.h:31
exr_get_error_code_as_string
EXR_EXPORT const char * exr_get_error_code_as_string(exr_result_t code)
Return a static string corresponding to the specified error code.
EXR_ERR_OUT_OF_MEMORY
Definition:
openexr_errors.h:34
EXR_ERR_USE_SCAN_NONDEEP_WRITE
Definition:
openexr_errors.h:61
EXR_ERR_WRITE_IO
Definition:
openexr_errors.h:44
EXR_ERR_ARGUMENT_OUT_OF_RANGE
Definition:
openexr_errors.h:37
EXR_ERR_HEADER_NOT_WRITTEN
Definition:
openexr_errors.h:42
EXR_ERR_TILE_SCAN_MIXEDAPI
Definition:
openexr_errors.h:52
EXR_ERR_BAD_CHUNK_LEADER
Definition:
openexr_errors.h:55
EXR_ERR_ATTR_SIZE_MISMATCH
Definition:
openexr_errors.h:50
EXR_ERR_CORRUPT_CHUNK
Definition:
openexr_errors.h:56
EXR_ERR_MISSING_CONTEXT_ARG
Definition:
openexr_errors.h:35
exr_get_default_error_message
EXR_EXPORT const char * exr_get_default_error_message(exr_result_t code)
Return a static string corresponding to the specified error code.
EXR_ERR_NOT_OPEN_READ
Definition:
openexr_errors.h:40
OpenEXR
openexr_errors.h
Generated on Tue Dec 17 2024 03:40:06 for HDK by
1.8.6