![]() |
ACloudViewer
3.9.4
A Modern Library for 3D Data Processing
|
#include <Annotaion.h>

Public Member Functions | |
| Annotaions (vtkRenderWindowInteractor *interactor=nullptr) | |
| void | preserve (size_t num=0) |
| void | release () |
| void | add (Annotation *anno) |
| void | remove (Annotation *anno) |
| void | clear () |
| std::size_t | getSize () |
| void | updateLabels (Annotation *anno, bool resetFlag=false) |
| void | loadAnnotations (std::string filename, int mode) |
| load annotations from file More... | |
| void | saveAnnotations (std::string filename, int mode) |
| save annotations to file More... | |
| bool | getAnnotations (std::vector< int > &annos) const |
| Annotation * | getAnnotation (vtkActor *actor) |
| from annotatin box actor to find annotation itself More... | |
| Annotation * | getAnnotation (std::size_t index) |
| void | getAnnotations (const std::string &type, std::vector< Annotation * > &annotations) |
| int | getAnnotationIndex (Annotation *anno) |
| std::vector< Annotation * > & | getAnnotations () |
| int | getLabelByIndex (std::size_t index) |
| void | updateBalloonByIndex (std::size_t index) |
| void | updateBalloonByAnno (Annotation *anno) |
Protected Attributes | |
| std::vector< Annotation * > | m_annotations |
| keep all annotation from current cloud More... | |
| vtkRenderWindowInteractor * | m_interactor |
| vtkSmartPointer< vtkBalloonWidget > | m_balloonWidget |
| int * | m_labeledCloudIndex = nullptr |
| size_t | m_capacity = 0 |
Definition at line 227 of file Annotaion.h.
|
explicit |
Definition at line 406 of file Annotaion.cpp.
References m_balloonWidget.
| void Annotaions::add | ( | Annotation * | anno | ) |
Definition at line 445 of file Annotaion.cpp.
References Annotation::getActor(), Annotation::getType(), m_annotations, m_balloonWidget, and updateLabels().
Referenced by loadAnnotations().
| void Annotaions::clear | ( | ) |
Definition at line 469 of file Annotaion.cpp.
References m_annotations, m_balloonWidget, and preserve().
| Annotation * Annotaions::getAnnotation | ( | std::size_t | index | ) |
Definition at line 691 of file Annotaion.cpp.
References getSize(), and m_annotations.
| Annotation * Annotaions::getAnnotation | ( | vtkActor * | actor | ) |
from annotatin box actor to find annotation itself
| actor |
Definition at line 669 of file Annotaion.cpp.
References m_annotations.
Referenced by updateBalloonByIndex().
| int Annotaions::getAnnotationIndex | ( | Annotation * | anno | ) |
Definition at line 678 of file Annotaion.cpp.
References Annotation::getActor(), and m_annotations.
Referenced by updateBalloonByAnno().
| std::vector< Annotation * > & Annotaions::getAnnotations | ( | ) |
Definition at line 667 of file Annotaion.cpp.
References m_annotations.
| void Annotaions::getAnnotations | ( | const std::string & | type, |
| std::vector< Annotation * > & | annotations | ||
| ) |
Definition at line 696 of file Annotaion.cpp.
References m_annotations, and type.
| bool Annotaions::getAnnotations | ( | std::vector< int > & | annos | ) | const |
Definition at line 658 of file Annotaion.cpp.
References m_capacity, and m_labeledCloudIndex.
|
inline |
Definition at line 267 of file Annotaion.h.
References m_capacity, and m_labeledCloudIndex.
| std::size_t Annotaions::getSize | ( | ) |
Definition at line 480 of file Annotaion.cpp.
References m_annotations.
Referenced by getAnnotation(), and updateBalloonByIndex().
| void Annotaions::loadAnnotations | ( | std::string | filename, |
| int | mode | ||
| ) |
load annotations from file
| filename |
Definition at line 518 of file Annotaion.cpp.
References add(), filename, Annotation::GetTypeByIndex(), m_annotations, m_capacity, CVLog::Print(), CVTools::QMappingReader(), CVTools::TimeOff(), CVTools::TimeStart(), type, and CVLog::Warning().
| void Annotaions::preserve | ( | size_t | num = 0 | ) |
Definition at line 420 of file Annotaion.cpp.
References m_capacity, and m_labeledCloudIndex.
Referenced by clear().
| void Annotaions::release | ( | ) |
Definition at line 428 of file Annotaion.cpp.
References Annotation::GetTypes(), m_balloonWidget, m_capacity, m_labeledCloudIndex, and Annotation::types.
| void Annotaions::remove | ( | Annotation * | anno | ) |
Definition at line 458 of file Annotaion.cpp.
References Annotation::getActor(), m_annotations, m_balloonWidget, and updateLabels().
| void Annotaions::saveAnnotations | ( | std::string | filename, |
| int | mode | ||
| ) |
save annotations to file
| filename |
Definition at line 577 of file Annotaion.cpp.
References filename, m_annotations, m_capacity, m_labeledCloudIndex, CVLog::Print(), CVTools::QMappingWriter(), CVTools::TimeOff(), CVTools::TimeStart(), patch::to_string(), and CVLog::Warning().
| void Annotaions::updateBalloonByAnno | ( | Annotation * | anno | ) |
Definition at line 717 of file Annotaion.cpp.
References Annotation::getActor(), getAnnotationIndex(), m_balloonWidget, and updateBalloonByIndex().
| void Annotaions::updateBalloonByIndex | ( | std::size_t | index | ) |
Definition at line 705 of file Annotaion.cpp.
References getAnnotation(), getSize(), and m_balloonWidget.
Referenced by updateBalloonByAnno().
| void Annotaions::updateLabels | ( | Annotation * | anno, |
| bool | resetFlag = false |
||
| ) |
Definition at line 482 of file Annotaion.cpp.
References Annotation::getSlice(), Annotation::getType(), Annotation::GetTypeIndex(), and m_labeledCloudIndex.
|
protected |
keep all annotation from current cloud
Definition at line 281 of file Annotaion.h.
Referenced by add(), clear(), getAnnotation(), getAnnotationIndex(), getAnnotations(), getSize(), loadAnnotations(), remove(), and saveAnnotations().
|
protected |
Definition at line 284 of file Annotaion.h.
Referenced by add(), Annotaions(), clear(), release(), remove(), updateBalloonByAnno(), and updateBalloonByIndex().
|
protected |
Definition at line 287 of file Annotaion.h.
Referenced by getAnnotations(), getLabelByIndex(), loadAnnotations(), preserve(), release(), and saveAnnotations().
|
protected |
Definition at line 283 of file Annotaion.h.
|
protected |
Definition at line 286 of file Annotaion.h.
Referenced by getAnnotations(), getLabelByIndex(), preserve(), release(), saveAnnotations(), and updateLabels().