2
* Copyright © 2015 Canonical Ltd.
4
* This program is free software: you can redistribute it and/or modify it
5
* under the terms of the GNU Lesser General Public License version 3,
6
* as published by the Free Software Foundation.
8
* This program is distributed in the hope that it will be useful,
9
* but WITHOUT ANY WARRANTY; without even the implied warranty of
10
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11
* GNU Lesser General Public License for more details.
13
* You should have received a copy of the GNU Lesser General Public License
14
* along with this program. If not, see <http://www.gnu.org/licenses/>.
16
* Authored by: Alexandros Frantzis <alexandros.frantzis@canonical.com>
19
#ifndef MIR_RENDERER_GL_RENDER_TARGET_H_
20
#define MIR_RENDERER_GL_RENDER_TARGET_H_
32
virtual ~RenderTarget() = default;
34
/** Makes the the current GL render target. */
35
virtual void make_current() = 0;
36
/** Releases the current GL render target. */
37
virtual void release_current() = 0;
39
* Swap buffers for OpenGL rendering.
40
* After this method returns is the earliest time that it is safe to
41
* free GL-related resources such as textures and buffers.
43
virtual void swap_buffers() = 0;
46
RenderTarget() = default;
47
RenderTarget(RenderTarget const&) = delete;
48
RenderTarget& operator=(RenderTarget const&) = delete;