| 1 | /* |
| 2 | * Copyright (c) 2008-2015, NVIDIA CORPORATION. All rights reserved. |
| 3 | * |
| 4 | * NVIDIA CORPORATION and its licensors retain all intellectual property |
| 5 | * and proprietary rights in and to this software, related documentation |
| 6 | * and any modifications thereto. Any use, reproduction, disclosure or |
| 7 | * distribution of this software and related documentation without an express |
| 8 | * license agreement from NVIDIA CORPORATION is strictly prohibited. |
| 9 | */ |
| 10 | // Copyright (c) 2004-2008 AGEIA Technologies, Inc. All rights reserved. |
| 11 | // Copyright (c) 2001-2004 NovodeX AG. All rights reserved. |
| 12 | |
| 13 | |
| 14 | #ifndef PX_FOUNDATION_PX_ERRORS_H |
| 15 | #define PX_FOUNDATION_PX_ERRORS_H |
| 16 | /** \addtogroup foundation |
| 17 | @{ |
| 18 | */ |
| 19 | |
| 20 | #include "foundation/Px.h" |
| 21 | |
| 22 | #ifndef PX_DOXYGEN |
| 23 | namespace physx |
| 24 | { |
| 25 | #endif |
| 26 | |
| 27 | /** |
| 28 | \brief Error codes |
| 29 | |
| 30 | These error codes are passed to #PxErrorCallback |
| 31 | |
| 32 | @see PxErrorCallback |
| 33 | */ |
| 34 | |
| 35 | struct PxErrorCode |
| 36 | { |
| 37 | enum Enum |
| 38 | { |
| 39 | eNO_ERROR = 0, |
| 40 | |
| 41 | //! \brief An informational message. |
| 42 | eDEBUG_INFO = 1, |
| 43 | |
| 44 | //! \brief a warning message for the user to help with debugging |
| 45 | eDEBUG_WARNING = 2, |
| 46 | |
| 47 | //! \brief method called with invalid parameter(s) |
| 48 | eINVALID_PARAMETER = 4, |
| 49 | |
| 50 | //! \brief method was called at a time when an operation is not possible |
| 51 | eINVALID_OPERATION = 8, |
| 52 | |
| 53 | //! \brief method failed to allocate some memory |
| 54 | eOUT_OF_MEMORY = 16, |
| 55 | |
| 56 | /** \brief The library failed for some reason. |
| 57 | Possibly you have passed invalid values like NaNs, which are not checked for. |
| 58 | */ |
| 59 | eINTERNAL_ERROR = 32, |
| 60 | |
| 61 | //! \brief An unrecoverable error, execution should be halted and log output flushed |
| 62 | eABORT = 64, |
| 63 | |
| 64 | //! \brief The SDK has determined that an operation may result in poor performance. |
| 65 | ePERF_WARNING = 128, |
| 66 | |
| 67 | //! \brief A bit mask for including all errors |
| 68 | eMASK_ALL = -1 |
| 69 | }; |
| 70 | }; |
| 71 | |
| 72 | #ifndef PX_DOXYGEN |
| 73 | } // namespace physx |
| 74 | #endif |
| 75 | |
| 76 | /** @} */ |
| 77 | #endif |
| 78 | |