tzh
2024-08-22 c7d0944258c7d0943aa7b2211498fd612971ce27
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
/*!****************************************************************************
 
 @file         PVRTError.h
 @copyright    Copyright (c) Imagination Technologies Limited.
 @brief        PVRT error codes.  
 
******************************************************************************/
#ifndef _PVRTERROR_H_
#define _PVRTERROR_H_
 
#if defined(ANDROID)
   #include <android/log.h>
#else
   #if defined(_WIN32)
       #include <windows.h>
   #else
       #include <stdio.h>
   #endif
#endif
/*!***************************************************************************
 Macros
*****************************************************************************/
 
/*! Outputs a string to the standard error if built for debugging. */
#if !defined(PVRTERROR_OUTPUT_DEBUG)
   #if defined(_DEBUG) || defined(DEBUG)
       #if defined(ANDROID)
           #define PVRTERROR_OUTPUT_DEBUG(A) __android_log_print(ANDROID_LOG_INFO, "PVRTools", A);
       #elif defined(_WIN32) && !defined(UNDER_CE)
           #define PVRTERROR_OUTPUT_DEBUG(A) OutputDebugStringA(A);
       #else
           #define PVRTERROR_OUTPUT_DEBUG(A) fprintf(stderr,A);
       #endif
   #else
       #define PVRTERROR_OUTPUT_DEBUG(A)
   #endif
#endif
 
 
/*!***************************************************************************
 Enums
*****************************************************************************/
/*!***************************************************************************
 @enum              EPVRTError
 @brief             EPVRT error conditions.
*****************************************************************************/
enum EPVRTError
{
   PVR_SUCCESS = 0,    /*!< Success! :D */
   PVR_FAIL = 1,       /*!< Failed :( */
   PVR_OVERFLOW = 2    /*!< Overflow error :| */
};
 
/*!***************************************************************************
 @brief             Outputs a string to the standard error.
 @param[in]            format        printf style format followed by arguments it requires.
*****************************************************************************/
void PVRTErrorOutputDebug(char const * const format, ...);
 
#endif // _PVRTERROR_H_
 
/*****************************************************************************
End of file (PVRTError.h)
*****************************************************************************/