AGX Dynamics 2.38.0.2
Loading...
Searching...
No Matches
FloatingPointExceptions.h
Go to the documentation of this file.
1/*
2Copyright 2007-2024. Algoryx Simulation AB.
3
4All AGX source code, intellectual property, documentation, sample code,
5tutorials, scene files and technical white papers, are copyrighted, proprietary
6and confidential material of Algoryx Simulation AB. You may not download, read,
7store, distribute, publish, copy or otherwise disseminate, use or expose this
8material unless having a written signed agreement with Algoryx Simulation AB, or having been
9advised so by Algoryx Simulation AB for a time limited evaluation, or having purchased a
10valid commercial license from Algoryx Simulation AB.
11
12Algoryx Simulation AB disclaims all responsibilities for loss or damage caused
13from using this software, unless otherwise stated in written agreements with
14Algoryx Simulation AB.
15*/
16
17#ifndef AGX_FLOATING_POINT_EXCEPTIONS_H
18#define AGX_FLOATING_POINT_EXCEPTIONS_H
19
20
21#include <agx/config.h>
22#include <agx/agx.h>
23#include <agx/agxCore_export.h>
24
25
26namespace agx
27{
28 namespace FloatingPointExceptions {
31 FP_EXC_INVALID_OPERATION = 1, // Invalid operation (e.g., square root of a negative number - qNaN by default).
32 FP_EXC_DIVISION_BY_ZERO = 2, // Division by zero (e.g., 1/0 or log(0) +- infinity by default)
33 FP_EXC_OVERFLOW = 4, // Overflow (a result is too large to be represented correctly) +- infinity by default).
34 FP_EXC_UNDERFLOW = 8, // Underflow (result too small and inexact) (returns a denormalized value by default).
35 FP_EXC_INEXACT = 16, // Inexact (returns correctly rounded result by default).
37 };
38
56
62
69
70 }
71
72}
73
74
75
76#endif
#define AGXCORE_EXPORT
void AGXCORE_EXPORT setFloatingPointExceptionSettings(int mask)
Sets global floating point exception settings for AGX, and applies them for current thread.
int AGXCORE_EXPORT getFloatingPointExceptionSettings()
Gets the global floating point exception settings.
void AGXCORE_EXPORT applyFloatingPointExceptionSettings()
Applies floating point exceptions as specified by the setFloatingPointExceptionSettings-function,...
The agx namespace contains the dynamics/math part of the AGX Dynamics API.