Debian Codegraph @

src/deprecated_units/castleglcontainer.pas

raw
1 {
2 Copyright 2009-2018 Michalis Kamburelis.
3
4 This file is part of "Castle Game Engine".
5
6 "Castle Game Engine" is free software; see the file COPYING.txt,
7 included in this distribution, for details about the copyright.
8
9 "Castle Game Engine" is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
12
13 ----------------------------------------------------------------------------
14 }
15
16 { Container for 2D controls able to render using OpenGL (TGLContainer). }
17 unit CastleGLContainer deprecated 'everything from this unit is now in CastleUIControls';
18
19 {$I castleconf.inc}
20
21 interface
22
23 uses Classes,
24 CastleUIControls, CastleRectangles, CastleColors, CastleImages;
25
26 type
27 TGLContainer = TCastleContainer
28 deprecated 'use TCastleContainer from CastleUIControls unit, no need to use CastleGLContainer unit';
29
30 function RenderControlToImage(const Container: TGLContainer;
31 const Control: TCastleUserInterface;
32 const ViewportRect: TRectangle;
33 const BackgroundColor: TCastleColor): TRGBAlphaImage;
34 deprecated 'use RenderControlToImage from CastleUIControls unit, no need to use CastleGLContainer unit';
35
36 implementation
37
38 { global routines ------------------------------------------------------------ }
39
40 function RenderControlToImage(const Container: TGLContainer;
41 const Control: TCastleUserInterface;
42 const ViewportRect: TRectangle;
43 const BackgroundColor: TCastleColor): TRGBAlphaImage;
44 begin
45 Result := CastleUIControls.RenderControlToImage(
46 Container, Control, ViewportRect, BackgroundColor);
47 end;
48
49 end.