These could lead to undefined behaviour if e.g. a negative value from ftell
was used to allocate memory.
Also store result of ftell in a long;
The result may previously have been truncated on some platforms
This adds the ability for geometry sets to store build settings that can
be automatically applied when they are loaded. This should allow sharing
of .gset files to demonstrate problems with certain settings on certain
files. It also allows people to diagnose problems more easily by being
able to dump their own triangle meshes and settings and load them in the
demo, with all of its visualization options. .gset files can be created
from the current mesh and settings by pressing the 9 key, which will
generate it in the same folder as the input mesh.
Also converts more of the demo to use STL.
* Removed some unused vars
* Fixed some signed/unsigned comparison mismatch warnings
* Cast some int's to size_t when appropriate
* Removed some redundant casts
* silenced warnings about implicit conversions that lose precision
* changed origMousePos to an array of ints to match mousePos
The demo relied on the build context returning accumulated times in
microseconds. On Windows this was using QueryPerformanceCounter directly
which has a higher resolution, thus returning wrong measured times. We
now report the accumulated times in microseconds on all platforms.
* Renamed a bunch of variables in main.cpp to be more descriptive.
* Removed unnecessary SDLMain.h and SDLMain.m OSX objective-c class as well as the plist, strings, xib and icns files, which are not needed.
* included cstdio in imguiRenderGL since SDL2 doesn't do it for us.
* Updated premake5 script to support SDL2 and to set the debug directory, as well as copy the SDL2.dll to the target directory on Windows.
* Updated readme with more descriptive, platform-specific demo project setup instructions
* Updated appveyor build script to build vs2015 as well.
* Updated Travis build script to build SDL2 from source, because they use Ubuntu 12.04 which doesn't have the libsdl2-dev package in its repositories.