Mercurial > hg > orthanc-stone
diff Framework/Scene2D/OpenGLCompositor.cpp @ 1299:c38c89684d83 broker
replacing std::auto_ptr by std::unique_ptr
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Mon, 02 Mar 2020 17:21:24 +0100 |
parents | 7ec8fea061b9 |
children | 257f2c9a02ac |
line wrap: on
line diff
--- a/Framework/Scene2D/OpenGLCompositor.cpp Sun Feb 23 15:32:24 2020 +0100 +++ b/Framework/Scene2D/OpenGLCompositor.cpp Mon Mar 02 17:21:24 2020 +0100 @@ -33,8 +33,8 @@ class OpenGLCompositor::Font : public boost::noncopyable { private: - std::auto_ptr<GlyphTextureAlphabet> alphabet_; - std::auto_ptr<OpenGL::OpenGLTexture> texture_; + std::unique_ptr<GlyphTextureAlphabet> alphabet_; + std::unique_ptr<OpenGL::OpenGLTexture> texture_; public: Font(OpenGL::IOpenGLContext& context, const GlyphBitmapAlphabet& dict) @@ -42,7 +42,7 @@ alphabet_.reset(new GlyphTextureAlphabet(dict)); texture_.reset(new OpenGL::OpenGLTexture(context)); - std::auto_ptr<Orthanc::ImageAccessor> bitmap(alphabet_->ReleaseTexture()); + std::unique_ptr<Orthanc::ImageAccessor> bitmap(alphabet_->ReleaseTexture()); texture_->Load(*bitmap, true /* enable linear interpolation */); } @@ -185,7 +185,7 @@ { context_.MakeCurrent(); // this can throw if context lost - std::auto_ptr<Font> font(new Font(context_, dict)); + std::unique_ptr<Font> font(new Font(context_, dict)); Fonts::iterator found = fonts_.find(index);