Skip to content

Commit

Permalink
Fixed xml deserialization crash
Browse files Browse the repository at this point in the history
  • Loading branch information
mikoro committed Nov 17, 2015
1 parent c87ec2d commit db5b7d1
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 21 deletions.
6 changes: 5 additions & 1 deletion raycer.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,11 @@
<ClCompile Include="src\Raytracing\Primitives\Torus.cpp" />
<ClCompile Include="src\Raytracing\Primitives\Triangle.cpp" />
<ClCompile Include="src\Raytracing\Ray.cpp" />
<ClCompile Include="src\Raytracing\Scene.cpp" />
<ClCompile Include="src\Raytracing\Scene.cpp">
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">NotUsing</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">NotUsing</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='DebugTest|x64'">NotUsing</PrecompiledHeader>
</ClCompile>
<ClCompile Include="src\Raytracing\Textures\AtmosphereTexture.cpp" />
<ClCompile Include="src\Raytracing\Textures\CellNoiseTexture.cpp" />
<ClCompile Include="src\Raytracing\Textures\CheckerTexture.cpp" />
Expand Down
5 changes: 5 additions & 0 deletions src/App.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@

#include "stdafx.h"

#include "tclap/CmdLine.h"
#include "tclap/SwitchArg.h"
#include "tclap/ValueArg.h"
#include "tclap/ArgException.h"

#include "App.h"
#include "Settings.h"
#include "Utils/Log.h"
Expand Down
12 changes: 11 additions & 1 deletion src/Raytracing/Scene.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,17 @@
// Copyright © 2015 Mikko Ronkainen <[email protected]>
// License: MIT, see the LICENSE file.

#include "stdafx.h"
// when using precompiled headers with this file, the deserialization of XML files will crash in release mode
//#include "stdafx.h"

#include "tinyformat/tinyformat.h"

#include "cereal/cereal.hpp"
#include "cereal/archives/json.hpp"
#include "cereal/archives/xml.hpp"
#include "cereal/archives/binary.hpp"
#include "cereal/types/vector.hpp"
#include "cereal/types/string.hpp"

#include "Raytracing/Scene.h"
#include "Raytracing/Primitives/Primitive.h"
Expand Down
7 changes: 7 additions & 0 deletions src/Rendering/Text.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,13 @@

#include "stdafx.h"

#include "freetype-gl/mat4.h"
#include "freetype-gl/vertex-buffer.h"
#include "freetype-gl/texture-atlas.h"
#include "freetype-gl/texture-font.h"

#include "utf8/utf8/unchecked.h"

#include "Rendering/Text.h"
#include "App.h"
#include "Utils/Log.h"
Expand Down
19 changes: 0 additions & 19 deletions src/stdafx.h
Original file line number Diff line number Diff line change
Expand Up @@ -63,25 +63,6 @@

#include "tinyformat/tinyformat.h"

#include "utf8/utf8/unchecked.h"

#include "cereal/cereal.hpp"
#include "cereal/archives/json.hpp"
#include "cereal/archives/xml.hpp"
#include "cereal/archives/binary.hpp"
#include "cereal/types/vector.hpp"
#include "cereal/types/string.hpp"

#include "freetype-gl/mat4.h"
#include "freetype-gl/vertex-buffer.h"
#include "freetype-gl/texture-atlas.h"
#include "freetype-gl/texture-font.h"

#include "tclap/CmdLine.h"
#include "tclap/SwitchArg.h"
#include "tclap/ValueArg.h"
#include "tclap/ArgException.h"

#ifdef __APPLE__
#include <Carbon/Carbon.h>
#include <CoreFoundation/CoreFoundation.h>
Expand Down

0 comments on commit db5b7d1

Please sign in to comment.