Wed, 09 Mar 2022 13:01:50 +0200
Fix performance issues in Model::find
3 | 1 | #pragma once |
14 | 2 | #include "object.h" |
3 | 3 | |
21 | 4 | class Model; |
5 | ||
35
98906a94732f
renamed the linetypes namespace to ldraw namespace and added more structures to it
Teemu Piippo <teemu@hecknology.net>
parents:
33
diff
changeset
|
6 | namespace ldraw |
3 | 7 | { |
8 | class SubfileReference; | |
9 | } | |
10 | ||
35
98906a94732f
renamed the linetypes namespace to ldraw namespace and added more structures to it
Teemu Piippo <teemu@hecknology.net>
parents:
33
diff
changeset
|
11 | class ldraw::SubfileReference : public ColoredObject |
3 | 12 | { |
13 | public: | |
14 | SubfileReference() = default; | |
8
44679e468ba9
major update with many things
Teemu Piippo <teemu@hecknology.net>
parents:
6
diff
changeset
|
15 | SubfileReference( |
33
4c41bfe2ec6e
replaced matrix and vertex classes with glm
Teemu Piippo <teemu@hecknology.net>
parents:
26
diff
changeset
|
16 | const glm::mat4& transformation, |
8
44679e468ba9
major update with many things
Teemu Piippo <teemu@hecknology.net>
parents:
6
diff
changeset
|
17 | const QString &referenceName, |
139
72098474d362
Document and refactor colors.cpp and colors.h
Teemu Piippo <teemu@hecknology.net>
parents:
132
diff
changeset
|
18 | const Color color = ldraw::MAIN_COLOR); |
3 | 19 | QVariant getProperty(Property property) const override; |
6 | 20 | QString textRepresentation() const override; |
21 | 21 | void getPolygons(std::vector<gl::Polygon>& polygons, GetPolygonsContext* context) const override; |
33
4c41bfe2ec6e
replaced matrix and vertex classes with glm
Teemu Piippo <teemu@hecknology.net>
parents:
26
diff
changeset
|
22 | glm::vec3 position() const; |
26 | 23 | void invert() override; |
148 | 24 | Model* resolve(const ModelId callingModelId, DocumentManager* documents) const; |
132
488d0ba6070b
Begin work with serialization
Teemu Piippo <teemu@hecknology.net>
parents:
86
diff
changeset
|
25 | Type typeIdentifier() const override; |
488d0ba6070b
Begin work with serialization
Teemu Piippo <teemu@hecknology.net>
parents:
86
diff
changeset
|
26 | QDataStream& serialize(QDataStream& stream) const override; |
488d0ba6070b
Begin work with serialization
Teemu Piippo <teemu@hecknology.net>
parents:
86
diff
changeset
|
27 | QDataStream& deserialize(QDataStream& stream) override; |
141 | 28 | QString toLDrawCode() const override; |
158
5bd755eaa5a8
Add icons from ionicons
Teemu Piippo <teemu@hecknology.net>
parents:
148
diff
changeset
|
29 | QString iconName() const override; |
33
4c41bfe2ec6e
replaced matrix and vertex classes with glm
Teemu Piippo <teemu@hecknology.net>
parents:
26
diff
changeset
|
30 | glm::mat4 transformation; |
3 | 31 | QString referenceName; |
26 | 32 | bool isInverted = false; |
86
4bec0525ef1b
PolygonObjectEditor can now modify the object properly
Teemu Piippo <teemu@hecknology.net>
parents:
77
diff
changeset
|
33 | protected: |
4bec0525ef1b
PolygonObjectEditor can now modify the object properly
Teemu Piippo <teemu@hecknology.net>
parents:
77
diff
changeset
|
34 | void setProperty(SetPropertyResult* result, const PropertyKeyValue& pair) override; |
3 | 35 | }; |