Fixes for building on MSVC 2015 / Qt 5.8

This commit is contained in:
Brad Davis 2016-12-01 11:11:42 -08:00
parent acdce95bba
commit 5cbf7588ac
3 changed files with 16 additions and 6 deletions

View file

@ -147,15 +147,15 @@ QString getCollisionGroupAsString(uint8_t group) {
}
uint8_t getCollisionGroupAsBitMask(const QStringRef& name) {
if (0 == name.compare("dynamic")) {
if (0 == name.compare(QString("dynamic"))) {
return USER_COLLISION_GROUP_DYNAMIC;
} else if (0 == name.compare("static")) {
} else if (0 == name.compare(QString("static"))) {
return USER_COLLISION_GROUP_STATIC;
} else if (0 == name.compare("kinematic")) {
} else if (0 == name.compare(QString("kinematic"))) {
return USER_COLLISION_GROUP_KINEMATIC;
} else if (0 == name.compare("myAvatar")) {
} else if (0 == name.compare(QString("myAvatar"))) {
return USER_COLLISION_GROUP_MY_AVATAR;
} else if (0 == name.compare("otherAvatar")) {
} else if (0 == name.compare(QString("otherAvatar"))) {
return USER_COLLISION_GROUP_OTHER_AVATAR;
}
return 0;

View file

@ -26,6 +26,15 @@
#include <windows.h>
#include "CPUIdent.h"
#include <Psapi.h>
#if _MSC_VER >= 1900
#pragma comment(lib, "legacy_stdio_definitions.lib")
FILE _iob[] = {*stdin, *stdout, *stderr};
extern "C" FILE * __cdecl __iob_func(void) {
return _iob;
}
#endif
#endif

View file

@ -1086,7 +1086,7 @@ private:
QSize _size;
QSettings _settings;
std::atomic<size_t> _renderCount;
std::atomic<size_t> _renderCount{ 0 };
gl::OffscreenContext _initContext;
RenderThread _renderThread;
QWindowCamera _camera;
@ -1152,3 +1152,4 @@ int main(int argc, char** argv) {
}
#include "main.moc"