tracy/server/TracyBadVersion.hpp

36 lines
603 B
C++
Raw Permalink Normal View History

#ifndef __TRACYBADVERSION_HPP__
#define __TRACYBADVERSION_HPP__
#include "../public/common/TracyForceInline.hpp"
2022-07-02 14:25:47 +00:00
struct ImFont;
namespace tracy
{
2019-08-12 10:04:27 +00:00
struct BadVersionState
{
enum State
{
Ok,
BadFile,
2020-02-12 18:53:37 +00:00
ReadError,
2019-08-12 10:16:48 +00:00
UnsupportedVersion,
LegacyVersion
2019-08-12 10:04:27 +00:00
};
State state = Ok;
int version = 0;
};
namespace detail
{
2021-11-13 21:20:00 +00:00
void BadVersionImpl( BadVersionState& badVer, ImFont* big );
}
2021-11-13 21:20:00 +00:00
tracy_force_inline void BadVersion( BadVersionState& badVer, ImFont* big ) { if( badVer.state != BadVersionState::Ok ) detail::BadVersionImpl( badVer, big ); }
}
#endif