21 #ifndef __vtkMRMLStreamingVolumeNode_h 22 #define __vtkMRMLStreamingVolumeNode_h 33 #include "vtkStreamingVolumeCodec.h" 36 #include <vtkImageData.h> 37 #include <vtkObject.h> 38 #include <vtkStdString.h> 39 #include <vtkUnsignedCharArray.h> 50 void PrintSelf(ostream& os, vtkIndent indent)
override;
54 void ProcessMRMLEvents(vtkObject *caller,
unsigned long event,
void *callData)
override;
60 void WriteXML(ostream& of,
int indent)
override;
68 {
return "StreamingVolume";}
78 void SetAndObserveFrame(vtkStreamingVolumeFrame* frame);
81 vtkStreamingVolumeFrame*
GetFrame(){
return this->Frame.GetPointer();};
85 virtual bool EncodeImageData(
bool forceKeyFrame =
false);
89 virtual bool DecodeFrame();
93 virtual bool IsKeyFrame();
97 static void FrameModifiedCallback(vtkObject *caller,
unsigned long eid,
void* clientData,
void* callData);
100 FrameModifiedEvent = 18002
104 vtkSetMacro(Codec, vtkStreamingVolumeCodec*);
105 vtkStreamingVolumeCodec* GetCodec();
109 vtkGetMacro(CodecFourCC, std::string);
110 vtkSetMacro(CodecFourCC, std::string);
114 void SetCodecParameterString(std::string parameterString);
115 std::string GetCodecParameterString();
124 void AllocateImageForFrame(vtkImageData* imageData);
127 bool HasExternalImageObserver();
130 vtkSmartPointer<vtkStreamingVolumeCodec>
Codec;
132 vtkSmartPointer<vtkStreamingVolumeFrame>
Frame;
133 bool FrameDecoded{
false};
134 bool FrameDecodingInProgress{
false};
const char * GetNodeTagName() override
Get node XML tag name (like Volume, Model)
vtkSmartPointer< vtkCallbackCommand > FrameModifiedCallbackCommand
vtkMRMLNode * CreateNodeInstance() override
MRMLNode methods.
vtkMRMLCopyContentMacro(vtkMRMLTensorVolumeNode)
virtual vtkAlgorithmOutput * GetImageDataConnection()
Return the input image data pipeline.
void WriteXML(ostream &of, int indent) override
Write this node's information to a MRML file in XML format.
MRML node for representing a single compressed video frame that can be decoded to an image representa...
void ReadXMLAttributes(const char **atts) override
Set node attributes
void operator=(const vtkMRMLVectorVolumeNode &)
vtkSmartPointer< vtkStreamingVolumeCodec > Codec
static vtkMRMLVectorVolumeNode * New()
MRML node for representing a vector volume (image stack).
void ProcessMRMLEvents(vtkObject *, unsigned long, void *) override
alternative method to propagate events generated in Display nodes
vtkSmartPointer< vtkStreamingVolumeFrame > Frame
virtual void SetAndObserveImageData(vtkImageData *ImageData)
vtkStreamingVolumeFrame * GetFrame()
Returns a pointer to the current frame.
Abstract Superclass for all specific types of MRML nodes.
virtual vtkImageData * GetImageData()
void PrintSelf(ostream &os, vtkIndent indent) override