comparison Framework/Viewport/SdlViewport.h @ 1213:86a8266b8888 broker

moving the scene from IViewport to ViewportController
author Sebastien Jodogne <s.jodogne@gmail.com>
date Wed, 04 Dec 2019 17:54:10 +0100
parents 6009c59d8676
children 9efa66d8d3f8
comparison
equal deleted inserted replaced
1212:ab06dfdf3b75 1213:86a8266b8888
106 unsigned int height, 106 unsigned int height,
107 bool allowDpiScaling = true); 107 bool allowDpiScaling = true);
108 108
109 virtual void Invalidate() ORTHANC_OVERRIDE; 109 virtual void Invalidate() ORTHANC_OVERRIDE;
110 110
111 virtual void Paint() ORTHANC_OVERRIDE; 111 virtual void Paint(const Scene2D& scene) ORTHANC_OVERRIDE;
112 112
113 virtual ILock* Lock() ORTHANC_OVERRIDE 113 virtual ILock* Lock() ORTHANC_OVERRIDE
114 { 114 {
115 return new SdlLock(*this); 115 return new SdlLock(*this);
116 } 116 }
159 boost::mutex mutex_; 159 boost::mutex mutex_;
160 SdlWindow window_; 160 SdlWindow window_;
161 CairoCompositor compositor_; 161 CairoCompositor compositor_;
162 SDL_Surface* sdlSurface_; 162 SDL_Surface* sdlSurface_;
163 163
164 void InvalidateInternal();
165
166 void CreateSdlSurfaceFromCompositor(); 164 void CreateSdlSurfaceFromCompositor();
167 165
168 public: 166 public:
169 SdlCairoViewport(const char* title, 167 SdlCairoViewport(const char* title,
170 unsigned int width, 168 unsigned int width,
173 171
174 ~SdlCairoViewport(); 172 ~SdlCairoViewport();
175 173
176 virtual void Invalidate() ORTHANC_OVERRIDE; 174 virtual void Invalidate() ORTHANC_OVERRIDE;
177 175
178 virtual void Paint() ORTHANC_OVERRIDE; 176 virtual void Paint(const Scene2D& scene) ORTHANC_OVERRIDE;
179 177
180 virtual ILock* Lock() ORTHANC_OVERRIDE 178 virtual ILock* Lock() ORTHANC_OVERRIDE
181 { 179 {
182 return new SdlLock(*this); 180 return new SdlLock(*this);
183 } 181 }