LibreOffice Module canvas (master)  1
ogl_canvasbitmap.hxx
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3  * This file is part of the LibreOffice project.
4  *
5  * This Source Code Form is subject to the terms of the Mozilla Public
6  * License, v. 2.0. If a copy of the MPL was not distributed with this
7  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8  */
9 
10 #pragma once
11 
12 #include <cppuhelper/compbase.hxx>
13 
14 #include <com/sun/star/rendering/XBitmapCanvas.hpp>
15 #include <com/sun/star/rendering/XIntegerBitmap.hpp>
16 
18 #include <base/basemutexhelper.hxx>
20 
22 #include "ogl_spritecanvas.hxx"
23 
24 
25 /* Definition of CanvasBitmap class */
26 
27 namespace oglcanvas
28 {
29  typedef ::cppu::WeakComponentImplHelper< css::rendering::XBitmapCanvas,
30  css::rendering::XIntegerBitmap > CanvasBitmapBase_Base;
31  typedef ::canvas::IntegerBitmapBase<
35  ::osl::MutexGuard,
37 
38  class CanvasBitmap : public CanvasBitmapBaseT
39  {
40  public:
49  CanvasBitmap( const css::geometry::IntegerSize2D& rSize,
50  const SpriteCanvasRef& rDevice,
51  SpriteDeviceHelper& rDeviceHelper );
52 
55  CanvasBitmap( const CanvasBitmap& rSrc );
56 
58  virtual void disposeThis() override;
59 
62  bool renderRecordedActions() const;
63 
64  private:
69  };
70 }
71 
72 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
::canvas::IntegerBitmapBase< canvas::BitmapCanvasBase2< ::canvas::BaseMutexHelper< CanvasBitmapBase_Base >, BitmapCanvasHelper,::osl::MutexGuard,::cppu::OWeakObject > > CanvasBitmapBaseT
SpriteCanvasRef mpDevice
MUST hold here, too, since CanvasHelper only contains a raw pointer (without refcounting) ...
::cppu::WeakComponentImplHelper< css::rendering::XBitmapCanvas, css::rendering::XIntegerBitmap > CanvasBitmapBase_Base
Helper class for basic canvas functionality.
CanvasBitmap(const css::geometry::IntegerSize2D &rSize, const SpriteCanvasRef &rDevice, SpriteDeviceHelper &rDeviceHelper)
Create a canvas bitmap for the given surface.
virtual void disposeThis() override
Dispose all internal references.
bool renderRecordedActions() const
Write out recorded actions.