Add VolRulerAnnotationActor.
This commit is contained in:
@@ -76,3 +76,7 @@ void RulerAnnotationActor::selfCalibCb(vtkObject *, unsigned long, void *data) {
|
||||
w->exec();
|
||||
delete w;
|
||||
}
|
||||
|
||||
vtkProp *RulerAnnotationActor::GetProp() {
|
||||
return this;
|
||||
}
|
||||
|
||||
@@ -20,6 +20,8 @@ vtkTypeMacro(RulerAnnotationActor, LineAnnotationActor);
|
||||
|
||||
NextMeasureMacro(RulerAnnotationActor);
|
||||
|
||||
vtkProp* GetProp() ;
|
||||
|
||||
void setCalibration(double s) {
|
||||
isCalibration = true;
|
||||
calibDistance = s;
|
||||
|
||||
23
src/src/Rendering/Measure/VolRulerAnnotationActor.cpp
Normal file
23
src/src/Rendering/Measure/VolRulerAnnotationActor.cpp
Normal file
@@ -0,0 +1,23 @@
|
||||
//
|
||||
// Created by Krad on 2022/11/23.
|
||||
//
|
||||
|
||||
#include "VolRulerAnnotationActor.h"
|
||||
|
||||
#include <vtkObjectFactory.h>
|
||||
#include <vtkPoints.h>
|
||||
|
||||
#include "Rendering/Core/ControlPointActor.h"
|
||||
|
||||
vtkStandardNewMacro(VolRulerAnnotationActor)
|
||||
|
||||
VolRulerAnnotationActor::VolRulerAnnotationActor() {
|
||||
MapMode = MapToWorld;
|
||||
controlP1->SetMapMode(MapToWorld);
|
||||
controlP2->SetMapMode(MapToWorld);
|
||||
}
|
||||
|
||||
VolRulerAnnotationActor::~VolRulerAnnotationActor() {
|
||||
|
||||
}
|
||||
|
||||
34
src/src/Rendering/Measure/VolRulerAnnotationActor.h
Normal file
34
src/src/Rendering/Measure/VolRulerAnnotationActor.h
Normal file
@@ -0,0 +1,34 @@
|
||||
//
|
||||
// Created by Krad on 2022/11/23.
|
||||
//
|
||||
|
||||
#ifndef OMEGAV_VOLRULERANNOTATIONACTOR_H
|
||||
#define OMEGAV_VOLRULERANNOTATIONACTOR_H
|
||||
|
||||
#include "RulerAnnotationActor.h"
|
||||
|
||||
class VolRulerAnnotationActor:public RulerAnnotationActor {
|
||||
public:
|
||||
//@{
|
||||
/**
|
||||
* Standard methods for instances of this class.
|
||||
*/
|
||||
static VolRulerAnnotationActor *New();
|
||||
|
||||
vtkTypeMacro(VolRulerAnnotationActor, RulerAnnotationActor);
|
||||
|
||||
|
||||
protected:
|
||||
VolRulerAnnotationActor();
|
||||
|
||||
~VolRulerAnnotationActor() override;
|
||||
|
||||
public:
|
||||
|
||||
private:
|
||||
VolRulerAnnotationActor(const VolRulerAnnotationActor&) = delete;
|
||||
void operator=(const VolRulerAnnotationActor&) = delete;
|
||||
};
|
||||
|
||||
|
||||
#endif //OMEGAV_VOLRULERANNOTATIONACTOR_H
|
||||
Reference in New Issue
Block a user