// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
// SPDX-License-Identifier: BSD-3-Clause
#include <vtkActor.h>
#include <vtkAppendPolyData.h>
#include <vtkCamera.h>
#include <vtkCubeSource.h>
#include <vtkInteractorEventRecorder.h>
#include <vtkInteractorStyleTrackballCamera.h>
#include <vtkNew.h>
#include <vtkOrientationRepresentation.h>
#include <vtkOrientationWidget.h>
#include <vtkPolyDataMapper.h>
#include <vtkProperty.h>
#include <vtkRenderWindow.h>
#include <vtkRenderWindowInteractor.h>
#include <vtkRenderer.h>
#include <vtkTransform.h>

constexpr char eventLog[] = "# StreamVersion 1.2\n"
                            "ExposeEvent 0 299 0 0 0 0 0\n "
                            "RenderEvent 0 299 0 0 0 0 0\n"
                            "EnterEvent 204 3 0 0 0 0 0\n"
                            "MouseMoveEvent 204 3 0 0 0 0 0\n"
                            "RenderEvent 204 3 0 0 0 0 0\n"
                            "MouseMoveEvent 197 46 0 0 0 0 0\n"
                            "MouseMoveEvent 196 56 0 0 0 0 0\n"
                            "MouseMoveEvent 195 64 0 0 0 0 0\n"
                            "MouseMoveEvent 195 68 0 0 0 0 0\n"
                            "MouseMoveEvent 194 71 0 0 0 0 0\n"
                            "MouseMoveEvent 194 73 0 0 0 0 0\n"
                            "MouseMoveEvent 194 76 0 0 0 0 0\n"
                            "MouseMoveEvent 194 78 0 0 0 0 0\n"
                            "MouseMoveEvent 194 80 0 0 0 0 0\n"
                            "RenderEvent 194 80 0 0 0 0 0\n"
                            "MouseMoveEvent 194 82 0 0 0 0 0\n"
                            "RenderEvent 194 82 0 0 0 0 0\n"
                            "MouseMoveEvent 193 84 0 0 0 0 0\n"
                            "MouseMoveEvent 193 86 0 0 0 0 0\n"
                            "MouseMoveEvent 193 88 0 0 0 0 0\n"
                            "MouseMoveEvent 193 89 0 0 0 0 0\n"
                            "MouseMoveEvent 193 91 0 0 0 0 0\n"
                            "MouseMoveEvent 193 92 0 0 0 0 0\n"
                            "MouseMoveEvent 193 93 0 0 0 0 0\n"
                            "MouseMoveEvent 193 94 0 0 0 0 0\n"
                            "MouseMoveEvent 193 95 0 0 0 0 0\n"
                            "MouseMoveEvent 193 97 0 0 0 0 0\n"
                            "MouseMoveEvent 193 98 0 0 0 0 0\n"
                            "MouseMoveEvent 193 99 0 0 0 0 0\n"
                            "MouseMoveEvent 193 100 0 0 0 0 0\n"
                            "RenderEvent 193 100 0 0 0 0 0\n"
                            "MouseMoveEvent 193 101 0 0 0 0 0\n"
                            "MouseMoveEvent 193 102 0 0 0 0 0\n"
                            "MouseMoveEvent 193 103 0 0 0 0 0\n"
                            "MouseMoveEvent 193 103 0 0 0 0 0\n"
                            "MouseMoveEvent 193 104 0 0 0 0 0\n"
                            "MouseMoveEvent 193 105 0 0 0 0 0\n"
                            "MouseMoveEvent 193 105 0 0 0 0 0\n"
                            "MouseMoveEvent 193 105 0 0 0 0 0\n"
                            "MouseMoveEvent 193 105 0 0 0 0 0\n"
                            "MouseMoveEvent 193 106 0 0 0 0 0\n"
                            "MouseMoveEvent 193 106 0 0 0 0 0\n"
                            "MouseMoveEvent 193 106 0 0 0 0 0\n"
                            "MouseMoveEvent 193 106 0 0 0 0 0\n"
                            "MouseMoveEvent 193 107 0 0 0 0 0\n"
                            "MouseMoveEvent 193 107 0 0 0 0 0\n"
                            "MouseMoveEvent 193 108 0 0 0 0 0\n"
                            "MouseMoveEvent 194 109 0 0 0 0 0\n"
                            "RenderEvent 194 109 0 0 0 0 0\n"
                            "MouseMoveEvent 194 109 0 0 0 0 0\n"
                            "MouseMoveEvent 194 110 0 0 0 0 0\n"
                            "MouseMoveEvent 194 111 0 0 0 0 0\n"
                            "MouseMoveEvent 194 111 0 0 0 0 0\n"
                            "MouseMoveEvent 194 112 0 0 0 0 0\n"
                            "MouseMoveEvent 194 113 0 0 0 0 0\n"
                            "MouseMoveEvent 195 114 0 0 0 0 0\n"
                            "MouseMoveEvent 195 115 0 0 0 0 0\n"
                            "MouseMoveEvent 195 116 0 0 0 0 0\n"
                            "MouseMoveEvent 195 117 0 0 0 0 0\n"
                            "MouseMoveEvent 195 118 0 0 0 0 0\n"
                            "MouseMoveEvent 195 119 0 0 0 0 0\n"
                            "MouseMoveEvent 195 119 0 0 0 0 0\n"
                            "MouseMoveEvent 195 120 0 0 0 0 0\n"
                            "MouseMoveEvent 196 121 0 0 0 0 0\n"
                            "MouseMoveEvent 196 122 0 0 0 0 0\n"
                            "MouseMoveEvent 196 122 0 0 0 0 0\n"
                            "MouseMoveEvent 196 123 0 0 0 0 0\n"
                            "MouseMoveEvent 196 124 0 0 0 0 0\n"
                            "MouseMoveEvent 196 125 0 0 0 0 0\n"
                            "MouseMoveEvent 196 125 0 0 0 0 0\n"
                            "MouseMoveEvent 196 126 0 0 0 0 0\n"
                            "MouseMoveEvent 196 126 0 0 0 0 0\n"
                            "MouseMoveEvent 196 127 0 0 0 0 0\n"
                            "MouseMoveEvent 196 128 0 0 0 0 0\n"
                            "MouseMoveEvent 196 129 0 0 0 0 0\n"
                            "MouseMoveEvent 196 129 0 0 0 0 0\n"
                            "MouseMoveEvent 196 129 0 0 0 0 0\n"
                            "MouseMoveEvent 196 130 0 0 0 0 0\n"
                            "MouseMoveEvent 196 130 0 0 0 0 0\n"
                            "LeftButtonPressEvent 196 130 0 0 0 0 0\n"
                            "MouseMoveEvent 196 129 0 0 0 0 0\n"
                            "RenderEvent 196 129 0 0 0 0 0\n"
                            "MouseMoveEvent 196 129 0 0 0 0 0\n"
                            "RenderEvent 196 129 0 0 0 0 0\n"
                            "MouseMoveEvent 196 129 0 0 0 0 0\n"
                            "RenderEvent 196 129 0 0 0 0 0\n"
                            "MouseMoveEvent 196 128 0 0 0 0 0\n"
                            "RenderEvent 196 128 0 0 0 0 0\n"
                            "MouseMoveEvent 196 128 0 0 0 0 0\n"
                            "RenderEvent 196 128 0 0 0 0 0\n"
                            "MouseMoveEvent 196 127 0 0 0 0 0\n"
                            "RenderEvent 196 127 0 0 0 0 0\n"
                            "MouseMoveEvent 196 127 0 0 0 0 0\n"
                            "RenderEvent 196 127 0 0 0 0 0\n"
                            "MouseMoveEvent 196 126 0 0 0 0 0\n"
                            "RenderEvent 196 126 0 0 0 0 0\n"
                            "MouseMoveEvent 196 125 0 0 0 0 0\n"
                            "RenderEvent 196 125 0 0 0 0 0\n"
                            "MouseMoveEvent 196 125 0 0 0 0 0\n"
                            "RenderEvent 196 125 0 0 0 0 0\n"
                            "MouseMoveEvent 196 124 0 0 0 0 0\n"
                            "RenderEvent 196 124 0 0 0 0 0\n"
                            "MouseMoveEvent 196 123 0 0 0 0 0\n"
                            "RenderEvent 196 123 0 0 0 0 0\n"
                            "MouseMoveEvent 196 122 0 0 0 0 0\n"
                            "RenderEvent 196 122 0 0 0 0 0\n"
                            "MouseMoveEvent 196 122 0 0 0 0 0\n"
                            "RenderEvent 196 122 0 0 0 0 0\n"
                            "MouseMoveEvent 196 121 0 0 0 0 0\n"
                            "RenderEvent 196 121 0 0 0 0 0\n"
                            "MouseMoveEvent 196 120 0 0 0 0 0\n"
                            "RenderEvent 196 120 0 0 0 0 0\n"
                            "MouseMoveEvent 196 119 0 0 0 0 0\n"
                            "RenderEvent 196 119 0 0 0 0 0\n"
                            "MouseMoveEvent 196 119 0 0 0 0 0\n"
                            "RenderEvent 196 119 0 0 0 0 0\n"
                            "MouseMoveEvent 196 118 0 0 0 0 0\n"
                            "RenderEvent 196 118 0 0 0 0 0\n"
                            "MouseMoveEvent 196 117 0 0 0 0 0\n"
                            "RenderEvent 196 117 0 0 0 0 0\n"
                            "MouseMoveEvent 196 116 0 0 0 0 0\n"
                            "RenderEvent 196 116 0 0 0 0 0\n"
                            "MouseMoveEvent 196 116 0 0 0 0 0\n"
                            "RenderEvent 196 116 0 0 0 0 0\n"
                            "MouseMoveEvent 196 115 0 0 0 0 0\n"
                            "RenderEvent 196 115 0 0 0 0 0\n"
                            "MouseMoveEvent 196 114 0 0 0 0 0\n"
                            "RenderEvent 196 114 0 0 0 0 0\n"
                            "MouseMoveEvent 196 114 0 0 0 0 0\n"
                            "RenderEvent 196 114 0 0 0 0 0\n"
                            "MouseMoveEvent 196 113 0 0 0 0 0\n"
                            "RenderEvent 196 113 0 0 0 0 0\n"
                            "MouseMoveEvent 196 112 0 0 0 0 0\n"
                            "RenderEvent 196 112 0 0 0 0 0\n"
                            "MouseMoveEvent 197 111 0 0 0 0 0\n"
                            "RenderEvent 197 111 0 0 0 0 0\n"
                            "MouseMoveEvent 197 110 0 0 0 0 0\n"
                            "RenderEvent 197 110 0 0 0 0 0\n"
                            "MouseMoveEvent 197 109 0 0 0 0 0\n"
                            "RenderEvent 197 109 0 0 0 0 0\n"
                            "MouseMoveEvent 197 109 0 0 0 0 0\n"
                            "RenderEvent 197 109 0 0 0 0 0\n"
                            "MouseMoveEvent 197 108 0 0 0 0 0\n"
                            "RenderEvent 197 108 0 0 0 0 0\n"
                            "MouseMoveEvent 197 107 0 0 0 0 0\n"
                            "RenderEvent 197 107 0 0 0 0 0\n"
                            "MouseMoveEvent 197 106 0 0 0 0 0\n"
                            "RenderEvent 197 106 0 0 0 0 0\n"
                            "MouseMoveEvent 197 105 0 0 0 0 0\n"
                            "RenderEvent 197 105 0 0 0 0 0\n"
                            "MouseMoveEvent 197 105 0 0 0 0 0\n"
                            "RenderEvent 197 105 0 0 0 0 0\n"
                            "MouseMoveEvent 197 104 0 0 0 0 0\n"
                            "RenderEvent 197 104 0 0 0 0 0\n"
                            "MouseMoveEvent 197 103 0 0 0 0 0\n"
                            "RenderEvent 197 103 0 0 0 0 0\n"
                            "MouseMoveEvent 197 103 0 0 0 0 0\n"
                            "RenderEvent 197 103 0 0 0 0 0\n"
                            "MouseMoveEvent 197 102 0 0 0 0 0\n"
                            "RenderEvent 197 102 0 0 0 0 0\n"
                            "MouseMoveEvent 197 101 0 0 0 0 0\n"
                            "RenderEvent 197 101 0 0 0 0 0\n"
                            "MouseMoveEvent 197 101 0 0 0 0 0\n"
                            "RenderEvent 197 101 0 0 0 0 0\n"
                            "MouseMoveEvent 197 100 0 0 0 0 0\n"
                            "RenderEvent 197 100 0 0 0 0 0\n"
                            "MouseMoveEvent 197 99 0 0 0 0 0\n"
                            "RenderEvent 197 99 0 0 0 0 0\n"
                            "MouseMoveEvent 197 99 0 0 0 0 0\n"
                            "RenderEvent 197 99 0 0 0 0 0\n"
                            "MouseMoveEvent 197 98 0 0 0 0 0\n"
                            "RenderEvent 197 98 0 0 0 0 0\n"
                            "MouseMoveEvent 197 97 0 0 0 0 0\n"
                            "RenderEvent 197 97 0 0 0 0 0\n"
                            "MouseMoveEvent 197 96 0 0 0 0 0\n"
                            "RenderEvent 197 96 0 0 0 0 0\n"
                            "MouseMoveEvent 197 96 0 0 0 0 0\n"
                            "RenderEvent 197 96 0 0 0 0 0\n"
                            "MouseMoveEvent 197 95 0 0 0 0 0\n"
                            "RenderEvent 197 95 0 0 0 0 0\n"
                            "MouseMoveEvent 197 94 0 0 0 0 0\n"
                            "RenderEvent 197 94 0 0 0 0 0\n"
                            "MouseMoveEvent 197 94 0 0 0 0 0\n"
                            "RenderEvent 197 94 0 0 0 0 0\n"
                            "MouseMoveEvent 197 93 0 0 0 0 0\n"
                            "RenderEvent 197 93 0 0 0 0 0\n"
                            "MouseMoveEvent 197 92 0 0 0 0 0\n"
                            "RenderEvent 197 92 0 0 0 0 0\n"
                            "MouseMoveEvent 197 91 0 0 0 0 0\n"
                            "RenderEvent 197 91 0 0 0 0 0\n"
                            "MouseMoveEvent 197 90 0 0 0 0 0\n"
                            "RenderEvent 197 90 0 0 0 0 0\n"
                            "MouseMoveEvent 197 89 0 0 0 0 0\n"
                            "RenderEvent 197 89 0 0 0 0 0\n"
                            "MouseMoveEvent 197 88 0 0 0 0 0\n"
                            "RenderEvent 197 88 0 0 0 0 0\n"
                            "MouseMoveEvent 197 87 0 0 0 0 0\n"
                            "RenderEvent 197 87 0 0 0 0 0\n"
                            "MouseMoveEvent 197 87 0 0 0 0 0\n"
                            "RenderEvent 197 87 0 0 0 0 0\n"
                            "MouseMoveEvent 197 87 0 0 0 0 0\n"
                            "RenderEvent 197 87 0 0 0 0 0\n"
                            "MouseMoveEvent 197 86 0 0 0 0 0\n"
                            "RenderEvent 197 86 0 0 0 0 0\n"
                            "LeftButtonReleaseEvent 197 86 0 0 0 0 0\n"
                            "RenderEvent 197 86 0 0 0 0 0\n"
                            "MouseMoveEvent 196 86 0 0 0 0 0\n"
                            "RenderEvent 196 86 0 0 0 0 0\n"
                            "MouseMoveEvent 186 85 0 0 0 0 0\n"
                            "MouseMoveEvent 180 85 0 0 0 0 0\n"
                            "MouseMoveEvent 177 85 0 0 0 0 0\n"
                            "RenderEvent 177 85 0 0 0 0 0\n"
                            "MouseMoveEvent 175 85 0 0 0 0 0\n"
                            "RenderEvent 175 85 0 0 0 0 0\n"
                            "MouseMoveEvent 171 84 0 0 0 0 0\n"
                            "RenderEvent 171 84 0 0 0 0 0\n"
                            "MouseMoveEvent 169 84 0 0 0 0 0\n"
                            "RenderEvent 169 84 0 0 0 0 0\n"
                            "MouseMoveEvent 166 84 0 0 0 0 0\n"
                            "RenderEvent 166 84 0 0 0 0 0\n"
                            "MouseMoveEvent 159 84 0 0 0 0 0\n"
                            "RenderEvent 159 84 0 0 0 0 0\n"
                            "MouseMoveEvent 154 84 0 0 0 0 0\n"
                            "MouseMoveEvent 147 85 0 0 0 0 0\n"
                            "MouseMoveEvent 145 85 0 0 0 0 0\n"
                            "MouseMoveEvent 142 85 0 0 0 0 0\n"
                            "MouseMoveEvent 140 85 0 0 0 0 0\n"
                            "MouseMoveEvent 138 85 0 0 0 0 0\n"
                            "MouseMoveEvent 135 86 0 0 0 0 0\n"
                            "MouseMoveEvent 133 86 0 0 0 0 0\n"
                            "MouseMoveEvent 131 86 0 0 0 0 0\n"
                            "MouseMoveEvent 129 86 0 0 0 0 0\n"
                            "MouseMoveEvent 127 86 0 0 0 0 0\n"
                            "MouseMoveEvent 125 86 0 0 0 0 0\n"
                            "MouseMoveEvent 124 87 0 0 0 0 0\n"
                            "MouseMoveEvent 123 87 0 0 0 0 0\n"
                            "MouseMoveEvent 122 87 0 0 0 0 0\n"
                            "MouseMoveEvent 120 87 0 0 0 0 0\n"
                            "MouseMoveEvent 119 87 0 0 0 0 0\n"
                            "MouseMoveEvent 118 87 0 0 0 0 0\n"
                            "RenderEvent 118 87 0 0 0 0 0\n"
                            "MouseMoveEvent 116 88 0 0 0 0 0\n"
                            "MouseMoveEvent 115 88 0 0 0 0 0\n"
                            "MouseMoveEvent 115 88 0 0 0 0 0\n"
                            "MouseMoveEvent 114 88 0 0 0 0 0\n"
                            "MouseMoveEvent 113 88 0 0 0 0 0\n"
                            "MouseMoveEvent 112 88 0 0 0 0 0\n"
                            "MouseMoveEvent 111 88 0 0 0 0 0\n"
                            "MouseMoveEvent 110 88 0 0 0 0 0\n"
                            "MouseMoveEvent 109 88 0 0 0 0 0\n"
                            "MouseMoveEvent 109 88 0 0 0 0 0\n"
                            "MouseMoveEvent 108 88 0 0 0 0 0\n"
                            "MouseMoveEvent 107 88 0 0 0 0 0\n"
                            "MouseMoveEvent 107 88 0 0 0 0 0\n"
                            "MouseMoveEvent 106 88 0 0 0 0 0\n"
                            "MouseMoveEvent 105 88 0 0 0 0 0\n"
                            "MouseMoveEvent 105 88 0 0 0 0 0\n"
                            "MouseMoveEvent 104 88 0 0 0 0 0\n"
                            "MouseMoveEvent 103 88 0 0 0 0 0\n"
                            "MouseMoveEvent 103 88 0 0 0 0 0\n"
                            "MouseMoveEvent 102 88 0 0 0 0 0\n"
                            "MouseMoveEvent 101 88 0 0 0 0 0\n"
                            "MouseMoveEvent 100 88 0 0 0 0 0\n"
                            "MouseMoveEvent 100 88 0 0 0 0 0\n"
                            "MouseMoveEvent 99 89 0 0 0 0 0\n"
                            "MouseMoveEvent 98 89 0 0 0 0 0\n"
                            "MouseMoveEvent 98 89 0 0 0 0 0\n"
                            "MouseMoveEvent 97 89 0 0 0 0 0\n"
                            "MouseMoveEvent 96 89 0 0 0 0 0\n"
                            "MouseMoveEvent 96 89 0 0 0 0 0\n"
                            "MouseMoveEvent 95 89 0 0 0 0 0\n"
                            "MouseMoveEvent 94 89 0 0 0 0 0\n"
                            "MouseMoveEvent 93 90 0 0 0 0 0\n"
                            "MouseMoveEvent 93 90 0 0 0 0 0\n"
                            "MouseMoveEvent 92 90 0 0 0 0 0\n"
                            "MouseMoveEvent 92 90 0 0 0 0 0\n"
                            "MouseMoveEvent 91 91 0 0 0 0 0\n"
                            "MouseMoveEvent 91 91 0 0 0 0 0\n"
                            "MouseMoveEvent 90 91 0 0 0 0 0\n"
                            "MouseMoveEvent 90 92 0 0 0 0 0\n"
                            "MouseMoveEvent 89 92 0 0 0 0 0\n"
                            "MouseMoveEvent 89 92 0 0 0 0 0\n"
                            "MouseMoveEvent 88 93 0 0 0 0 0\n"
                            "MouseMoveEvent 88 93 0 0 0 0 0\n"
                            "MouseMoveEvent 87 93 0 0 0 0 0\n"
                            "MouseMoveEvent 87 93 0 0 0 0 0\n"
                            "MouseMoveEvent 87 93 0 0 0 0 0\n"
                            "MouseMoveEvent 86 93 0 0 0 0 0\n"
                            "MouseMoveEvent 86 94 0 0 0 0 0\n"
                            "MouseMoveEvent 86 94 0 0 0 0 0\n"
                            "MouseMoveEvent 86 94 0 0 0 0 0\n"
                            "MouseMoveEvent 86 94 0 0 0 0 0\n"
                            "MouseMoveEvent 86 94 0 0 0 0 0\n"
                            "MouseMoveEvent 86 95 0 0 0 0 0\n"
                            "MouseMoveEvent 86 95 0 0 0 0 0\n"
                            "MouseMoveEvent 86 95 0 0 0 0 0\n"
                            "MouseMoveEvent 86 95 0 0 0 0 0\n"
                            "MouseMoveEvent 86 96 0 0 0 0 0\n"
                            "MouseMoveEvent 86 96 0 0 0 0 0\n"
                            "MouseMoveEvent 86 96 0 0 0 0 0\n"
                            "MouseMoveEvent 86 96 0 0 0 0 0\n"
                            "MouseMoveEvent 86 97 0 0 0 0 0\n"
                            "MouseMoveEvent 86 97 0 0 0 0 0\n"
                            "MouseMoveEvent 86 97 0 0 0 0 0\n"
                            "MouseMoveEvent 86 97 0 0 0 0 0\n"
                            "MouseMoveEvent 86 98 0 0 0 0 0\n"
                            "MouseMoveEvent 86 98 0 0 0 0 0\n"
                            "LeftButtonPressEvent 86 98 0 0 0 0 0\n"
                            "MouseMoveEvent 86 98 0 0 0 0 0\n"
                            "RenderEvent 86 98 0 0 0 0 0\n"
                            "MouseMoveEvent 87 97 0 0 0 0 0\n"
                            "RenderEvent 87 97 0 0 0 0 0\n"
                            "MouseMoveEvent 90 96 0 0 0 0 0\n"
                            "RenderEvent 90 96 0 0 0 0 0\n"
                            "MouseMoveEvent 90 96 0 0 0 0 0\n"
                            "RenderEvent 90 96 0 0 0 0 0\n"
                            "MouseMoveEvent 91 95 0 0 0 0 0\n"
                            "RenderEvent 91 95 0 0 0 0 0\n"
                            "MouseMoveEvent 92 95 0 0 0 0 0\n"
                            "RenderEvent 92 95 0 0 0 0 0\n"
                            "MouseMoveEvent 93 94 0 0 0 0 0\n"
                            "RenderEvent 93 94 0 0 0 0 0\n"
                            "MouseMoveEvent 93 94 0 0 0 0 0\n"
                            "RenderEvent 93 94 0 0 0 0 0\n"
                            "MouseMoveEvent 94 94 0 0 0 0 0\n"
                            "RenderEvent 94 94 0 0 0 0 0\n"
                            "MouseMoveEvent 94 93 0 0 0 0 0\n"
                            "RenderEvent 94 93 0 0 0 0 0\n"
                            "MouseMoveEvent 96 93 0 0 0 0 0\n"
                            "RenderEvent 96 93 0 0 0 0 0\n"
                            "MouseMoveEvent 96 92 0 0 0 0 0\n"
                            "RenderEvent 96 92 0 0 0 0 0\n"
                            "MouseMoveEvent 97 92 0 0 0 0 0\n"
                            "RenderEvent 97 92 0 0 0 0 0\n"
                            "MouseMoveEvent 98 92 0 0 0 0 0\n"
                            "RenderEvent 98 92 0 0 0 0 0\n"
                            "MouseMoveEvent 98 92 0 0 0 0 0\n"
                            "RenderEvent 98 92 0 0 0 0 0\n"
                            "MouseMoveEvent 99 92 0 0 0 0 0\n"
                            "RenderEvent 99 92 0 0 0 0 0\n"
                            "MouseMoveEvent 100 91 0 0 0 0 0\n"
                            "RenderEvent 100 91 0 0 0 0 0\n"
                            "MouseMoveEvent 100 91 0 0 0 0 0\n"
                            "RenderEvent 100 91 0 0 0 0 0\n"
                            "MouseMoveEvent 102 90 0 0 0 0 0\n"
                            "RenderEvent 102 90 0 0 0 0 0\n"
                            "MouseMoveEvent 103 90 0 0 0 0 0\n"
                            "RenderEvent 103 90 0 0 0 0 0\n"
                            "MouseMoveEvent 104 89 0 0 0 0 0\n"
                            "RenderEvent 104 89 0 0 0 0 0\n"
                            "MouseMoveEvent 105 89 0 0 0 0 0\n"
                            "RenderEvent 105 89 0 0 0 0 0\n"
                            "MouseMoveEvent 106 88 0 0 0 0 0\n"
                            "RenderEvent 106 88 0 0 0 0 0\n"
                            "MouseMoveEvent 108 88 0 0 0 0 0\n"
                            "RenderEvent 108 88 0 0 0 0 0\n"
                            "MouseMoveEvent 109 87 0 0 0 0 0\n"
                            "RenderEvent 109 87 0 0 0 0 0\n"
                            "MouseMoveEvent 110 86 0 0 0 0 0\n"
                            "RenderEvent 110 86 0 0 0 0 0\n"
                            "MouseMoveEvent 111 86 0 0 0 0 0\n"
                            "RenderEvent 111 86 0 0 0 0 0\n"
                            "MouseMoveEvent 112 86 0 0 0 0 0\n"
                            "RenderEvent 112 86 0 0 0 0 0\n"
                            "MouseMoveEvent 113 85 0 0 0 0 0\n"
                            "RenderEvent 113 85 0 0 0 0 0\n"
                            "MouseMoveEvent 115 85 0 0 0 0 0\n"
                            "RenderEvent 115 85 0 0 0 0 0\n"
                            "MouseMoveEvent 116 84 0 0 0 0 0\n"
                            "RenderEvent 116 84 0 0 0 0 0\n"
                            "MouseMoveEvent 117 83 0 0 0 0 0\n"
                            "RenderEvent 117 83 0 0 0 0 0\n"
                            "MouseMoveEvent 119 83 0 0 0 0 0\n"
                            "RenderEvent 119 83 0 0 0 0 0\n"
                            "MouseMoveEvent 121 82 0 0 0 0 0\n"
                            "RenderEvent 121 82 0 0 0 0 0\n"
                            "MouseMoveEvent 122 82 0 0 0 0 0\n"
                            "RenderEvent 122 82 0 0 0 0 0\n"
                            "MouseMoveEvent 123 82 0 0 0 0 0\n"
                            "RenderEvent 123 82 0 0 0 0 0\n"
                            "MouseMoveEvent 125 81 0 0 0 0 0\n"
                            "RenderEvent 125 81 0 0 0 0 0\n"
                            "MouseMoveEvent 126 80 0 0 0 0 0\n"
                            "RenderEvent 126 80 0 0 0 0 0\n"
                            "MouseMoveEvent 128 79 0 0 0 0 0\n"
                            "RenderEvent 128 79 0 0 0 0 0\n"
                            "MouseMoveEvent 129 79 0 0 0 0 0\n"
                            "RenderEvent 129 79 0 0 0 0 0\n"
                            "MouseMoveEvent 131 78 0 0 0 0 0\n"
                            "RenderEvent 131 78 0 0 0 0 0\n"
                            "MouseMoveEvent 133 77 0 0 0 0 0\n"
                            "RenderEvent 133 77 0 0 0 0 0\n"
                            "MouseMoveEvent 134 77 0 0 0 0 0\n"
                            "RenderEvent 134 77 0 0 0 0 0\n"
                            "MouseMoveEvent 135 77 0 0 0 0 0\n"
                            "RenderEvent 135 77 0 0 0 0 0\n"
                            "MouseMoveEvent 136 76 0 0 0 0 0\n"
                            "RenderEvent 136 76 0 0 0 0 0\n"
                            "MouseMoveEvent 136 76 0 0 0 0 0\n"
                            "RenderEvent 136 76 0 0 0 0 0\n"
                            "LeftButtonReleaseEvent 136 76 0 0 0 0 0\n"
                            "RenderEvent 136 76 0 0 0 0 0\n"
                            "MouseMoveEvent 136 76 0 0 0 0 0\n"
                            "RenderEvent 136 76 0 0 0 0 0\n"
                            "MouseMoveEvent 135 77 0 0 0 0 0\n"
                            "MouseMoveEvent 129 81 0 0 0 0 0\n"
                            "MouseMoveEvent 125 83 0 0 0 0 0\n"
                            "MouseMoveEvent 121 86 0 0 0 0 0\n"
                            "MouseMoveEvent 117 88 0 0 0 0 0\n"
                            "MouseMoveEvent 113 90 0 0 0 0 0\n"
                            "MouseMoveEvent 110 92 0 0 0 0 0\n"
                            "MouseMoveEvent 106 94 0 0 0 0 0\n"
                            "MouseMoveEvent 101 97 0 0 0 0 0\n"
                            "MouseMoveEvent 98 99 0 0 0 0 0\n"
                            "MouseMoveEvent 95 101 0 0 0 0 0\n"
                            "MouseMoveEvent 92 103 0 0 0 0 0\n"
                            "MouseMoveEvent 91 104 0 0 0 0 0\n"
                            "MouseMoveEvent 89 105 0 0 0 0 0\n"
                            "MouseMoveEvent 88 106 0 0 0 0 0\n"
                            "MouseMoveEvent 87 106 0 0 0 0 0\n"
                            "MouseMoveEvent 86 107 0 0 0 0 0\n"
                            "MouseMoveEvent 85 107 0 0 0 0 0\n"
                            "MouseMoveEvent 84 108 0 0 0 0 0\n"
                            "MouseMoveEvent 84 109 0 0 0 0 0\n"
                            "MouseMoveEvent 83 109 0 0 0 0 0\n"
                            "MouseMoveEvent 82 110 0 0 0 0 0\n"
                            "MouseMoveEvent 81 111 0 0 0 0 0\n"
                            "MouseMoveEvent 80 111 0 0 0 0 0\n"
                            "MouseMoveEvent 80 112 0 0 0 0 0\n"
                            "MouseMoveEvent 79 113 0 0 0 0 0\n"
                            "MouseMoveEvent 78 113 0 0 0 0 0\n"
                            "MouseMoveEvent 77 114 0 0 0 0 0\n"
                            "MouseMoveEvent 76 115 0 0 0 0 0\n"
                            "MouseMoveEvent 75 116 0 0 0 0 0\n"
                            "MouseMoveEvent 74 117 0 0 0 0 0\n"
                            "MouseMoveEvent 73 117 0 0 0 0 0\n"
                            "MouseMoveEvent 72 118 0 0 0 0 0\n"
                            "MouseMoveEvent 71 119 0 0 0 0 0\n"
                            "MouseMoveEvent 70 120 0 0 0 0 0\n"
                            "MouseMoveEvent 70 120 0 0 0 0 0\n"
                            "MouseMoveEvent 69 121 0 0 0 0 0\n"
                            "MouseMoveEvent 68 121 0 0 0 0 0\n"
                            "MouseMoveEvent 68 122 0 0 0 0 0\n"
                            "MouseMoveEvent 67 122 0 0 0 0 0\n"
                            "MouseMoveEvent 67 123 0 0 0 0 0\n"
                            "MouseMoveEvent 66 123 0 0 0 0 0\n"
                            "MouseMoveEvent 66 123 0 0 0 0 0\n"
                            "MouseMoveEvent 65 124 0 0 0 0 0\n"
                            "MouseMoveEvent 65 124 0 0 0 0 0\n"
                            "MouseMoveEvent 65 124 0 0 0 0 0\n"
                            "MouseMoveEvent 64 125 0 0 0 0 0\n"
                            "MouseMoveEvent 64 125 0 0 0 0 0\n"
                            "MouseMoveEvent 63 125 0 0 0 0 0\n"
                            "MouseMoveEvent 63 126 0 0 0 0 0\n"
                            "MouseMoveEvent 62 126 0 0 0 0 0\n"
                            "MouseMoveEvent 62 126 0 0 0 0 0\n"
                            "MouseMoveEvent 62 127 0 0 0 0 0\n"
                            "MouseMoveEvent 61 127 0 0 0 0 0\n"
                            "MouseMoveEvent 61 127 0 0 0 0 0\n"
                            "MouseMoveEvent 61 128 0 0 0 0 0\n"
                            "MouseMoveEvent 60 128 0 0 0 0 0\n"
                            "MouseMoveEvent 60 128 0 0 0 0 0\n"
                            "MouseMoveEvent 60 129 0 0 0 0 0\n"
                            "MouseMoveEvent 59 129 0 0 0 0 0\n"
                            "MouseMoveEvent 59 129 0 0 0 0 0\n"
                            "MouseMoveEvent 59 130 0 0 0 0 0\n"
                            "MouseMoveEvent 58 130 0 0 0 0 0\n"
                            "MouseMoveEvent 58 131 0 0 0 0 0\n"
                            "RenderEvent 58 131 0 0 0 0 0\n"
                            "MouseMoveEvent 57 131 0 0 0 0 0\n"
                            "MouseMoveEvent 57 131 0 0 0 0 0\n"
                            "MouseMoveEvent 56 132 0 0 0 0 0\n"
                            "MouseMoveEvent 56 132 0 0 0 0 0\n"
                            "MouseMoveEvent 55 133 0 0 0 0 0\n"
                            "RenderEvent 55 133 0 0 0 0 0\n"
                            "MouseMoveEvent 55 133 0 0 0 0 0\n"
                            "MouseMoveEvent 55 134 0 0 0 0 0\n"
                            "RenderEvent 55 134 0 0 0 0 0\n"
                            "MouseMoveEvent 54 134 0 0 0 0 0\n"
                            "MouseMoveEvent 54 134 0 0 0 0 0\n"
                            "MouseMoveEvent 53 135 0 0 0 0 0\n"
                            "MouseMoveEvent 53 135 0 0 0 0 0\n"
                            "MouseMoveEvent 53 135 0 0 0 0 0\n"
                            "MouseMoveEvent 52 136 0 0 0 0 0\n"
                            "MouseMoveEvent 52 136 0 0 0 0 0\n"
                            "MouseMoveEvent 52 136 0 0 0 0 0\n"
                            "MouseMoveEvent 51 137 0 0 0 0 0\n"
                            "MouseMoveEvent 51 137 0 0 0 0 0\n"
                            "MouseMoveEvent 50 138 0 0 0 0 0\n"
                            "MouseMoveEvent 50 139 0 0 0 0 0\n"
                            "MouseMoveEvent 50 139 0 0 0 0 0\n"
                            "MouseMoveEvent 50 140 0 0 0 0 0\n"
                            "MouseMoveEvent 50 140 0 0 0 0 0\n"
                            "MouseMoveEvent 50 140 0 0 0 0 0\n"
                            "MouseMoveEvent 50 141 0 0 0 0 0\n"
                            "MouseMoveEvent 50 141 0 0 0 0 0\n"
                            "LeftButtonPressEvent 50 141 0 0 0 0 0\n"
                            "MouseMoveEvent 50 141 0 0 0 0 0\n"
                            "RenderEvent 50 141 0 0 0 0 0\n"
                            "MouseMoveEvent 50 139 0 0 0 0 0\n"
                            "RenderEvent 50 139 0 0 0 0 0\n"
                            "MouseMoveEvent 49 137 0 0 0 0 0\n"
                            "RenderEvent 49 137 0 0 0 0 0\n"
                            "MouseMoveEvent 49 135 0 0 0 0 0\n"
                            "RenderEvent 49 135 0 0 0 0 0\n"
                            "MouseMoveEvent 49 134 0 0 0 0 0\n"
                            "RenderEvent 49 134 0 0 0 0 0\n"
                            "MouseMoveEvent 49 133 0 0 0 0 0\n"
                            "RenderEvent 49 133 0 0 0 0 0\n"
                            "MouseMoveEvent 49 133 0 0 0 0 0\n"
                            "RenderEvent 49 133 0 0 0 0 0\n"
                            "MouseMoveEvent 48 130 0 0 0 0 0\n"
                            "RenderEvent 48 130 0 0 0 0 0\n"
                            "MouseMoveEvent 48 128 0 0 0 0 0\n"
                            "RenderEvent 48 128 0 0 0 0 0\n"
                            "MouseMoveEvent 48 126 0 0 0 0 0\n"
                            "RenderEvent 48 126 0 0 0 0 0\n"
                            "MouseMoveEvent 48 124 0 0 0 0 0\n"
                            "RenderEvent 48 124 0 0 0 0 0\n"
                            "MouseMoveEvent 47 122 0 0 0 0 0\n"
                            "RenderEvent 47 122 0 0 0 0 0\n"
                            "MouseMoveEvent 47 120 0 0 0 0 0\n"
                            "RenderEvent 47 120 0 0 0 0 0\n"
                            "MouseMoveEvent 47 118 0 0 0 0 0\n"
                            "RenderEvent 47 118 0 0 0 0 0\n"
                            "MouseMoveEvent 47 117 0 0 0 0 0\n"
                            "RenderEvent 47 117 0 0 0 0 0\n"
                            "MouseMoveEvent 47 115 0 0 0 0 0\n"
                            "RenderEvent 47 115 0 0 0 0 0\n"
                            "MouseMoveEvent 47 113 0 0 0 0 0\n"
                            "RenderEvent 47 113 0 0 0 0 0\n"
                            "MouseMoveEvent 47 112 0 0 0 0 0\n"
                            "RenderEvent 47 112 0 0 0 0 0\n"
                            "MouseMoveEvent 46 110 0 0 0 0 0\n"
                            "RenderEvent 46 110 0 0 0 0 0\n"
                            "MouseMoveEvent 46 109 0 0 0 0 0\n"
                            "RenderEvent 46 109 0 0 0 0 0\n"
                            "MouseMoveEvent 46 107 0 0 0 0 0\n"
                            "RenderEvent 46 107 0 0 0 0 0\n"
                            "MouseMoveEvent 46 106 0 0 0 0 0\n"
                            "RenderEvent 46 106 0 0 0 0 0\n"
                            "MouseMoveEvent 46 104 0 0 0 0 0\n"
                            "RenderEvent 46 104 0 0 0 0 0\n"
                            "MouseMoveEvent 46 103 0 0 0 0 0\n"
                            "RenderEvent 46 103 0 0 0 0 0\n"
                            "MouseMoveEvent 46 102 0 0 0 0 0\n"
                            "RenderEvent 46 102 0 0 0 0 0\n"
                            "MouseMoveEvent 46 100 0 0 0 0 0\n"
                            "RenderEvent 46 100 0 0 0 0 0\n"
                            "MouseMoveEvent 46 99 0 0 0 0 0\n"
                            "RenderEvent 46 99 0 0 0 0 0\n"
                            "MouseMoveEvent 45 98 0 0 0 0 0\n"
                            "RenderEvent 45 98 0 0 0 0 0\n"
                            "MouseMoveEvent 45 97 0 0 0 0 0\n"
                            "RenderEvent 45 97 0 0 0 0 0\n"
                            "MouseMoveEvent 45 95 0 0 0 0 0\n"
                            "RenderEvent 45 95 0 0 0 0 0\n"
                            "MouseMoveEvent 45 94 0 0 0 0 0\n"
                            "RenderEvent 45 94 0 0 0 0 0\n"
                            "MouseMoveEvent 44 92 0 0 0 0 0\n"
                            "RenderEvent 44 92 0 0 0 0 0\n"
                            "MouseMoveEvent 44 91 0 0 0 0 0\n"
                            "RenderEvent 44 91 0 0 0 0 0\n"
                            "MouseMoveEvent 44 89 0 0 0 0 0\n"
                            "RenderEvent 44 89 0 0 0 0 0\n"
                            "MouseMoveEvent 44 88 0 0 0 0 0\n"
                            "RenderEvent 44 88 0 0 0 0 0\n"
                            "MouseMoveEvent 43 87 0 0 0 0 0\n"
                            "RenderEvent 43 87 0 0 0 0 0\n"
                            "MouseMoveEvent 43 86 0 0 0 0 0\n"
                            "RenderEvent 43 86 0 0 0 0 0\n"
                            "MouseMoveEvent 43 83 0 0 0 0 0\n"
                            "RenderEvent 43 83 0 0 0 0 0\n"
                            "MouseMoveEvent 42 81 0 0 0 0 0\n"
                            "RenderEvent 42 81 0 0 0 0 0\n"
                            "MouseMoveEvent 42 80 0 0 0 0 0\n"
                            "RenderEvent 42 80 0 0 0 0 0\n"
                            "MouseMoveEvent 42 79 0 0 0 0 0\n"
                            "RenderEvent 42 79 0 0 0 0 0\n"
                            "MouseMoveEvent 41 77 0 0 0 0 0\n"
                            "RenderEvent 41 77 0 0 0 0 0\n"
                            "MouseMoveEvent 41 76 0 0 0 0 0\n"
                            "RenderEvent 41 76 0 0 0 0 0\n"
                            "MouseMoveEvent 41 75 0 0 0 0 0\n"
                            "RenderEvent 41 75 0 0 0 0 0\n"
                            "MouseMoveEvent 40 73 0 0 0 0 0\n"
                            "RenderEvent 40 73 0 0 0 0 0\n"
                            "MouseMoveEvent 40 71 0 0 0 0 0\n"
                            "RenderEvent 40 71 0 0 0 0 0\n"
                            "MouseMoveEvent 39 69 0 0 0 0 0\n"
                            "RenderEvent 39 69 0 0 0 0 0\n"
                            "MouseMoveEvent 39 67 0 0 0 0 0\n"
                            "RenderEvent 39 67 0 0 0 0 0\n"
                            "MouseMoveEvent 38 65 0 0 0 0 0\n"
                            "RenderEvent 38 65 0 0 0 0 0\n"
                            "MouseMoveEvent 38 63 0 0 0 0 0\n"
                            "RenderEvent 38 63 0 0 0 0 0\n"
                            "MouseMoveEvent 37 60 0 0 0 0 0\n"
                            "RenderEvent 37 60 0 0 0 0 0\n"
                            "MouseMoveEvent 37 58 0 0 0 0 0\n"
                            "RenderEvent 37 58 0 0 0 0 0\n"
                            "MouseMoveEvent 37 57 0 0 0 0 0\n"
                            "RenderEvent 37 57 0 0 0 0 0\n"
                            "MouseMoveEvent 36 55 0 0 0 0 0\n"
                            "RenderEvent 36 55 0 0 0 0 0\n"
                            "MouseMoveEvent 36 54 0 0 0 0 0\n"
                            "RenderEvent 36 54 0 0 0 0 0\n"
                            "MouseMoveEvent 35 52 0 0 0 0 0\n"
                            "RenderEvent 35 52 0 0 0 0 0\n"
                            "MouseMoveEvent 35 51 0 0 0 0 0\n"
                            "RenderEvent 35 51 0 0 0 0 0\n"
                            "MouseMoveEvent 35 50 0 0 0 0 0\n"
                            "RenderEvent 35 50 0 0 0 0 0\n"
                            "MouseMoveEvent 34 48 0 0 0 0 0\n"
                            "RenderEvent 34 48 0 0 0 0 0\n"
                            "MouseMoveEvent 34 46 0 0 0 0 0\n"
                            "RenderEvent 34 46 0 0 0 0 0\n"
                            "MouseMoveEvent 33 44 0 0 0 0 0\n"
                            "RenderEvent 33 44 0 0 0 0 0\n"
                            "MouseMoveEvent 33 43 0 0 0 0 0\n"
                            "RenderEvent 33 43 0 0 0 0 0\n"
                            "MouseMoveEvent 33 42 0 0 0 0 0\n"
                            "RenderEvent 33 42 0 0 0 0 0\n"
                            "MouseMoveEvent 32 41 0 0 0 0 0\n"
                            "RenderEvent 32 41 0 0 0 0 0\n"
                            "MouseMoveEvent 32 40 0 0 0 0 0\n"
                            "RenderEvent 32 40 0 0 0 0 0\n"
                            "MouseMoveEvent 32 39 0 0 0 0 0\n"
                            "RenderEvent 32 39 0 0 0 0 0\n"
                            "MouseMoveEvent 32 38 0 0 0 0 0\n"
                            "RenderEvent 32 38 0 0 0 0 0\n"
                            "MouseMoveEvent 31 37 0 0 0 0 0\n"
                            "RenderEvent 31 37 0 0 0 0 0\n"
                            "MouseMoveEvent 31 36 0 0 0 0 0\n"
                            "RenderEvent 31 36 0 0 0 0 0\n"
                            "MouseMoveEvent 30 36 0 0 0 0 0\n"
                            "RenderEvent 30 36 0 0 0 0 0\n"
                            "MouseMoveEvent 30 35 0 0 0 0 0\n"
                            "RenderEvent 30 35 0 0 0 0 0\n"
                            "MouseMoveEvent 30 35 0 0 0 0 0\n"
                            "RenderEvent 30 35 0 0 0 0 0\n"
                            "LeftButtonReleaseEvent 30 35 0 0 0 0 0\n"
                            "RenderEvent 30 35 0 0 0 0 0\n"
                            "MouseMoveEvent 30 35 0 0 0 0 0\n"
                            "RenderEvent 30 35 0 0 0 0 0\n"
                            "MouseMoveEvent 31 33 0 0 0 0 0\n"
                            "MouseMoveEvent 35 27 0 0 0 0 0\n"
                            "RenderEvent 35 27 0 0 0 0 0\n"
                            "MouseMoveEvent 41 18 0 0 0 0 0\n"
                            "MouseMoveEvent 44 11 0 0 0 0 0\n"
                            "MouseMoveEvent 48 6 0 0 0 0 0\n"
                            "MouseMoveEvent 51 0 0 0 0 0 0\n"
                            "LeaveEvent 55 -6 0 0 0 0 0\n";

// Callback for the interaction
class vtkOrientationCallback : public vtkCommand
{
public:
  static vtkOrientationCallback* New() { return new vtkOrientationCallback; }
  void Execute(vtkObject* caller, unsigned long, void*) override
  {
    vtkOrientationWidget* widget = reinterpret_cast<vtkOrientationWidget*>(caller);
    vtkOrientationRepresentation* repr =
      reinterpret_cast<vtkOrientationRepresentation*>(widget->GetRepresentation());
    this->Actor->SetOrientation(repr->GetOrientation());
  }

  vtkActor* Actor = nullptr;
};

int TestOrientationWidget(int, char*[])
{
  // Create source, mapper and actor
  vtkNew<vtkCubeSource> cubeSource;
  vtkNew<vtkPolyDataMapper> cubeMapper;
  cubeMapper->SetInputConnection(cubeSource->GetOutputPort());
  vtkNew<vtkActor> cubeActor;
  cubeActor->SetMapper(cubeMapper);

  // Setup renderer and render window
  vtkNew<vtkRenderer> renderer;
  renderer->AddActor(cubeActor);
  renderer->SetBackground(0.7, 0.7, 1.0);
  renderer->GetActiveCamera()->SetPosition(1.0, 1.0, -4.0);

  vtkNew<vtkRenderWindow> renderWindow;
  renderWindow->SetSize(300, 300);
  renderWindow->AddRenderer(renderer);
  renderWindow->SetWindowName("orientationWidget");

  // An interactor
  vtkNew<vtkInteractorStyleTrackballCamera> style;
  vtkNew<vtkRenderWindowInteractor> renderWindowInteractor;
  renderWindowInteractor->SetRenderWindow(renderWindow);
  renderWindowInteractor->SetInteractorStyle(style);

  // Callback to sync object and widget
  vtkSmartPointer<vtkOrientationCallback> myCallback =
    vtkSmartPointer<vtkOrientationCallback>::New();
  myCallback->Actor = cubeActor;

  // Camera widget and its representation
  vtkNew<vtkOrientationRepresentation> orientationRepresentation;
  vtkNew<vtkOrientationWidget> orientationWidget;
  orientationWidget->SetInteractor(renderWindowInteractor);
  orientationWidget->SetRepresentation(orientationRepresentation);
  orientationWidget->AddObserver(vtkCommand::InteractionEvent, myCallback);
  orientationRepresentation->PlaceWidget(cubeActor->GetBounds());

  orientationRepresentation->ShowArrowsOn();
  orientationRepresentation->SetArrowDistance(0.05);
  orientationRepresentation->SetArrowLength(0.1);
  orientationRepresentation->SetArrowTipLength(0.35);
  orientationRepresentation->SetArrowTipRadius(0.03);
  orientationRepresentation->SetArrowShaftRadius(0.01);

  orientationRepresentation->GetPropertyX(false)->SetColor(1.0, 0.0, 1.0);
  orientationRepresentation->GetPropertyY(true)->SetColor(1.0, 1.0, 0.0);
  vtkNew<vtkProperty> propertyZ;
  propertyZ->SetColor(0.0, 1.0, 1.0);
  orientationRepresentation->SetPropertyZ(false, propertyZ);

  // Render
  renderWindowInteractor->Initialize();
  renderWindow->Render();
  orientationWidget->On();

  vtkNew<vtkInteractorEventRecorder> recorder;
  recorder->SetInteractor(renderWindowInteractor);
#if 0
  recorder->SetFileName("./record.log");
  recorder->Record();
  recorder->On();
#else
  recorder->ReadFromInputStringOn();
  recorder->SetInputString(eventLog);
  recorder->Play();
#endif

  // Begin mouse interaction
  renderWindowInteractor->Start();
  recorder->Stop();

  return EXIT_SUCCESS;
}
