OpenMoHAA 0.82.0
Loading...
Searching...
No Matches
tr_fbo.h
1/*
2===========================================================================
3Copyright (C) 2010 James Canete (use.less01@gmail.com)
4
5This file is part of Quake III Arena source code.
6
7Quake III Arena source code is free software; you can redistribute it
8and/or modify it under the terms of the GNU General Public License as
9published by the Free Software Foundation; either version 2 of the License,
10or (at your option) any later version.
11
12Quake III Arena source code is distributed in the hope that it will be
13useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
14MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15GNU General Public License for more details.
16
17You should have received a copy of the GNU General Public License
18along with Quake III Arena source code; if not, write to the Free Software
19Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
20===========================================================================
21*/
22// tr_fbo.h
23
24#ifndef __TR_FBO_H__
25#define __TR_FBO_H__
26
27struct image_s;
28struct shaderProgram_s;
29
30typedef struct FBO_s
31{
32 char name[MAX_QPATH];
33
34 int index;
35
36 uint32_t frameBuffer;
37
38 uint32_t colorBuffers[16];
39 int colorFormat;
40 struct image_s *colorImage[16];
41
42 uint32_t depthBuffer;
43 int depthFormat;
44
45 uint32_t stencilBuffer;
46 int stencilFormat;
47
48 uint32_t packedDepthStencilBuffer;
49 int packedDepthStencilFormat;
50
51 int width;
52 int height;
53} FBO_t;
54
55void FBO_AttachImage(FBO_t *fbo, image_t *image, GLenum attachment, GLuint cubemapside);
56void FBO_Bind(FBO_t *fbo);
57void FBO_Init(void);
58void FBO_Shutdown(void);
59
60void FBO_BlitFromTexture(struct image_s *src, vec4_t inSrcTexCorners, vec2_t inSrcTexScale, FBO_t *dst, ivec4_t inDstBox, struct shaderProgram_s *shaderProgram, vec4_t inColor, int blend);
61void FBO_Blit(FBO_t *src, ivec4_t srcBox, vec2_t srcTexScale, FBO_t *dst, ivec4_t dstBox, struct shaderProgram_s *shaderProgram, vec4_t color, int blend);
62void FBO_FastBlit(FBO_t *src, ivec4_t srcBox, FBO_t *dst, ivec4_t dstBox, int buffers, int filter);
63
64
65#endif
Definition tr_fbo.h:31
Definition tr_common.h:53
Definition tr_local.h:849