Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
QmitkRenderingManager.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 ===================================================================*/
16 
17 #include "QmitkRenderingManager.h"
18 
19 #include "mitkBaseRenderer.h"
20 #include "mitkGeometry3D.h"
22 
23 #include <QApplication>
24 #include <QTimer>
25 
27 {
29 }
30 
32 {
33 }
34 
36 {
37 }
38 
40 {
41 }
42 
44 {
45  QApplication::postEvent(this, new QmitkRenderingRequestEvent);
46 }
47 
49 {
50  QTimer::singleShot(200, this, SLOT(TimerCallback()));
52 }
53 
55 {
56  if (!--pendingTimerCallbacks)
58 }
59 
60 bool QmitkRenderingManager::event(QEvent *event)
61 {
62  if (event->type() == (QEvent::Type)QmitkRenderingRequestEvent::RenderingRequest)
63  {
64  // Directly process all pending rendering requests
65  this->ExecutePendingRequests();
66  return true;
67  }
68 
69  return false;
70 }
virtual bool event(QEvent *event) override
virtual void DoFinishAbortRendering() override
virtual void StartOrResetTimer() override
virtual void DoMonitorRendering() override
virtual void GenerateRenderingRequestEvent() override