CustusX  22.04-rc3
An IGT application
cxOpenIGTLinkStreamer.cpp
Go to the documentation of this file.
1 /*=========================================================================
2 This file is part of CustusX, an Image Guided Therapy Application.
3 
4 Copyright (c) SINTEF Department of Medical Technology.
5 All rights reserved.
6 
7 CustusX is released under a BSD 3-Clause license.
8 
9 See Lisence.txt (https://github.com/SINTEFMedtek/CustusX/blob/master/License.txt) for details.
10 =========================================================================*/
11 #include "cxOpenIGTLinkStreamer.h"
12 
13 #include "cxLogger.h"
14 #include "cxSender.h"
15 
16 namespace cx
17 {
18 
20 {}
21 
23 {}
24 
25 
27 {
28  mSender = sender;
29 }
30 
32 {
33  mSender.reset();
34  emit stoppedStreaming();
35 }
36 
38 {
39  return true;
40 }
41 
43 {
44  return "OpenIGTLinkStreamer";
45 }
46 
48 {
49 }
50 
52 {
53 }
54 
56 {
57 }
58 
60 {
61  //CX_LOG_DEBUG() << "receivedImage";
62  PackagePtr package(new Package());
63  package->mImage = image;
64  if(mSender)
65  mSender->send(package);
66 }
67 
68 //void OpenIGTLinkStreamer::receivedProbedefinition(QString not_used, ProbeDefinitionPtr probedef)//Was not used?
69 //Added connect and changed name to see if this allows IGSTK tools to receive probeDefinition
71 {
72  //CX_LOG_DEBUG() << "receivedProbedefinition";
73  PackagePtr package(new Package());
74  package->mProbe = probedef;
75  if(mSender)
76  mSender->send(package);
77 }
78 
79 
81 {
82 
83 }
84 
85 } // namespace cx
86 
87 
boost::shared_ptr< class Image > ImagePtr
Definition: cxDicomWidget.h:27
boost::shared_ptr< struct Package > PackagePtr
boost::shared_ptr< Sender > SenderPtr
Definition: cxSender.h:64
boost::shared_ptr< class ProbeDefinition > ProbeDefinitionPtr
Namespace for all CustusX production code.