Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
mitkSpectroCamController.cpp
Go to the documentation of this file.
1 /*===================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center,
6 Division of Medical and Biological Informatics.
7 All rights reserved.
8 
9 This software is distributed WITHOUT ANY WARRANTY; without
10 even the implied warranty of MERCHANTABILITY or FITNESS FOR
11 A PARTICULAR PURPOSE.
12 
13 See LICENSE.txt or http://www.mitk.org for details.
14 
15 ===================================================================*/
17 #include "mitkLogMacros.h"
19 #include <mitkImageCast.h>
20 
21 
22 #include <fstream>
23 #include <string>
24 #include <iostream>
25 #include <functional>
26 
27 //OpenCv includes
28 #include <opencv\cv.h>
29 #include <opencv\cxcore.h>
30 #include <opencv\highgui.h>
31 #include <opencv2/contrib/contrib.hpp>
32 
33 // itk includes
34 #include <itkImage.h>
35 #include <itkComposeImageFilter.h>
36 
37 //Spectrocam includes
38 #include <ISpectroCam.h>
39 #include <Jai_Factory.h>
40 
41 
42 
43 using namespace std;
44 using namespace cv;
45 
46 
47 namespace mitk {
48 
49 
50  typedef itk::VectorImage<unsigned short, 2> CompositeCameraImageType;
51 
59  class SpectroCamController_pimpl
60  {
61  public:
62  SpectroCamController_pimpl();
63  ~SpectroCamController_pimpl();
64 
65  bool Ini();
66  int OpenCameraConnection();
67  int CloseCameraConnection();
68  bool isCameraRunning();
69 
70 
71  void SetCurrentImageAsWhiteBalance();
72 
73  mitk::Image::Pointer GetCurrentImage();
74 
75  CompositeCameraImageType::Pointer m_CompositeItkImage_1;
76  CompositeCameraImageType::Pointer m_CompositeItkImage_2;
77  mitk::Image::Pointer m_CompositeMitkImage;
78 
79  cv::Mat m_CurrentStackSmall;
80  cv::Mat m_CurrentTransformedStack;
81  cv::Mat m_FlatfieldSmall;
82  cv::Mat m_LLSQSolutionSmall;
83 
84  const int m_FullWidth;
85  const int m_FullHeight;
86 
87  const int m_SmallWidth;
88  const int m_SmallHeight;
89 
90  bool m_ShowOxygenation;
91 
92  // for image double buffer swap
93  bool m_Image1Selected;
94 
95  std::string mode;
96  std::string model;
97 
98  private:
99 
100  void InitializeItkImage(mitk::CompositeCameraImageType::Pointer& compositeImage);
101 
102  bool m_IsCameraRunning;
103 
104  unsigned m_NumRecordedImages;
105 
106  ISpectroCam* spectroCam; //SpectroCam var
107 
108  STREAM_HANDLE m_hDS; // Handle to the data stream
109 
110  uint32_t m_iValidBuffers; // Number of buffers allocated to image acquisition
111  BUF_HANDLE m_pAquBufferID; // Handles for all the image buffers
112  HANDLE m_hEventKill; // Event used for speeding up the termination of image capture
113 
114 
115  //Vars for Ini from file
116  FastModeSettings fastSettings;
117  SequenceModeSettings seqSettings;
118  IndexModeSettings indexSettings;
119 
120  void SaveCameraStreamToDisk();
121  };
122 
123 }
124 
125 
126 // Implementation
127 
128 static mitk::SpectroCamController_pimpl* my_SpectroCamController;
129 
130 mitk::Image::Pointer mitk::SpectroCamController_pimpl::GetCurrentImage()
131 {
133 
134  // TODO SW: semaphore here so it cannot interfere with callback readout of m_Image1Selected
135  if (this->m_Image1Selected)
136  {
137  this->m_Image1Selected = !this->m_Image1Selected;
138  selectedImage = this->m_CompositeItkImage_1;
139  }
140  else
141  {
142  this->m_Image1Selected = !this->m_Image1Selected;
143  selectedImage = this->m_CompositeItkImage_2;
144  }
145 
146  this->m_CompositeMitkImage = mitk::Image::New();
147  MITK_INFO << "Image created";
148  this->m_CompositeMitkImage->InitializeByItk<mitk::CompositeCameraImageType>(selectedImage);
149  MITK_INFO << "Initialized image by ITK";
150  this->m_CompositeMitkImage->SetVolume(selectedImage->GetBufferPointer());
151  MITK_INFO << "Copied data";
152 
153 
154  return m_CompositeMitkImage;
155 }
156 
158 {
159  //Create the H-Matrix
160  // Ox DOx //Lookup values at http://omlc.org/spectra/hemoglobin/summary.html
161  float H[8][4]= {{50104 , 37020. , 405, 1.}, //Filter0 = 580nm +- 10
162  {33209.2 , 16156.4 , 785., 1.}, //Filter1 = 470nm +- 10
163  {319.6 , 3226.56 , 280., 1.}, //Filter2 = 660nm +- 10
164  {32613.2 , 53788 , 495., 1.}, //Filter3 = 560nm +- 10
165  {26629.2 , 14550 , 760., 1.}, //Filter4 = 480nm +- 12,5
166  {20035.2 , 25773.6 , 665., 1.}, //Filter5 = 511nm +- 10 ->took 510nm
167  {3200 , 14677.2 , 380., 1.}, //Filter6 = 600nm +- 10
168  {290 , 1794.28 , 220., 1.}}; //Filter7 = 700nm
169 
170  //Create the hMatrix
171  cv::Mat hMatrix = cv::Mat(8, 4, CV_32F, &H ); //cv::Mat(rows, cols, type, fill with)
172 
173  cv::Mat transH;
174  transpose(hMatrix,transH);
175  cv::Mat mulImage = transH * hMatrix;
176  cv::Mat invImage = mulImage.inv();
177  cv::Mat HCompononentsForLLSQ = invImage * transH;
178 
179  return HCompononentsForLLSQ;
180 }
181 
182 mitk::SpectroCamController_pimpl::SpectroCamController_pimpl()
183  :m_hDS(NULL),
184  m_NumRecordedImages(1),
185  m_IsCameraRunning(false),
186  m_SmallWidth(614),
187  m_SmallHeight(514),
188  m_FullWidth(2456),
189  m_FullHeight(2058),
190  m_Image1Selected(true),
191  m_ShowOxygenation(false)
192 {
194  m_CurrentStackSmall = cv::Mat(8, m_SmallWidth * m_SmallHeight, CV_32F, cv::Scalar(0));
195  m_FlatfieldSmall = cv::Mat(8, m_SmallWidth * m_SmallHeight, CV_32F, cv::Scalar(1));
196  m_CurrentTransformedStack = cv::Mat(8, m_SmallWidth * m_SmallHeight, CV_32F, cv::Scalar(1));
197 
198 
199  m_LLSQSolutionSmall = createLLSQSolutionFromHMatrix();
200 
201 
202 }
203 
204 void mitk::SpectroCamController_pimpl::SetCurrentImageAsWhiteBalance()
205 {
206  // deep copy of current image stack
207  m_FlatfieldSmall = m_CurrentStackSmall.clone();
208 
209  cv::namedWindow("Oxygenation Estimate", WINDOW_AUTOSIZE);
210  m_ShowOxygenation = true;
211 }
212 
213 
214 
215 mitk::SpectroCamController_pimpl::~SpectroCamController_pimpl()
216 {
217 }
218 
219 
220 
221 
222 
223 void mitk::SpectroCamController_pimpl::SaveCameraStreamToDisk()
224 {
225  /*
226  //=================================Save Images to HDD=================================
227  imagesRecoreded=0;
228 
229  //If Rec is pressed -> Save Images to Harddrive
230  if (rec == true) //On pressing the Rec-Button we wan to save x Stacks with 8 images each
231  {
232  //Save Image
233  saveImage(in); //std::cout<< "save no."<< imagesRecoreded<< std::endl;
234  //Icrement counter
235  imagesRecoreded++;
236 
237  if (imagesRecoreded >= (NumberOfStacksToBeRecorded*8) ) //If number of images is bigger or equal to the the Image Stack we want to tecord, untoggle the rec button and reset the counter!
238  {
239  imagesRecoreded=0;
240  rec=false;
241  ReCButtonControl_Pointer->EnableWindow(TRUE);
242  }
243  }
244  */
245 }
246 
247 
248 
249 //Initialize Camera Controller
250 bool mitk::SpectroCamController_pimpl::Ini()
251 {
252  //===============Get Ini from File===============
253  //Get model from file std::string CChildWindowSampleDlg::getModelNameFromIni()
254  std::ifstream fin("C:\\ModeSettings.txt"); //Set File to read
255  std::ofstream fout("C:\\ModeSettingsCheck.txt"); //Set output
256  const int bufferSize = 1000;
257  char buffer[bufferSize];
258 
259  if (fin.fail())
260  {
261  MITK_INFO << "Failed opening file ModeSettings.txt!" << endl ;
262  }
263 
264  fin.getline(buffer, bufferSize);
265  fin.getline(buffer, bufferSize);
266  model = buffer;
267 
268 
269  //Get mode from file
270  //Skipping model, getting mode
271  for (int i = 0; i < 3; ++i)
272  {
273  fin.getline(buffer, bufferSize);
274  fout << buffer << endl;
275  }
276 
277  mode = buffer;
278 
279  // [FastModeExposure]
280  for (int i = 0; i < 2; ++i)
281  {
282  fin.getline(buffer, bufferSize);
283  fout << buffer << endl;
284  }
285 
286  fin >> fastSettings.exposure;
287  fout << fastSettings.exposure << endl;;
288 
289  // [FastModeGain]
290  for (int i = 0; i < 3; ++i)
291  {
292  fin.getline(buffer, bufferSize);
293  fout << buffer << endl;
294  }
295 
296  fin >> fastSettings.gain;
297  fout << fastSettings.gain << endl;
298 
299  // [SequenceModeExposures]
300  for (int i = 0; i < 3; ++i)
301  {
302  fin.getline(buffer, bufferSize);
303  fout << buffer << endl;
304  }
305 
306  for (int i = 0; i < NUMBER_FILTERS; ++i)
307  {
308  fin >> seqSettings.exposures[i];
309  fout << seqSettings.exposures[i] << endl;
310  }
311 
312  // [SequenceModeGains]
313  for (int i = 0; i < 3; ++i)
314  {
315  fin.getline(buffer, bufferSize);
316  fout << buffer << endl;
317  }
318 
319  for (int i = 0; i < NUMBER_FILTERS; ++i)
320  {
321  fin >> seqSettings.gains[i];
322  fout << seqSettings.gains[i] << endl;
323  }
324 
325  // [IndexModeExposures]
326  for (int i = 0; i < 3; ++i)
327  {
328  fin.getline(buffer, bufferSize);
329  fout << buffer << endl;
330  }
331 
332  for (int i = 0; i < NUMBER_FILTERS; ++i)
333  {
334  fin >> indexSettings.exposures[i];
335  fout << indexSettings.exposures[i] << endl;
336  }
337 
338  // [IndexModeGains]
339  for (int i = 0; i < 3; ++i)
340  {
341  fin.getline(buffer, bufferSize);
342  fout << buffer << endl;
343  }
344  for (int i = 0; i < NUMBER_FILTERS; ++i)
345  {
346  fin >> indexSettings.gains[i];
347  fout << indexSettings.gains[i] << endl;
348  }
349 
350  // [IndexModeNumberFilterIterations]
351  for (int i = 0; i < 3; ++i)
352  {
353  fin.getline(buffer, bufferSize);
354  fout << buffer << endl;
355  }
356 
357  for (int i = 0; i < NUMBER_FILTERS; ++i)
358  {
359  fin >> indexSettings.numFilterIterations[i];
360  fout << indexSettings.numFilterIterations[i] << endl;
361  }
362 
363  //After reading files -> close stream
364  fin.close();
365  fout.close();
366 
367  return 0;
368 
369 }
370 
371 void mitk::SpectroCamController_pimpl::InitializeItkImage(mitk::CompositeCameraImageType::Pointer& compositeImage)
372 {
373  if (compositeImage.IsNull())
374  {
375 
376  MITK_INFO << "initializing itk::Composite Image";
377  mitk::CompositeCameraImageType::RegionType region;
378  mitk::CompositeCameraImageType::RegionType::SizeType size;
379  mitk::CompositeCameraImageType::RegionType::IndexType index;
380  mitk::CompositeCameraImageType::SpacingType spacing;
381  size.Fill( 1 );
382  size[0] = this->m_FullWidth;
383  size[1] = this->m_FullHeight;
384  index.Fill(0);
385  spacing.Fill(1);
386  region.SetSize(size);
387  region.SetIndex(index);
388 
389  compositeImage = mitk::CompositeCameraImageType::New();
390  compositeImage->SetRegions(region);
391  compositeImage->SetSpacing(spacing);
392  compositeImage->SetNumberOfComponentsPerPixel(NUMBER_FILTERS);
393  compositeImage->Allocate();
394  }
395 }
396 
401 static void DisplayCameraStream(SpectroCamImage image)
402 {
403 
404  MITK_INFO << "image callback call";
405  try
406  {
407  if (image.m_FilterNum < 0 || image.m_FilterNum >= NUMBER_FILTERS)
408  {
409  std::cout << "Filter number out of range.\n"<< std::endl;
410  }
411  else
412  {
413  // Allocate the buffer to hold converted the image. (We only want to do this once for performance reasons)
414  if (image.m_pAcqImage->pImageBuffer == NULL)
415  {
416  if (J_Image_Malloc(image.m_pAcqImage, image.m_pAcqImage) != J_ST_SUCCESS)
417  {
418  return;
419  }
420  }
421 
422 
423  //============= Get data from spectrocam to opencv
424 
425  // TODO SW: probably we can get around this memcopy by simply setting data pointer? Not sure.
426  cv::Mat data = cv::Mat( image.m_pAcqImage->iSizeY, image.m_pAcqImage->iSizeX, CV_16U);
427  memcpy( data.datastart , image.m_pAcqImage->pImageBuffer , image.m_pAcqImage->iImageSize); //Copy Image from JAI-Format to OCV´s IplImage
428 
429 
430  //============= From opencv to mitk::Image (VectorImage)
431 
433 
434  if (my_SpectroCamController->m_Image1Selected)
435  {
436  selectedImage = my_SpectroCamController->m_CompositeItkImage_1;
437  }
438  else
439  {
440  selectedImage = my_SpectroCamController->m_CompositeItkImage_2;
441  }
442 
443  itk::ImageRegionIterator<mitk::CompositeCameraImageType> imageIterator(selectedImage, selectedImage->GetLargestPossibleRegion());
444 
445  MatConstIterator_<unsigned short> it, end;
446  it = data.begin<unsigned short>();
447  end = data.end<unsigned short>();
448 
449 
450  while(!imageIterator.IsAtEnd())
451  {
452  mitk::CompositeCameraImageType::PixelType compositePixel = imageIterator.Get();
453 
454  compositePixel[image.m_FilterNum] = *it;
455 
456  ++it;
457  ++imageIterator;
458  }
459 
460  //both matrix and itk image shall reach end at the same time.
461  assert(it == end);
462 
463 
464  //============= Display image as opencv window ==
465 
466  cv::Mat display;
467  cv::resize(data, display, cvSize(my_SpectroCamController->m_SmallWidth, my_SpectroCamController->m_SmallHeight) ); //do some resizeing for faster display
468 
469  display *= 16; // image is only 12 bit large, but datatype is 16 bit. Expand to full range for displaying by multiplying by 2^4.
470 
471 
472 
473  //Display Image
474  cv::imshow("Display window", display); //Display image
475  //MITK_INFO << "pixel 100,100" << display.at<unsigned short>(0,100);
476 
477 
478  //============= TODO: live oxygenation estimation
479 
480  if (my_SpectroCamController->m_ShowOxygenation)
481  {
482  cv::Range slice[2];
483  slice[0] = cv::Range( image.m_FilterNum, image.m_FilterNum+1 );
484  slice[1] = cv::Range::all();
485 
486  cv::Mat currentSlice = my_SpectroCamController->m_CurrentStackSmall(slice);
487 
488  cv::Mat currentImageF32;
489  display.convertTo(currentImageF32, CV_32F);
490 
491  currentImageF32 = currentImageF32.reshape(0, 1);
492  currentImageF32.copyTo(currentSlice);
493 
494  cv::Mat currentWorkingSlice = currentSlice.clone();
495 
496  cv::Mat currentFlatfieldSlice = my_SpectroCamController->m_FlatfieldSmall(slice);
497  MITK_INFO << "flat current: " << currentFlatfieldSlice.at<float>(0,100);
498 
499 
500  MITK_INFO << "raw measured pixel value: " << currentWorkingSlice.at<float>(0,100);
501 
502  cv::divide(currentWorkingSlice, currentFlatfieldSlice, currentWorkingSlice);
503  MITK_INFO << "corrected by flatfield pixel: " << currentWorkingSlice.at<float>(0,100);
504 
505  cv::log(currentWorkingSlice, currentWorkingSlice);
506  currentWorkingSlice = -0.43429 * currentWorkingSlice;
507  MITK_INFO << "to absorption: " << currentWorkingSlice.at<float>(0,100);
508 
509  currentWorkingSlice.copyTo(my_SpectroCamController->m_CurrentTransformedStack(slice) );
510 
511  //MITK_INFO << "slice 0: " << my_SpectroCamController->m_CurrentTransformedStack.at<float>(0,100);;
512 
513  cv::Mat currentEstimate = my_SpectroCamController->m_LLSQSolutionSmall * my_SpectroCamController->m_CurrentTransformedStack;
514  cv::Range oxyHemo[2];
515  oxyHemo[0] = cv::Range(0,1);
516  oxyHemo[1] = cv::Range::all();
517 
518  cv::Range deOxyHemo[2];
519  deOxyHemo[0] = cv::Range(1,2);
520  deOxyHemo[1] = cv::Range::all();
521 
522  cv::Mat saO2 = currentEstimate(oxyHemo) / (currentEstimate(oxyHemo) + currentEstimate(deOxyHemo));
523 
524  cv::Mat saO2Image = saO2.reshape(0, my_SpectroCamController->m_SmallHeight);
525  MITK_INFO << "saO2, 200 200: " << saO2Image.at<float>(200,200);
526 
527  cv::threshold(saO2Image, saO2Image, 1., 1., cv::THRESH_TRUNC);
528  cv::threshold(saO2Image, saO2Image, 0., 0., cv::THRESH_TOZERO);
529 
530  saO2Image = saO2Image * 637.;// 255.;
531 
532  cv::Mat SaO2IntImage;
533  saO2Image.convertTo(SaO2IntImage, CV_8U);
534  // MITK_INFO << saO2Image.at<float>(0,100);
535 
536  cv::Mat colorImage;
537  cv::applyColorMap(SaO2IntImage, colorImage, COLORMAP_JET);
538  cv::imshow("Oxygenation Estimate", colorImage); //Display image
539  }
540 
541 
542  cv::waitKey(1);
543  }
544 
545  }//try
546 
547  catch (std::exception &e) {
548  MITK_INFO << e.what();
549  }
550 }
551 
552 
553 
554 int mitk::SpectroCamController_pimpl::OpenCameraConnection()
555 {
556  //=====================OpenFactoryAndCamera=====================
557  //Create Factory and cam based on //BOOL OpenFactoryAndCamera(); // Open factory and search for cameras. Open first camera
558  spectroCam = CreateSpectroCam(&DisplayCameraStream, nullptr, 0);
559  MITK_INFO << "Camera " << model << " is running in: " << mode << "-mode" << endl;
560 
561 
562 
563  //=====================Open Streams=====================
564  J_STATUS_TYPE status = spectroCam->initialize(model.c_str(), (std::string("C:\\") + model + "\\").c_str());
565 
566  if (status != J_ST_SUCCESS)
567  {
568  MITK_INFO << "Could not initialize camera!" << endl;
569  }
570 
571  // initialize VectorImage
572  this->InitializeItkImage(this->m_CompositeItkImage_1);
573  this->InitializeItkImage(this->m_CompositeItkImage_2);
574 
575 
576 
577  //=====================Open Streams=====================
578  if (mode == "Fast")
579  {
580  status = status | spectroCam->start(fastSettings);
581  }
582 
583  else if (mode == "Sequence")
584  {
585  status = status | spectroCam->start(seqSettings);
586  }
587 
588  else if (mode == "IndexFast")
589  {
590  indexSettings.filterModeSpeed = IndexModeSettings::INDEX_FAST;
591  status = status | spectroCam->start(indexSettings);
592  }
593 
594  else if (mode == "IndexSlow")
595  {
596  indexSettings.filterModeSpeed = IndexModeSettings::INDEX_SLOW;
597  status = status | spectroCam->start(indexSettings);
598  }
599 
600  else if (mode == "IndexTriggered")
601  {
602  indexSettings.filterModeSpeed = IndexModeSettings::INDEX_TRIGGERED;
603  status = status | spectroCam->start(indexSettings);
604  }
605 
606  else
607  {
608  status = status | spectroCam->start(fastSettings);
609  }
610 
611  MITK_INFO << "status flag: " << status;
612 
613  if (status == J_ST_SUCCESS)
614  {
615  m_IsCameraRunning = true;
616  }
617 
618 
619  cv::namedWindow( "Display window", WINDOW_AUTOSIZE );// Create a window for display.
620 
621  return status;
622 }
623 
624 bool mitk::SpectroCamController_pimpl::isCameraRunning()
625 {
626  return m_IsCameraRunning;
627 }
628 
629 
630 
631 //Method to close down connections
632 int mitk::SpectroCamController_pimpl::CloseCameraConnection()
633 {
634 
635  // On click -> Stop acquisition
636  J_STATUS_TYPE retval = 0;
637  CAM_HANDLE hCam = spectroCam->GetCameraHandle();
638 
639  // Stop Acquision
640  if (hCam)
641  {
642  retval = retval | J_Camera_ExecuteCommand(hCam, (int8_t*) NODE_NAME_ACQSTOP);
643  }
644 
645 
646  MITK_INFO << "execute acqstop command";
647 
648 
649  // Close stream (this frees all allocated buffers)
650  // Stop the image acquisition engine
651  J_DataStream_StopAcquisition(m_hDS, ACQ_STOP_FLAG_KILL);
652 
653 
654  MITK_INFO << "execute stop aqui";
655 
656  // UnPrepare Buffers (this removed the buffers from the acquisition engine and frees buffers)
657  {
658  void *pPrivate;
659  void *pBuffer;
660 
661  // Flush Queues
662  J_DataStream_FlushQueue(m_hDS, ACQ_QUEUE_INPUT_TO_OUTPUT);
663  J_DataStream_FlushQueue(m_hDS, ACQ_QUEUE_OUTPUT_DISCARD);
664 
665  // Remove the frame buffer from the Acquisition engine.
666  J_DataStream_RevokeBuffer(m_hDS, m_pAquBufferID, &pBuffer , &pPrivate);
667 
668  m_pAquBufferID = 0;
669 
670  m_iValidBuffers = 0;
671  }
672 
673  MITK_INFO << "unprepared buffers";
674 
675 
676  // Close Stream
677  if(m_hDS)
678  {
679  J_DataStream_Close(m_hDS);
680  m_hDS = NULL;
681  }
682 
683 
684  MITK_INFO << "closed stream";
685 
686  //===================Close Factory and destroy Cam=====================
687  //void CloseFactoryAndCamera(); // Close camera and factory to clean up
688  retval = retval | spectroCam->stop();
689 
690 
691  MITK_INFO << "stopped camera";
692 
693  //BOOL TerminateStreamThread(void); // Terminate the image acquisition thread
694  if (spectroCam)
695  {
696  //DestroySpectroCam(spectroCam); //Destroy SpectroCam-Objekt
697  }
698 
699  MITK_INFO << "destroyed spectrocam";
700 
701  if (J_ST_SUCCESS == retval)
702  {
703  m_IsCameraRunning = false;
704  }
705 
706  return retval;
707 }
708 
709 
711 {
712  m_SpectroCamController_pimpl = new SpectroCamController_pimpl();
713 }
714 
716 {
717  delete m_SpectroCamController_pimpl;
718 }
719 
721 {
722  return m_SpectroCamController_pimpl->OpenCameraConnection();
723 }
724 
726 {
727  return m_SpectroCamController_pimpl->CloseCameraConnection();
728 }
729 
731 {
732  return m_SpectroCamController_pimpl->Ini();
733 }
734 
736 {
737  return m_SpectroCamController_pimpl->isCameraRunning();
738 }
739 
740 
742 {
743  return m_SpectroCamController_pimpl->GetCurrentImage();
744 }
745 
747 {
748  m_SpectroCamController_pimpl->SetCurrentImageAsWhiteBalance();
749 }
itk::SmartPointer< Self > Pointer
#define MITK_INFO
Definition: mitkLogMacros.h:22
itk::VectorImage< unsigned short, 2 > CompositeCameraImageType
STL namespace.
DataCollection - Class to facilitate loading/accessing structured data.
static mitk::SpectroCamController_pimpl * my_SpectroCamController
static cv::Mat createLLSQSolutionFromHMatrix()
mitk::Image::Pointer GetCurrentImage()
static void DisplayCameraStream(SpectroCamImage image)
static Pointer New()
unsigned short PixelType
static itkEventMacro(BoundingShapeInteractionEvent, itk::AnyEvent) class MITKBOUNDINGSHAPE_EXPORT BoundingShapeInteractor Pointer New()
Basic interaction methods for mitk::GeometryData.