git.ucc.asn.au
/
ipdf
/
code.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
// there is no elegance here. only sleep deprivation and regret.
[ipdf/code.git]
/
src
/
graphicsbuffer.h
diff --git
a/src/graphicsbuffer.h
b/src/graphicsbuffer.h
index
3dbb6fb
..
4053f90
100644
(file)
--- a/
src/graphicsbuffer.h
+++ b/
src/graphicsbuffer.h
@@
-1,7
+1,7
@@
#ifndef _GRAPHICSBUFFER_H
#define _GRAPHICSBUFFER_H
#ifndef _GRAPHICSBUFFER_H
#define _GRAPHICSBUFFER_H
-#include
<SDL.h>
+#include
"SDL.h"
#include "gl_core44.h"
#include "gl_core44.h"
@@
-21,7
+21,7
@@
namespace IPDF
BufferTypePixelUnpack,
BufferTypeUniform, // Uniform/Constant buffer
BufferTypeTexture, // I was hoping to avoid this one.
BufferTypePixelUnpack,
BufferTypeUniform, // Uniform/Constant buffer
BufferTypeTexture, // I was hoping to avoid this one.
- BufferTypeDrawIndirect
,
+ BufferTypeDrawIndirect
};
enum BufferUsage
};
enum BufferUsage
@@
-40,6
+40,7
@@
namespace IPDF
GraphicsBuffer();
~GraphicsBuffer();
GraphicsBuffer();
~GraphicsBuffer();
+ void SetName(const char *name);
void SetType(BufferType bufType);
void SetUsage(BufferUsage bufUsage);
void SetType(BufferType bufType);
void SetUsage(BufferUsage bufUsage);
@@
-63,8
+64,9
@@
namespace IPDF
GLuint GetHandle() const { return m_buffer_handle; }
void Bind() const;
GLuint GetHandle() const { return m_buffer_handle; }
void Bind() const;
+ void BindRange(size_t start, size_t size) const;
private:
private:
- bool RecreateBuffer(const void *data =
nullptr
);
+ bool RecreateBuffer(const void *data =
NULL
);
GLuint m_buffer_handle;
BufferType m_buffer_type;
BufferUsage m_buffer_usage;
GLuint m_buffer_handle;
BufferType m_buffer_type;
BufferUsage m_buffer_usage;
@@
-73,6
+75,7
@@
namespace IPDF
bool m_invalidated;
bool m_buffer_shape_dirty;
bool m_faking_map;
bool m_invalidated;
bool m_buffer_shape_dirty;
bool m_faking_map;
+ const char *m_name;
};
}
};
}
UCC
git Repository :: git.ucc.asn.au