optimize: clear WARNING C4353 & no exception thrown in time::Now

refactoring: Transform move to base package
This commit is contained in:
Haibo 2018-11-16 17:19:03 +08:00 committed by Nomango
parent 5875f0d2b1
commit 6ec03fa0c9
26 changed files with 270 additions and 257 deletions

View File

@ -20,22 +20,13 @@
#pragma once #pragma once
#include "macros.h" #include "macros.h"
#include "Color.h" #include "Point.hpp"
#include "Size.h" #include "Size.hpp"
#include "Rect.hpp" #include "Rect.hpp"
#include "../math/vector.hpp" #include "Color.h"
namespace easy2d namespace easy2d
{ {
// 坐标
//
// Usage:
// 表示一个二维空间的坐标: Point origin(0, 0);
// 计算两点间距离: float distance = p1.Distance(p2);
// 坐标可以相加减: Point p = Point(10, 10) + Point(20, 20); // p 的坐标是 (30, 30)
//
using Point = math::Vector2;
using String = std::wstring; using String = std::wstring;
// 方向 // 方向

View File

@ -515,12 +515,12 @@ namespace easy2d
this->SetSize(size.width, size.height); this->SetSize(size.width, size.height);
} }
math::Transform const& Node::GetTransform() const Transform const& Node::GetTransform() const
{ {
return transform_; return transform_;
} }
void Node::SetTransform(math::Transform const& transform) void Node::SetTransform(Transform const& transform)
{ {
transform_ = transform; transform_ = transform;
dirty_transform_ = true; dirty_transform_ = true;

View File

@ -25,9 +25,8 @@
#include "MouseEvent.h" #include "MouseEvent.h"
#include "ActionManager.h" #include "ActionManager.h"
#include "TaskManager.h" #include "TaskManager.h"
#include "Transform.hpp"
#include "intrusive/List.hpp" #include "intrusive/List.hpp"
#include "../math/Transform.hpp"
#include "../math/Matrix.hpp"
namespace easy2d namespace easy2d
{ {
@ -281,10 +280,10 @@ namespace easy2d
const Color& color const Color& color
); );
math::Transform const& GetTransform() const; Transform const& GetTransform() const;
void SetTransform( void SetTransform(
math::Transform const& transform Transform const& transform
); );
// 判断点是否在节点内 // 判断点是否在节点内
@ -383,7 +382,7 @@ namespace easy2d
Color border_color_; Color border_color_;
Children children_; Children children_;
ID2D1Geometry* border_; ID2D1Geometry* border_;
math::Transform transform_; Transform transform_;
math::Matrix initial_matrix_; math::Matrix initial_matrix_;
math::Matrix final_matrix_; math::Matrix final_matrix_;
}; };

84
core/base/Point.hpp Normal file
View File

@ -0,0 +1,84 @@
// Copyright (c) 2016-2018 Easy2D - Nomango
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.
#pragma once
#include "../math/vector.hpp"
#include <d2d1.h>
namespace easy2d
{
// 坐标
//
// Usage:
// 表示一个二维空间的坐标: Point origin(0, 0);
// 计算两点间距离: float distance = p1.Distance(p2);
// 坐标可以相加减: Point p = Point(10, 10) + Point(20, 20); // p 的坐标是 (30, 30)
//
class Point
: public math::Vector2
{
public:
Point() {}
Point(float x, float y) : math::Vector2(x, y) {}
Point(Point const& other) : math::Vector2(other.x, other.y) {}
inline float Distance(Point const& v)
{
return Point(x - v.x, y - v.y).Length();
}
inline const Point operator + (const Point & other) const
{
return Point(x + other.x, y + other.y);
}
inline const Point operator - (const Point & other) const
{
return Point(x - other.x, y - other.y);
}
inline const Point operator * (float val) const
{
return Point(x * val, y * val);
}
inline const Point operator / (float val) const
{
return Point(x / val, y / val);
}
inline const Point operator - () const
{
return Point(-x, -y);
}
inline bool operator == (const Point& other) const
{
return (x == other.x) && (y == other.y);
}
inline operator D2D1_POINT_2F () const
{
return D2D1_POINT_2F{ x, y };
}
};
}

View File

@ -19,8 +19,8 @@
// THE SOFTWARE. // THE SOFTWARE.
#pragma once #pragma once
#include "../math/vector.hpp" #include "Point.hpp"
#include "Size.h" #include "Size.hpp"
#include <d2d1.h> #include <d2d1.h>
namespace easy2d namespace easy2d
@ -35,8 +35,6 @@ namespace easy2d
// //
class Rect class Rect
{ {
using Point = math::Vector2;
public: public:
Point origin; // 左上角坐标 Point origin; // 左上角坐标
Size size; // 宽度和高度 Size size; // 宽度和高度
@ -100,18 +98,14 @@ namespace easy2d
inline float GetBottom() const { return origin.y + size.height; } inline float GetBottom() const { return origin.y + size.height; }
// 判断点是否在矩形内 // 判断点是否在矩形内
inline bool ContainsPoint( inline bool ContainsPoint(const Point& point) const
const Point& point
) const
{ {
return point.x >= origin.x && point.x <= (origin.y + size.height) && return point.x >= origin.x && point.x <= (origin.y + size.height) &&
point.y >= origin.y && point.y <= (origin.y + size.height); point.y >= origin.y && point.y <= (origin.y + size.height);
} }
// 判断两矩形是否相交 // 判断两矩形是否相交
inline bool Intersects( inline bool Intersects(const Rect& rect) const
const Rect& rect
) const
{ {
return !((origin.x + size.width) < rect.origin.x || return !((origin.x + size.width) < rect.origin.x ||
(rect.origin.x + rect.size.width) < origin.x || (rect.origin.x + rect.size.width) < origin.x ||

View File

@ -1,72 +0,0 @@
// Copyright (c) 2016-2018 Easy2D - Nomango
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.
#include "Size.h"
namespace easy2d
{
Size::Size()
{
width = 0;
height = 0;
}
Size::Size(float width, float height)
{
this->width = width;
this->height = height;
}
Size::Size(const Size & other)
{
width = other.width;
height = other.height;
}
const Size Size::operator+(const Size & other) const
{
return Size(width + other.width, height + other.height);
}
const Size Size::operator-(const Size & other) const
{
return Size(width - other.width, height - other.height);
}
const Size Size::operator*(float val) const
{
return Size(width * val, height * val);
}
const Size Size::operator/(float val) const
{
return Size(width / val, height / val);
}
const Size Size::operator-() const
{
return Size(-width, -height);
}
bool Size::operator==(const Size & other) const
{
return (width == other.width) && (height == other.height);
}
}

View File

@ -36,23 +36,53 @@ namespace easy2d
float height; // 高度 float height; // 高度
public: public:
Size(); Size()
{
width = 0;
height = 0;
}
Size( Size(float width, float height)
float width, {
float height this->width = width;
); this->height = height;
}
Size( Size(const Size & other)
const Size& other {
); width = other.width;
height = other.height;
}
const Size operator + (const Size & other) const; inline const Size operator+(const Size & other) const
const Size operator - (const Size & other) const; {
const Size operator * (float val) const; return Size(width + other.width, height + other.height);
const Size operator / (float val) const; }
const Size operator - () const;
bool operator== (const Size& other) const; inline const Size operator-(const Size & other) const
{
return Size(width - other.width, height - other.height);
}
inline const Size operator*(float val) const
{
return Size(width * val, height * val);
}
inline const Size operator/(float val) const
{
return Size(width / val, height / val);
}
inline const Size operator-() const
{
return Size(-width, -height);
}
inline bool operator==(const Size & other) const
{
return (width == other.width) && (height == other.height);
}
inline operator D2D1_SIZE_F () const inline operator D2D1_SIZE_F () const
{ {

View File

@ -19,22 +19,22 @@
// THE SOFTWARE. // THE SOFTWARE.
#pragma once #pragma once
#include "../base/BaseTypes.hpp" #include "Size.hpp"
#include "Matrix.hpp" #include "Point.hpp"
#include "../math/Matrix.hpp"
#include <d2d1.h>
namespace easy2d namespace easy2d
{ {
namespace math
{
class Transform class Transform
{ {
public: public:
Size size; // 大小 Size size; // 大小
float rotation; // 旋转 float rotation; // 旋转
math::Vector2 position; // ×ø±ê Point position; // ×ø±ê
math::Vector2 scale; // Ëõ·Å Point scale; // Ëõ·Å
math::Vector2 skew; // ´íÇÐ½Ç¶È Point skew; // ´íÇнǶÈ
math::Vector2 pivot; // Ö§µã Point pivot; // Ö§µã
public: public:
Transform() Transform()
@ -46,13 +46,13 @@ namespace easy2d
, pivot(0.f, 0.f) , pivot(0.f, 0.f)
{} {}
inline Matrix ToMatrix() const inline math::Matrix ToMatrix() const
{ {
auto center = Vector2{ size.width * pivot.x, size.height * pivot.y }; math::Vector2 center{ size.width * pivot.x, size.height * pivot.y };
return Matrix{} * Matrix::Scaling(scale.x, scale.y, center) return math::Matrix::Scaling(scale.x, scale.y, center)
* Matrix::Skewing(skew.x, skew.y, center) * math::Matrix::Skewing(skew.x, skew.y, center)
* Matrix::Rotation(rotation, center) * math::Matrix::Rotation(rotation, center)
* Matrix::Translation(position - center); * math::Matrix::Translation(position.x - center.x, position.y - center.y);
} }
bool operator== (const Transform& other) const bool operator== (const Transform& other) const
@ -65,5 +65,4 @@ namespace easy2d
pivot == other.pivot; pivot == other.pivot;
} }
}; };
}
} }

View File

@ -276,12 +276,12 @@ namespace easy2d
if (out_scene_) if (out_scene_)
{ {
out_scene_->SetTransform(math::Transform{}); out_scene_->SetTransform(Transform{});
} }
if (in_scene_) if (in_scene_)
{ {
auto transform = math::Transform{}; auto transform = Transform{};
transform.position = start_pos_; transform.position = start_pos_;
in_scene_->SetTransform(transform); in_scene_->SetTransform(transform);
} }
@ -293,14 +293,14 @@ namespace easy2d
if (out_scene_) if (out_scene_)
{ {
auto transform = math::Transform{}; auto transform = Transform{};
transform.position = pos_delta_ * process_; transform.position = pos_delta_ * process_;
out_scene_->SetTransform(transform); out_scene_->SetTransform(transform);
} }
if (in_scene_) if (in_scene_)
{ {
auto transform = math::Transform{}; auto transform = Transform{};
transform.position = start_pos_ + pos_delta_ * process_; transform.position = start_pos_ + pos_delta_ * process_;
in_scene_->SetTransform(transform); in_scene_->SetTransform(transform);
} }
@ -310,12 +310,12 @@ namespace easy2d
{ {
if (out_scene_) if (out_scene_)
{ {
out_scene_->SetTransform(math::Transform{}); out_scene_->SetTransform(Transform{});
} }
if (in_scene_) if (in_scene_)
{ {
in_scene_->SetTransform(math::Transform{}); in_scene_->SetTransform(Transform{});
} }
} }
@ -333,7 +333,7 @@ namespace easy2d
{ {
Transition::Init(prev, next); Transition::Init(prev, next);
auto transform = math::Transform{}; auto transform = Transform{};
transform.pivot = Point{ 0.5f, 0.5f }; transform.pivot = Point{ 0.5f, 0.5f };
transform.position = Point{ window_size_.width / 2, window_size_.height / 2 }; transform.position = Point{ window_size_.width / 2, window_size_.height / 2 };
@ -384,12 +384,12 @@ namespace easy2d
{ {
if (out_scene_) if (out_scene_)
{ {
out_scene_->SetTransform(math::Transform{}); out_scene_->SetTransform(Transform{});
} }
if (in_scene_) if (in_scene_)
{ {
in_scene_->SetTransform(math::Transform{}); in_scene_->SetTransform(Transform{});
} }
} }
} }

View File

@ -25,7 +25,7 @@
#include <mfapi.h> #include <mfapi.h>
#include <mfidl.h> #include <mfidl.h>
#include <mfreadwrite.h> #include <mfreadwrite.h>
#include <assert.h>
namespace easy2d namespace easy2d
{ {
//------------------------------------------------------- //-------------------------------------------------------

View File

@ -20,8 +20,8 @@
#pragma once #pragma once
#include "BaseTypes.hpp" #include "BaseTypes.hpp"
#include "intrusive/SmartPointer.hpp"
#include "RefCounter.hpp" #include "RefCounter.hpp"
#include "intrusive/SmartPointer.hpp"
#ifndef E2D_DECLARE_SMART_PTR #ifndef E2D_DECLARE_SMART_PTR

View File

@ -22,6 +22,13 @@
#include <stdexcept> #include <stdexcept>
#include <functional> #include <functional>
#undef DEBUG_CHECK_LIST
#ifdef E2D_DEBUG
# define DEBUG_CHECK_LIST(list_ptr) list_ptr->Check()
#else
# define DEBUG_CHECK_LIST __noop
#endif
namespace easy2d namespace easy2d
{ {
namespace intrusive namespace intrusive
@ -95,9 +102,7 @@ namespace easy2d
last_ = child; last_ = child;
++size_; ++size_;
#ifdef E2D_DEBUG DEBUG_CHECK_LIST(this);
Check();
#endif
} }
void PushFront(T& child) void PushFront(T& child)
@ -117,9 +122,7 @@ namespace easy2d
first_ = child; first_ = child;
++size_; ++size_;
#ifdef E2D_DEBUG DEBUG_CHECK_LIST(this);
Check();
#endif
} }
void Remove(T& child) void Remove(T& child)
@ -156,9 +159,7 @@ namespace easy2d
child->next_ = nullptr; child->next_ = nullptr;
--size_; --size_;
#ifdef E2D_DEBUG DEBUG_CHECK_LIST(this);
Check();
#endif
} }
void Insert(T& child, T& before) void Insert(T& child, T& before)
@ -173,9 +174,7 @@ namespace easy2d
before->prev_ = child; before->prev_ = child;
++size_; ++size_;
#ifdef E2D_DEBUG DEBUG_CHECK_LIST(this);
Check();
#endif
} }
void Clear() void Clear()
@ -229,9 +228,7 @@ namespace easy2d
first_ = *temp_vec.begin(); first_ = *temp_vec.begin();
last_ = *temp_vec.rbegin(); last_ = *temp_vec.rbegin();
#ifdef E2D_DEBUG DEBUG_CHECK_LIST(this);
Check();
#endif
} }
#ifdef E2D_DEBUG #ifdef E2D_DEBUG
@ -271,3 +268,5 @@ namespace easy2d
}; };
} }
} }
#undef DEBUG_CHECK_LIST

View File

@ -30,7 +30,7 @@
# ifdef E2D_DEBUG # ifdef E2D_DEBUG
# define E2D_LOG(format, ...) easy2d::logs::Println(format, ##__VA_ARGS__) # define E2D_LOG(format, ...) easy2d::logs::Println(format, ##__VA_ARGS__)
# else # else
# define E2D_LOG ((void)0) # define E2D_LOG __noop
# endif # endif
#endif #endif

View File

@ -32,6 +32,18 @@ namespace easy2d
{ {
namespace devices namespace devices
{ {
namespace
{
inline D2D1_MATRIX_3X2_F ConvertToD2DMatrix(math::Matrix const& matrix)
{
return D2D1_MATRIX_3X2_F{
matrix.m[0], matrix.m[1],
matrix.m[2], matrix.m[3],
matrix.m[4], matrix.m[5]
};
}
}
GraphicsDevice::GraphicsDevice() GraphicsDevice::GraphicsDevice()
: fps_text_format_(nullptr) : fps_text_format_(nullptr)
, fps_text_layout_(nullptr) , fps_text_layout_(nullptr)
@ -211,7 +223,7 @@ namespace easy2d
{ {
hr = d2d.factory->CreateTransformedGeometry( hr = d2d.factory->CreateTransformedGeometry(
rectangle, rectangle,
matrix, ConvertToD2DMatrix(matrix),
&transformed &transformed
); );
} }
@ -340,7 +352,7 @@ namespace easy2d
if (!d2d.render_target) if (!d2d.render_target)
return E_UNEXPECTED; return E_UNEXPECTED;
d2d.render_target->SetTransform(clip_matrix); d2d.render_target->SetTransform(ConvertToD2DMatrix(clip_matrix));
d2d.render_target->PushAxisAlignedClip( d2d.render_target->PushAxisAlignedClip(
D2D1::RectF(0, 0, clip_size.width, clip_size.height), D2D1::RectF(0, 0, clip_size.width, clip_size.height),
D2D1_ANTIALIAS_MODE_PER_PRIMITIVE D2D1_ANTIALIAS_MODE_PER_PRIMITIVE
@ -591,7 +603,7 @@ namespace easy2d
if (!d2d.render_target) if (!d2d.render_target)
return E_UNEXPECTED; return E_UNEXPECTED;
d2d.render_target->SetTransform(matrix); d2d.render_target->SetTransform(ConvertToD2DMatrix(matrix));
return S_OK; return S_OK;
} }

View File

@ -434,17 +434,13 @@ namespace easy2d
// Functions // Functions
//------------------------------------------------------- //-------------------------------------------------------
TimePoint easy2d::time::Now() TimePoint easy2d::time::Now() E2D_NOEXCEPT
{ {
static LARGE_INTEGER freq = {}; static LARGE_INTEGER freq = {};
if (freq.QuadPart == 0LL) if (freq.QuadPart == 0LL)
{ {
if (QueryPerformanceFrequency(&freq) == 0) // the function will always succceed on systems that run Windows XP or later
{ QueryPerformanceFrequency(&freq);
const char* err = "QueryPerformanceFrequency not supported";
logs::Errorln(HRESULT_FROM_WIN32(GetLastError()), err);
throw std::runtime_error(err);
}
} }
LARGE_INTEGER count; LARGE_INTEGER count;

View File

@ -177,7 +177,7 @@ namespace easy2d
}; };
// 获取当前时间 // 获取当前时间
TimePoint Now(); TimePoint Now() E2D_NOEXCEPT;
// 时间段格式化 // 时间段格式化
// 时间段字符串允许是有符号的浮点数, 并且带有时间单位后缀 // 时间段字符串允许是有符号的浮点数, 并且带有时间单位后缀

View File

@ -119,7 +119,7 @@ namespace easy2d
::UnregisterClass(REGISTER_CLASS, hinstance); ::UnregisterClass(REGISTER_CLASS, hinstance);
const char* err = "Create window failed!"; const char* err = "Create window failed!";
logs::Errorln(err); logs::Errorln(HRESULT_FROM_WIN32(GetLastError()), err);
throw std::runtime_error(err); throw std::runtime_error(err);
} }

View File

@ -40,12 +40,14 @@
#include "base/time.h" #include "base/time.h"
#include "base/logs.h" #include "base/logs.h"
#include "base/Size.h" #include "base/Point.hpp"
#include "base/Size.hpp"
#include "base/Rect.hpp" #include "base/Rect.hpp"
#include "base/Font.hpp" #include "base/Font.hpp"
#include "base/TextStyle.hpp"
#include "base/Color.h" #include "base/Color.h"
#include "base/Resource.h" #include "base/Resource.h"
#include "base/Transform.hpp"
#include "base/TextStyle.hpp"
#include "base/intrusive/SmartPointer.hpp" #include "base/intrusive/SmartPointer.hpp"
#include "base/intrusive/List.hpp" #include "base/intrusive/List.hpp"
@ -78,9 +80,8 @@
#include "math/scalar.hpp" #include "math/scalar.hpp"
#include "math/vector.hpp" #include "math/vector.hpp"
#include "math/Matrix.hpp"
#include "math/Transform.hpp"
#include "math/rand.h" #include "math/rand.h"
#include "math/Matrix.hpp"
// //

View File

@ -20,7 +20,6 @@
#pragma once #pragma once
#include "vector.hpp" #include "vector.hpp"
#include <d2d1.h>
namespace easy2d namespace easy2d
{ {
@ -41,6 +40,7 @@ namespace easy2d
class Matrix class Matrix
{ {
public:
float m[6]; // m[3][2] float m[6]; // m[3][2]
public: public:
@ -91,15 +91,6 @@ namespace easy2d
return *this; return *this;
} }
inline operator D2D1_MATRIX_3X2_F () const
{
return D2D1_MATRIX_3X2_F{
m[0], m[1],
m[2], m[3],
m[4], m[5]
};
}
inline Matrix& Identity() inline Matrix& Identity()
{ {
m[0] = 1.f; m[1] = 0.f; m[0] = 1.f; m[1] = 0.f;

View File

@ -20,7 +20,6 @@
#pragma once #pragma once
#include "scalar.hpp" #include "scalar.hpp"
#include <d2d1.h>
namespace easy2d namespace easy2d
{ {
@ -55,11 +54,6 @@ namespace easy2d
return math::Sqrt(x * x + y * y); return math::Sqrt(x * x + y * y);
} }
inline float Distance(const Vector2& v)
{
return Vector2(x - v.x, y - v.y).Length();
}
inline const Vector2 operator + (const Vector2 & other) const inline const Vector2 operator + (const Vector2 & other) const
{ {
return Vector2(x + other.x, y + other.y); return Vector2(x + other.x, y + other.y);
@ -89,11 +83,6 @@ namespace easy2d
{ {
return (x == other.x) && (y == other.y); return (x == other.x) && (y == other.y);
} }
inline operator D2D1_POINT_2F () const
{
return D2D1_POINT_2F{ x, y };
}
}; };
} }
} }

View File

@ -43,13 +43,14 @@
<ClInclude Include="..\..\core\base\MouseEvent.h" /> <ClInclude Include="..\..\core\base\MouseEvent.h" />
<ClInclude Include="..\..\core\base\Music.h" /> <ClInclude Include="..\..\core\base\Music.h" />
<ClInclude Include="..\..\core\base\Node.h" /> <ClInclude Include="..\..\core\base\Node.h" />
<ClInclude Include="..\..\core\base\Point.hpp" />
<ClInclude Include="..\..\core\base\Rect.hpp" /> <ClInclude Include="..\..\core\base\Rect.hpp" />
<ClInclude Include="..\..\core\base\RefCounter.hpp" /> <ClInclude Include="..\..\core\base\RefCounter.hpp" />
<ClInclude Include="..\..\core\base\render.h" /> <ClInclude Include="..\..\core\base\render.h" />
<ClInclude Include="..\..\core\base\Resource.h" /> <ClInclude Include="..\..\core\base\Resource.h" />
<ClInclude Include="..\..\core\base\Scene.h" /> <ClInclude Include="..\..\core\base\Scene.h" />
<ClInclude Include="..\..\core\base\Singleton.hpp" /> <ClInclude Include="..\..\core\base\Singleton.hpp" />
<ClInclude Include="..\..\core\base\Size.h" /> <ClInclude Include="..\..\core\base\Size.hpp" />
<ClInclude Include="..\..\core\base\Sprite.h" /> <ClInclude Include="..\..\core\base\Sprite.h" />
<ClInclude Include="..\..\core\base\Task.h" /> <ClInclude Include="..\..\core\base\Task.h" />
<ClInclude Include="..\..\core\base\TaskManager.h" /> <ClInclude Include="..\..\core\base\TaskManager.h" />
@ -57,13 +58,13 @@
<ClInclude Include="..\..\core\base\TextRenderer.h" /> <ClInclude Include="..\..\core\base\TextRenderer.h" />
<ClInclude Include="..\..\core\base\TextStyle.hpp" /> <ClInclude Include="..\..\core\base\TextStyle.hpp" />
<ClInclude Include="..\..\core\base\time.h" /> <ClInclude Include="..\..\core\base\time.h" />
<ClInclude Include="..\..\core\base\Transform.hpp" />
<ClInclude Include="..\..\core\base\Transition.h" /> <ClInclude Include="..\..\core\base\Transition.h" />
<ClInclude Include="..\..\core\base\window.h" /> <ClInclude Include="..\..\core\base\window.h" />
<ClInclude Include="..\..\core\easy2d.h" /> <ClInclude Include="..\..\core\easy2d.h" />
<ClInclude Include="..\..\core\math\Matrix.hpp" /> <ClInclude Include="..\..\core\math\Matrix.hpp" />
<ClInclude Include="..\..\core\math\rand.h" /> <ClInclude Include="..\..\core\math\rand.h" />
<ClInclude Include="..\..\core\math\scalar.hpp" /> <ClInclude Include="..\..\core\math\scalar.hpp" />
<ClInclude Include="..\..\core\math\Transform.hpp" />
<ClInclude Include="..\..\core\math\vector.hpp" /> <ClInclude Include="..\..\core\math\vector.hpp" />
<ClInclude Include="..\..\core\ui\Button.h" /> <ClInclude Include="..\..\core\ui\Button.h" />
<ClInclude Include="..\..\core\ui\Menu.h" /> <ClInclude Include="..\..\core\ui\Menu.h" />
@ -93,7 +94,6 @@
<ClCompile Include="..\..\core\base\render.cpp" /> <ClCompile Include="..\..\core\base\render.cpp" />
<ClCompile Include="..\..\core\base\Resource.cpp" /> <ClCompile Include="..\..\core\base\Resource.cpp" />
<ClCompile Include="..\..\core\base\Scene.cpp" /> <ClCompile Include="..\..\core\base\Scene.cpp" />
<ClCompile Include="..\..\core\base\Size.cpp" />
<ClCompile Include="..\..\core\base\Sprite.cpp" /> <ClCompile Include="..\..\core\base\Sprite.cpp" />
<ClCompile Include="..\..\core\base\Task.cpp" /> <ClCompile Include="..\..\core\base\Task.cpp" />
<ClCompile Include="..\..\core\base\TaskManager.cpp" /> <ClCompile Include="..\..\core\base\TaskManager.cpp" />

View File

@ -56,9 +56,6 @@
<ClInclude Include="..\..\core\base\Scene.h"> <ClInclude Include="..\..\core\base\Scene.h">
<Filter>base</Filter> <Filter>base</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="..\..\core\base\Size.h">
<Filter>base</Filter>
</ClInclude>
<ClInclude Include="..\..\core\base\Sprite.h"> <ClInclude Include="..\..\core\base\Sprite.h">
<Filter>base</Filter> <Filter>base</Filter>
</ClInclude> </ClInclude>
@ -137,9 +134,6 @@
<ClInclude Include="..\..\core\base\TaskManager.h"> <ClInclude Include="..\..\core\base\TaskManager.h">
<Filter>base</Filter> <Filter>base</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="..\..\core\math\Transform.hpp">
<Filter>math</Filter>
</ClInclude>
<ClInclude Include="..\..\core\base\TextStyle.hpp"> <ClInclude Include="..\..\core\base\TextStyle.hpp">
<Filter>base</Filter> <Filter>base</Filter>
</ClInclude> </ClInclude>
@ -158,6 +152,15 @@
<ClInclude Include="..\..\core\base\BaseTypes.hpp"> <ClInclude Include="..\..\core\base\BaseTypes.hpp">
<Filter>base</Filter> <Filter>base</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="..\..\core\base\Transform.hpp">
<Filter>base</Filter>
</ClInclude>
<ClInclude Include="..\..\core\base\Point.hpp">
<Filter>base</Filter>
</ClInclude>
<ClInclude Include="..\..\core\base\Size.hpp">
<Filter>base</Filter>
</ClInclude>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<Filter Include="base"> <Filter Include="base">
@ -222,9 +225,6 @@
<ClCompile Include="..\..\core\base\Scene.cpp"> <ClCompile Include="..\..\core\base\Scene.cpp">
<Filter>base</Filter> <Filter>base</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="..\..\core\base\Size.cpp">
<Filter>base</Filter>
</ClCompile>
<ClCompile Include="..\..\core\base\Sprite.cpp"> <ClCompile Include="..\..\core\base\Sprite.cpp">
<Filter>base</Filter> <Filter>base</Filter>
</ClCompile> </ClCompile>

View File

@ -43,13 +43,14 @@
<ClInclude Include="..\..\core\base\MouseEvent.h" /> <ClInclude Include="..\..\core\base\MouseEvent.h" />
<ClInclude Include="..\..\core\base\Music.h" /> <ClInclude Include="..\..\core\base\Music.h" />
<ClInclude Include="..\..\core\base\Node.h" /> <ClInclude Include="..\..\core\base\Node.h" />
<ClInclude Include="..\..\core\base\Point.hpp" />
<ClInclude Include="..\..\core\base\Rect.hpp" /> <ClInclude Include="..\..\core\base\Rect.hpp" />
<ClInclude Include="..\..\core\base\RefCounter.hpp" /> <ClInclude Include="..\..\core\base\RefCounter.hpp" />
<ClInclude Include="..\..\core\base\render.h" /> <ClInclude Include="..\..\core\base\render.h" />
<ClInclude Include="..\..\core\base\Resource.h" /> <ClInclude Include="..\..\core\base\Resource.h" />
<ClInclude Include="..\..\core\base\Scene.h" /> <ClInclude Include="..\..\core\base\Scene.h" />
<ClInclude Include="..\..\core\base\Singleton.hpp" /> <ClInclude Include="..\..\core\base\Singleton.hpp" />
<ClInclude Include="..\..\core\base\Size.h" /> <ClInclude Include="..\..\core\base\Size.hpp" />
<ClInclude Include="..\..\core\base\Sprite.h" /> <ClInclude Include="..\..\core\base\Sprite.h" />
<ClInclude Include="..\..\core\base\Task.h" /> <ClInclude Include="..\..\core\base\Task.h" />
<ClInclude Include="..\..\core\base\TaskManager.h" /> <ClInclude Include="..\..\core\base\TaskManager.h" />
@ -57,13 +58,13 @@
<ClInclude Include="..\..\core\base\TextRenderer.h" /> <ClInclude Include="..\..\core\base\TextRenderer.h" />
<ClInclude Include="..\..\core\base\TextStyle.hpp" /> <ClInclude Include="..\..\core\base\TextStyle.hpp" />
<ClInclude Include="..\..\core\base\time.h" /> <ClInclude Include="..\..\core\base\time.h" />
<ClInclude Include="..\..\core\base\Transform.hpp" />
<ClInclude Include="..\..\core\base\Transition.h" /> <ClInclude Include="..\..\core\base\Transition.h" />
<ClInclude Include="..\..\core\base\window.h" /> <ClInclude Include="..\..\core\base\window.h" />
<ClInclude Include="..\..\core\easy2d.h" /> <ClInclude Include="..\..\core\easy2d.h" />
<ClInclude Include="..\..\core\math\Matrix.hpp" /> <ClInclude Include="..\..\core\math\Matrix.hpp" />
<ClInclude Include="..\..\core\math\rand.h" /> <ClInclude Include="..\..\core\math\rand.h" />
<ClInclude Include="..\..\core\math\scalar.hpp" /> <ClInclude Include="..\..\core\math\scalar.hpp" />
<ClInclude Include="..\..\core\math\Transform.hpp" />
<ClInclude Include="..\..\core\math\vector.hpp" /> <ClInclude Include="..\..\core\math\vector.hpp" />
<ClInclude Include="..\..\core\ui\Button.h" /> <ClInclude Include="..\..\core\ui\Button.h" />
<ClInclude Include="..\..\core\ui\Menu.h" /> <ClInclude Include="..\..\core\ui\Menu.h" />
@ -93,7 +94,6 @@
<ClCompile Include="..\..\core\base\render.cpp" /> <ClCompile Include="..\..\core\base\render.cpp" />
<ClCompile Include="..\..\core\base\Resource.cpp" /> <ClCompile Include="..\..\core\base\Resource.cpp" />
<ClCompile Include="..\..\core\base\Scene.cpp" /> <ClCompile Include="..\..\core\base\Scene.cpp" />
<ClCompile Include="..\..\core\base\Size.cpp" />
<ClCompile Include="..\..\core\base\Sprite.cpp" /> <ClCompile Include="..\..\core\base\Sprite.cpp" />
<ClCompile Include="..\..\core\base\Task.cpp" /> <ClCompile Include="..\..\core\base\Task.cpp" />
<ClCompile Include="..\..\core\base\TaskManager.cpp" /> <ClCompile Include="..\..\core\base\TaskManager.cpp" />

View File

@ -56,9 +56,6 @@
<ClInclude Include="..\..\core\base\Scene.h"> <ClInclude Include="..\..\core\base\Scene.h">
<Filter>base</Filter> <Filter>base</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="..\..\core\base\Size.h">
<Filter>base</Filter>
</ClInclude>
<ClInclude Include="..\..\core\base\Sprite.h"> <ClInclude Include="..\..\core\base\Sprite.h">
<Filter>base</Filter> <Filter>base</Filter>
</ClInclude> </ClInclude>
@ -137,9 +134,6 @@
<ClInclude Include="..\..\core\base\TaskManager.h"> <ClInclude Include="..\..\core\base\TaskManager.h">
<Filter>base</Filter> <Filter>base</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="..\..\core\math\Transform.hpp">
<Filter>math</Filter>
</ClInclude>
<ClInclude Include="..\..\core\base\TextStyle.hpp"> <ClInclude Include="..\..\core\base\TextStyle.hpp">
<Filter>base</Filter> <Filter>base</Filter>
</ClInclude> </ClInclude>
@ -158,6 +152,15 @@
<ClInclude Include="..\..\core\base\BaseTypes.hpp"> <ClInclude Include="..\..\core\base\BaseTypes.hpp">
<Filter>base</Filter> <Filter>base</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="..\..\core\base\Transform.hpp">
<Filter>base</Filter>
</ClInclude>
<ClInclude Include="..\..\core\base\Point.hpp">
<Filter>base</Filter>
</ClInclude>
<ClInclude Include="..\..\core\base\Size.hpp">
<Filter>base</Filter>
</ClInclude>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<Filter Include="base"> <Filter Include="base">
@ -222,9 +225,6 @@
<ClCompile Include="..\..\core\base\Scene.cpp"> <ClCompile Include="..\..\core\base\Scene.cpp">
<Filter>base</Filter> <Filter>base</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="..\..\core\base\Size.cpp">
<Filter>base</Filter>
</ClCompile>
<ClCompile Include="..\..\core\base\Sprite.cpp"> <ClCompile Include="..\..\core\base\Sprite.cpp">
<Filter>base</Filter> <Filter>base</Filter>
</ClCompile> </ClCompile>

View File

@ -43,13 +43,14 @@
<ClInclude Include="..\..\core\base\MouseEvent.h" /> <ClInclude Include="..\..\core\base\MouseEvent.h" />
<ClInclude Include="..\..\core\base\Music.h" /> <ClInclude Include="..\..\core\base\Music.h" />
<ClInclude Include="..\..\core\base\Node.h" /> <ClInclude Include="..\..\core\base\Node.h" />
<ClInclude Include="..\..\core\base\Point.hpp" />
<ClInclude Include="..\..\core\base\Rect.hpp" /> <ClInclude Include="..\..\core\base\Rect.hpp" />
<ClInclude Include="..\..\core\base\RefCounter.hpp" /> <ClInclude Include="..\..\core\base\RefCounter.hpp" />
<ClInclude Include="..\..\core\base\render.h" /> <ClInclude Include="..\..\core\base\render.h" />
<ClInclude Include="..\..\core\base\Resource.h" /> <ClInclude Include="..\..\core\base\Resource.h" />
<ClInclude Include="..\..\core\base\Scene.h" /> <ClInclude Include="..\..\core\base\Scene.h" />
<ClInclude Include="..\..\core\base\Singleton.hpp" /> <ClInclude Include="..\..\core\base\Singleton.hpp" />
<ClInclude Include="..\..\core\base\Size.h" /> <ClInclude Include="..\..\core\base\Size.hpp" />
<ClInclude Include="..\..\core\base\Sprite.h" /> <ClInclude Include="..\..\core\base\Sprite.h" />
<ClInclude Include="..\..\core\base\Task.h" /> <ClInclude Include="..\..\core\base\Task.h" />
<ClInclude Include="..\..\core\base\TaskManager.h" /> <ClInclude Include="..\..\core\base\TaskManager.h" />
@ -57,13 +58,13 @@
<ClInclude Include="..\..\core\base\TextRenderer.h" /> <ClInclude Include="..\..\core\base\TextRenderer.h" />
<ClInclude Include="..\..\core\base\TextStyle.hpp" /> <ClInclude Include="..\..\core\base\TextStyle.hpp" />
<ClInclude Include="..\..\core\base\time.h" /> <ClInclude Include="..\..\core\base\time.h" />
<ClInclude Include="..\..\core\base\Transform.hpp" />
<ClInclude Include="..\..\core\base\Transition.h" /> <ClInclude Include="..\..\core\base\Transition.h" />
<ClInclude Include="..\..\core\base\window.h" /> <ClInclude Include="..\..\core\base\window.h" />
<ClInclude Include="..\..\core\easy2d.h" /> <ClInclude Include="..\..\core\easy2d.h" />
<ClInclude Include="..\..\core\math\Matrix.hpp" /> <ClInclude Include="..\..\core\math\Matrix.hpp" />
<ClInclude Include="..\..\core\math\rand.h" /> <ClInclude Include="..\..\core\math\rand.h" />
<ClInclude Include="..\..\core\math\scalar.hpp" /> <ClInclude Include="..\..\core\math\scalar.hpp" />
<ClInclude Include="..\..\core\math\Transform.hpp" />
<ClInclude Include="..\..\core\math\vector.hpp" /> <ClInclude Include="..\..\core\math\vector.hpp" />
<ClInclude Include="..\..\core\ui\Button.h" /> <ClInclude Include="..\..\core\ui\Button.h" />
<ClInclude Include="..\..\core\ui\Menu.h" /> <ClInclude Include="..\..\core\ui\Menu.h" />
@ -93,7 +94,6 @@
<ClCompile Include="..\..\core\base\render.cpp" /> <ClCompile Include="..\..\core\base\render.cpp" />
<ClCompile Include="..\..\core\base\Resource.cpp" /> <ClCompile Include="..\..\core\base\Resource.cpp" />
<ClCompile Include="..\..\core\base\Scene.cpp" /> <ClCompile Include="..\..\core\base\Scene.cpp" />
<ClCompile Include="..\..\core\base\Size.cpp" />
<ClCompile Include="..\..\core\base\Sprite.cpp" /> <ClCompile Include="..\..\core\base\Sprite.cpp" />
<ClCompile Include="..\..\core\base\Task.cpp" /> <ClCompile Include="..\..\core\base\Task.cpp" />
<ClCompile Include="..\..\core\base\TaskManager.cpp" /> <ClCompile Include="..\..\core\base\TaskManager.cpp" />
@ -201,7 +201,7 @@
<Optimization>Disabled</Optimization> <Optimization>Disabled</Optimization>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> <PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<SDLCheck>false</SDLCheck> <SDLCheck>false</SDLCheck>
<DebugInformationFormat>EditAndContinue</DebugInformationFormat> <DebugInformationFormat>None</DebugInformationFormat>
<MinimalRebuild>false</MinimalRebuild> <MinimalRebuild>false</MinimalRebuild>
<TreatWarningAsError>true</TreatWarningAsError> <TreatWarningAsError>true</TreatWarningAsError>
</ClCompile> </ClCompile>

View File

@ -56,9 +56,6 @@
<ClInclude Include="..\..\core\base\Scene.h"> <ClInclude Include="..\..\core\base\Scene.h">
<Filter>base</Filter> <Filter>base</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="..\..\core\base\Size.h">
<Filter>base</Filter>
</ClInclude>
<ClInclude Include="..\..\core\base\Sprite.h"> <ClInclude Include="..\..\core\base\Sprite.h">
<Filter>base</Filter> <Filter>base</Filter>
</ClInclude> </ClInclude>
@ -137,9 +134,6 @@
<ClInclude Include="..\..\core\base\TaskManager.h"> <ClInclude Include="..\..\core\base\TaskManager.h">
<Filter>base</Filter> <Filter>base</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="..\..\core\math\Transform.hpp">
<Filter>math</Filter>
</ClInclude>
<ClInclude Include="..\..\core\base\TextStyle.hpp"> <ClInclude Include="..\..\core\base\TextStyle.hpp">
<Filter>base</Filter> <Filter>base</Filter>
</ClInclude> </ClInclude>
@ -158,6 +152,15 @@
<ClInclude Include="..\..\core\base\BaseTypes.hpp"> <ClInclude Include="..\..\core\base\BaseTypes.hpp">
<Filter>base</Filter> <Filter>base</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="..\..\core\base\Transform.hpp">
<Filter>base</Filter>
</ClInclude>
<ClInclude Include="..\..\core\base\Point.hpp">
<Filter>base</Filter>
</ClInclude>
<ClInclude Include="..\..\core\base\Size.hpp">
<Filter>base</Filter>
</ClInclude>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<Filter Include="base"> <Filter Include="base">
@ -222,9 +225,6 @@
<ClCompile Include="..\..\core\base\Scene.cpp"> <ClCompile Include="..\..\core\base\Scene.cpp">
<Filter>base</Filter> <Filter>base</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="..\..\core\base\Size.cpp">
<Filter>base</Filter>
</ClCompile>
<ClCompile Include="..\..\core\base\Sprite.cpp"> <ClCompile Include="..\..\core\base\Sprite.cpp">
<Filter>base</Filter> <Filter>base</Filter>
</ClCompile> </ClCompile>