 |
ACloudViewer
3.9.4
A Modern Library for 3D Data Processing
|
Go to the documentation of this file.
28 virtual QString
getName()
const override;
42 QStringList getLabelContent(
int precision)
const;
48 QString getTitle(
int precision)
const;
57 int screenHeight)
override;
60 void setPosition(
float x,
float y);
63 inline const float*
getPosition()
const {
return m_screenPos; }
66 void clear(
bool ignoreDependencies =
false,
bool ignoreCaption =
true);
68 void clearLabel(
bool ignoreCaption =
true);
74 inline unsigned size()
const {
75 return static_cast<unsigned>(m_pickedPoints.size());
87 bool entityCenter =
false);
97 unsigned triangleIndex,
99 bool entityCenter =
false);
145 unsigned getUniqueID()
const;
150 QString itemTitle()
const;
152 QString prefix(
const char* pointTag)
const;
162 entityCenterPoint(false) {}
167 bool centerPoint =
false)
174 entityCenterPoint(centerPoint) {}
180 bool centerPoint =
false)
187 entityCenterPoint(centerPoint) {}
191 bool addPickedPoint(
const PickedPoint& pp);
195 return m_pickedPoints[index];
199 return m_pickedPoints[index];
206 m_relMarkerScale = scale;
212 int& nearestPointIndex,
213 double& nearestSquareDist)
const;
240 sfValueIsShifted(false) {}
244 void getLabelInfo1(LabelInfo1& info)
const;
251 static QString GetSFValueAsString(
const LabelInfo1& info,
int precision);
269 void getLabelInfo2(LabelInfo2& info)
const;
297 void getLabelInfo3(LabelInfo3& info)
const;
300 bool toFile_MeOnly(QFile& out,
short dataVersion)
const override;
301 short minimumFileVersion_MeOnly()
const override;
302 bool fromFile_MeOnly(QFile& in,
305 LoadedIDMap& oldToNewIDMap)
override;
307 virtual void onDeletionOf(
const ccHObject* obj)
override;
341 float m_screenPos[2];
344 int m_lastScreenPos[2];
unsigned point1Index
Definition: ecv2DLabel.h:273
PointCoordinateType area
Definition: ecv2DLabel.h:280
ccGenericPointCloud * cloud2
Definition: ecv2DLabel.h:276
normal_z rgb
Definition: my_point_types.h:168
void setDisplayedIn2D(bool state)
Whether to display the label in 2D.
Definition: ecv2DLabel.h:114
float markerScale
Last known marker scale.
Definition: ecv2DLabel.h:134
normal_z x
Definition: my_point_types.h:165
void displayPointLegend(bool state)
Whether to display the point(s) legend (title only)
Definition: ecv2DLabel.h:108
ccGenericPointCloud * cloud3
Definition: ecv2DLabel.h:278
double normal[3]
Definition: FileIOFactory.cpp:53
Three-points label info.
Definition: ecv2DLabel.h:272
bool isCollapsed() const
Returns whether the label is collapsed or not.
Definition: ecv2DLabel.h:105
ccGenericPointCloud * cloud
Definition: ecv2DLabel.h:219
CCVector2d uv
Barycentric coordinates (for triangles)
Definition: ecv2DLabel.h:136
QString m_surfaceIdfix
Definition: ecv2DLabel.h:356
void setRelativeMarkerScale(float scale)
Sets marker (relative) scale.
Definition: ecv2DLabel.h:205
virtual bool move2D(int x, int y, int dx, int dy, int screenWidth, int screenHeight)
Called on mouse move (for 2D interactors)
Definition: ecvInteractor.h:32
ScalarType sfValue
Definition: ecv2DLabel.h:225
ccGenericPointCloud * cloud2
Definition: ecv2DLabel.h:258
QString m_contourIdfix
Definition: ecv2DLabel.h:357
ccGenericMesh * mesh
Mesh.
Definition: ecv2DLabel.h:126
virtual bool acceptClick(int x, int y, Qt::MouseButton button)
Called on mouse click.
Definition: ecvInteractor.h:25
2D label (typically attached to points)
Definition: ecv2DLabel.h:22
MouseButton
Definition: Events.h:26
const PickedPoint & getPickedPoint(unsigned index) const
Returns a given point.
Definition: ecv2DLabel.h:194
QString m_sphereIdfix
Definition: ecv2DLabel.h:355
QString m_name
Object name.
Definition: ecvObject.h:219
QString m_lineID
Definition: ecv2DLabel.h:358
OpenGL camera parameters.
Definition: ecvGenericDisplayTools.h:554
Interactor interface (entity that can be dragged or clicked in a 3D view)
Definition: ecvInteractor.h:20
ccGenericPointCloud * cloud1
Definition: ecv2DLabel.h:256
bool entityCenterPoint
Entity center mode (index will be invalid)
Definition: ecv2DLabel.h:138
PickedPoint & getPickedPoint(unsigned index)
Returns a given point.
Definition: ecv2DLabel.h:198
int64_t CV_CLASS_ENUM
Type of object type flags (64 bits)
Definition: CVTypes.h:97
LabelInfo3()
Default constructor.
Definition: ecv2DLabel.h:284
virtual bool isSerializable() const override
Returns whether object is serializable of not.
Definition: ecv2DLabel.h:33
ImGuiContext * context
Definition: Window.cpp:76
QString getRawName() const
Returns 'raw' name (no replacement of default keywords)
Definition: ecv2DLabel.h:36
normal_z y
Definition: my_point_types.h:168
A 3D cloud interface with associated features (color, normals, octree, etc.)
Definition: ecvGenericPointCloud.h:45
CCVector3d pos2D
Last known '2D' position (i.e. in screen space)
Definition: ecv2DLabel.h:132
ecvColor::Rgb rgb
Definition: ecv2DLabel.h:223
QRect m_labelROI
label ROI
Definition: ecv2DLabel.h:333
One-point label info.
Definition: ecv2DLabel.h:217
bool isDisplayedIn2D() const
Returns whether the label is displayed in 2D.
Definition: ecv2DLabel.h:117
void setCollapsed(bool state)
Whether to collapse label or not.
Definition: ecv2DLabel.h:102
bool hasNormal
Definition: ecv2DLabel.h:220
unsigned point1Index
Definition: ecv2DLabel.h:255
unsigned point3Index
Definition: ecv2DLabel.h:277
PickedPoint(ccGenericMesh *_mesh, unsigned triIindex, const CCVector2d &_uv, bool centerPoint=false)
Constructor from a triangle, its index and barycentric coordinates.
Definition: ecv2DLabel.h:177
unsigned point2Index
Definition: ecv2DLabel.h:257
unsigned size() const
Returns current size.
Definition: ecv2DLabel.h:74
@ LABEL_2D
Definition: CVTypes.h:140
unsigned index
Point/triangle index.
Definition: ecv2DLabel.h:128
Generic mesh interface.
Definition: ecvGenericMesh.h:28
ccGenericPointCloud * cloud1
Definition: ecv2DLabel.h:274
LabelInfo2()
Default constructor.
Definition: ecv2DLabel.h:261
unsigned pointIndex
Definition: ecv2DLabel.h:218
Two-points label info.
Definition: ecv2DLabel.h:254
LabelInfo1()
Default constructor.
Definition: ecv2DLabel.h:230
QStringList m_historyMessage
Definition: ecv2DLabel.h:335
CCVector3 normal
Definition: ecv2DLabel.h:221
double sfShiftedValue
Definition: ecv2DLabel.h:226
bool hasSF
Definition: ecv2DLabel.h:224
Picked point descriptor.
Definition: ecv2DLabel.h:122
CCVector3d edges
Definition: ecv2DLabel.h:282
CCVector3 diff
Definition: ecv2DLabel.h:259
CCVector3d angles
Definition: ecv2DLabel.h:281
std::vector< PickedPoint > m_pickedPoints
Picked points.
Definition: ecv2DLabel.h:318
float m_relMarkerScale
Relative marker scale.
Definition: ecv2DLabel.h:353
math::float2 uv
Definition: PointCloudBuffers.cpp:51
RGB color structure.
Definition: ecvColorTypes.h:49
Hierarchical CLOUDVIEWER Object.
Definition: ecvHObject.h:25
bool m_dispPointsLegend
Whether to display the point(s) legend.
Definition: ecv2DLabel.h:347
virtual QString getName() const
Returns object name.
Definition: ecvObject.h:72
virtual CV_CLASS_ENUM getClassID() const override
Returns class ID.
Definition: ecv2DLabel.h:30
bool isPointLegendDisplayed() const
Returns whether the point(s) legend is displayed.
Definition: ecv2DLabel.h:111
PickedPoint()
Default constructor.
Definition: ecv2DLabel.h:155
#define CV_DB_LIB_API
Definition: CV_db.h:15
Display context.
Definition: ecvDrawContext.h:365
PickedPoint(ccGenericPointCloud *_cloud, unsigned pointIndex, bool centerPoint=false)
Constructor from a point and its index.
Definition: ecv2DLabel.h:165
float PointCoordinateType
Type of the coordinates of a (N-D) point.
Definition: CVTypes.h:16
ccGenericPointCloud * cloud
Cloud.
Definition: ecv2DLabel.h:124
unsigned point2Index
Definition: ecv2DLabel.h:275
bool m_showFullBody
Whether to show full label body or not.
Definition: ecv2DLabel.h:324
CCVector3 normal
Definition: ecv2DLabel.h:279
bool sfValueIsShifted
Definition: ecv2DLabel.h:227
bool hasRGB
Definition: ecv2DLabel.h:222
QString sfName
Definition: ecv2DLabel.h:228
bool m_dispIn2D
Whether to display the label in 2D.
Definition: ecv2DLabel.h:350
const float * getPosition() const
Returns relative position.
Definition: ecv2DLabel.h:63
std::string name
Definition: FileIOFactory.cpp:129