Main Page
Namespaces
Classes
Files
File List
File Members
include
Graphics
GL4
GteGL4Buffer.h
Go to the documentation of this file.
1
// David Eberly, Geometric Tools, Redmond WA 98052
2
// Copyright (c) 1998-2017
3
// Distributed under the Boost Software License, Version 1.0.
4
// http://www.boost.org/LICENSE_1_0.txt
5
// http://www.geometrictools.com/License/Boost/LICENSE_1_0.txt
6
// File Version: 3.0.0 (2016/06/19)
7
8
#pragma once
9
10
#include <
Graphics/GteBuffer.h
>
11
#include <
Graphics/GL4/GteGL4Resource.h
>
12
13
namespace
gte
14
{
15
16
class
GTE_IMPEXP
GL4Buffer
:
public
GL4Resource
17
{
18
protected
:
19
// Abstract base class.
20
virtual
~
GL4Buffer
();
21
GL4Buffer
(
Buffer
const
*
buffer
,
GLenum
type
);
22
23
// Must be called by constructor.
24
virtual
void
Initialize();
25
26
public
:
27
// Member access.
28
inline
Buffer
* GetBuffer()
const
;
29
inline
GLenum
GetType()
const
;
30
inline
GLenum
GetUsage()
const
;
31
32
// TODO: TENTATIVE INTERFACE (modify as needed). Do we really need
33
// these to be virtual? Revisit the DX11 code and investigate why the
34
// choice was made there.
35
virtual
bool
Update();
36
virtual
bool
CopyCpuToGpu();
37
virtual
bool
CopyGpuToCpu();
38
39
protected
:
40
GLenum
mType
;
41
GLenum
mUsage
;
42
};
43
44
inline
Buffer
*
GL4Buffer::GetBuffer
()
const
45
{
46
return
static_cast<
Buffer
*
>
(mGTObject);
47
}
48
49
inline
GLenum
GL4Buffer::GetType
()
const
50
{
51
return
mType;
52
}
53
54
inline
GLenum
GL4Buffer::GetUsage
()
const
55
{
56
return
mUsage;
57
}
58
59
}
GteBuffer.h
gte::GL4Buffer
Definition:
GteGL4Buffer.h:16
gte::GL4Buffer::mUsage
GLenum mUsage
Definition:
GteGL4Buffer.h:41
gte::GL4Buffer::GetUsage
GLenum GetUsage() const
Definition:
GteGL4Buffer.h:54
gte::GL4Buffer::GetBuffer
Buffer * GetBuffer() const
Definition:
GteGL4Buffer.h:44
gte::GL4Resource
Definition:
GteGL4Resource.h:17
GLenum
unsigned int GLenum
Definition:
glcorearb.h:83
gte
Definition:
GLX/GteWICFileIO.h:16
GteGL4Resource.h
gte::Buffer
Definition:
GteBuffer.h:16
gte::GL4Buffer::mType
GLenum mType
Definition:
GteGL4Buffer.h:40
gte::GL4Buffer::GetType
GLenum GetType() const
Definition:
GteGL4Buffer.h:49
buffer
GLuint buffer
Definition:
glcorearb.h:655
GTE_IMPEXP
#define GTE_IMPEXP
Definition:
GTEngineDEF.h:63
type
GLint GLint GLsizei GLint GLenum GLenum type
Definition:
glcorearb.h:103
geometric_tools_engine
Author(s): Yijiang Huang
autogenerated on Thu Jul 18 2019 04:00:00