Mudbox/mudbox.h Source File
Go to the documentation of this file.
15 #ifndef __MUDBOXSDK_MUDBOX_H__
16 #define __MUDBOXSDK_MUDBOX_H__
21 #pragma warning( disable : 4251 )
49 #define MB_SDK_VERSION_STRING "7.0.0"
57 #define MB_SDK_VERSION 0x00070000
59 #define MB_SDK_VERSION_CHECK(major, minor, patch) ((major<<16)|(minor<<8)|(patch))
68 #define MB_ASSERT( condition ) { static bool bShow = true; if (!(condition)&&mudbox::AssertFailed( __FILE__, __LINE__, #condition, "", &bShow )) __debugbreak(); }
70 #define MB_ASSERT( condition ) { static bool bShow = true; if (!(condition)) mudbox::AssertFailed( __FILE__, __LINE__, #condition, "", &bShow); }
73 #define MB_ASSERT( condition ) {}
78 #define MB_VERIFY( condition ) MB_ASSERT( condition )
80 #define MB_VERIFY( condition ) { bool b___ = condition; b___; }
87 #define MB_VERIFY_EQ( condition_, value_ ) MB_ASSERT( (condition_) == (value_) )
89 #define MB_VERIFY_EQ( condition_, value_ ) (condition_)
93 #ifndef MB_VERIFY_TRUE
95 #define MB_VERIFY_TRUE( condition_ ) MB_ASSERT( (condition_) )
97 #define MB_VERIFY_TRUE( condition_ ) (condition_)
101 #define MB_ONBUG( condition ) MB_ASSERT( !(condition) ); if ( condition )
102 #define MB_SAFELY( condition ) MB_ASSERT( condition ); if ( condition )
105 #define QT_NO_DEBUG_OUTPUT
108 #if defined( MB_TEST ) || defined( MB_DEBUG )
110 #if defined(_MSC_VER)
111 #define MB_TIMER( name ) static int ____iTimerIndex = -1; mudbox::Timer ____cTimer( __FUNCTION__" - "##name, ____iTimerIndex );
113 #define MB_TIMER( name ) static int ____iTimerIndex = -1; mudbox::Timer ____cTimer( __FILE__ " - " name, ____iTimerIndex );
117 #define MB_TIMER( name ) ;
119 #if defined(__GNUC__)
120 #define MB_ERROR throw (new mudbox::Error( "", mudbox::Error::codeUnspecified, __PRETTY_FUNCTION__, __FILE__, __LINE__ ))->Format
121 #define MB_ERRORQ(s) throw new mudbox::Error( s, mudbox::Error::codeUnspecified, __PRETTY_FUNCTION__, __FILE__, __LINE__ )
123 #define MB_ERROR throw (new mudbox::Error( "", mudbox::Error::codeUnspecified, __FUNCTION__, __FILE__, __LINE__ ))->Format
124 #define MB_ERRORQ(s) throw new mudbox::Error( s, mudbox::Error::codeUnspecified, __FUNCTION__, __FILE__, __LINE__ )
127 #define MB_PLUGIN( name, description, author, url, initializer ) mudbox::Plugin __myplugin( name, description, author, url, __DATE__" "__TIME__, initializer );
129 #if defined(QT_VERSION) || defined(MB_USE_QT)
136 #include <QtCore/QString>
137 #include <QtGui/QLabel>
138 #include <QtCore/QFileInfoList>
145 #ifndef __forceinline
146 #define __forceinline inline
150 #if defined(_MSC_VER) || defined(__INTEL_COMPILER)
152 #define __MUDBOX_HAS_OPENMP_LIB__ 1
155 #if (__GNUC__ >= 4) && (__GNUC_MINOR__ >= 2)
157 #define __MUDBOX_HAS_OPENMP_LIB__ 1
167 class XSubdivisionLevel;
172 class AttributeWidget;
176 typedef long long int64;
179 template <
typename type>
class Array;
180 template <
typename type>
class Store;
183 template <
typename type >
185 template <
typename type >
187 bool MBDLL_DECL AssertFailed(
const char *sSourceFile,
int iSourceLine,
const char *sCondition,
const char *sMessage,
bool *bShow );
193 #if defined(JAMBUILD)
280 #if defined(JAMBUILD)
288 #define MB_CHECK_GL_ERROR Kernel()->GLCheckError( __FILE__, __FUNCTION__, __LINE__ );
289 #define MB_CHECK_GL_STATES Kernel()->GLCheckStates( __FILE__, __FUNCTION__, __LINE__ );
290 #define MB_CHECK_CG_ERROR {CGerror error;\
291 const char* const lastErrorString = cgGetLastErrorString(&error); \
292 if( error != CG_NO_ERROR ) Kernel()->Log(NTRQ("Cg error: '%1'").arg(lastErrorString));}
294 #define MB_CHECK_GL_ERROR
295 #define MB_CHECK_GL_STATES
296 #define MB_CHECK_CG_ERROR
300 #define MB_SDN( a ) if( a ) { delete a; a = 0; };
GLuint GLuint GLsizei GLenum type
unsigned long long uint64
An internal helper class, representing an array. Use the Store class instead.
GLsizei const GLfloat * value
float MBDLL_DECL Modf(float value)
bool MBDLL_DECL AssertFailed(const char *sSourceFile, int iSourceLine, const char *sCondition, const char *sMessage, bool *bShow)
Class: ConvolutionKernel.
GLubyte GLubyte GLubyte a
The BrushOperation class is the base class for brush functionality.