FIX:程序无法运行的问题
parent
169aa9501c
commit
55f37fd284
|
@ -3,6 +3,7 @@
|
||||||
#include <QJsonArray>
|
#include <QJsonArray>
|
||||||
#include <QJsonObject>
|
#include <QJsonObject>
|
||||||
#include <QPainterPath>
|
#include <QPainterPath>
|
||||||
|
#include <QImage>
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
#include "../Renderer/Painting/ElementStyle.h"
|
#include "../Renderer/Painting/ElementStyle.h"
|
||||||
|
@ -49,6 +50,9 @@ public:
|
||||||
|
|
||||||
//******************************** BitmapPath ********************************//
|
//******************************** BitmapPath ********************************//
|
||||||
|
|
||||||
|
using std::vector;
|
||||||
|
using std::shared_ptr;
|
||||||
|
|
||||||
class BitmapPath
|
class BitmapPath
|
||||||
{
|
{
|
||||||
protected:
|
protected:
|
||||||
|
|
|
@ -12,6 +12,8 @@
|
||||||
#include <QTreeWidget>
|
#include <QTreeWidget>
|
||||||
#include <memory>
|
#include <memory>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
|
#include "../Renderer/Painting/ElementStyle.h"
|
||||||
using std::shared_ptr;
|
using std::shared_ptr;
|
||||||
using std::vector;
|
using std::vector;
|
||||||
class GraphicElement;
|
class GraphicElement;
|
||||||
|
|
|
@ -43,11 +43,13 @@ std::vector<glm::vec2> generatePathBuffer(const QPainterPath& path)
|
||||||
break;
|
break;
|
||||||
case QPainterPath::LineToElement:
|
case QPainterPath::LineToElement:
|
||||||
qDebug() << "LineToElement";
|
qDebug() << "LineToElement";
|
||||||
|
{
|
||||||
glm::vec2 end = glm::vec2(element.x, element.y);
|
glm::vec2 end = glm::vec2(element.x, element.y);
|
||||||
glm::vec2 mid = (pathBuffer.back() + end) / 2.f;
|
glm::vec2 mid = (pathBuffer.back() + end) / 2.f;
|
||||||
pathBuffer.push_back(mid);
|
pathBuffer.push_back(mid);
|
||||||
pathBuffer.push_back(mid);
|
pathBuffer.push_back(mid);
|
||||||
pathBuffer.push_back(end);
|
pathBuffer.push_back(end);
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case QPainterPath::CurveToElement:
|
case QPainterPath::CurveToElement:
|
||||||
qDebug() << "CurveToElement";
|
qDebug() << "CurveToElement";
|
||||||
|
|
Loading…
Reference in New Issue