[Mesa-dev] [PATCH 6/8] i965/upload: Drop use of GL types.
Kenneth Graunke
kenneth at whitecape.org
Thu Mar 13 01:57:14 PDT 2014
Using GL types outside of the GL API is silly.
Signed-off-by: Kenneth Graunke <kenneth at whitecape.org>
---
src/mesa/drivers/dri/i965/intel_buffer_objects.h | 10 +++++-----
src/mesa/drivers/dri/i965/intel_upload.c | 18 +++++++++---------
2 files changed, 14 insertions(+), 14 deletions(-)
diff --git a/src/mesa/drivers/dri/i965/intel_buffer_objects.h b/src/mesa/drivers/dri/i965/intel_buffer_objects.h
index 2197707..a132408 100644
--- a/src/mesa/drivers/dri/i965/intel_buffer_objects.h
+++ b/src/mesa/drivers/dri/i965/intel_buffer_objects.h
@@ -85,16 +85,16 @@ drm_intel_bo *intel_bufferobj_buffer(struct brw_context *brw,
uint32_t size);
void intel_upload_data(struct brw_context *brw,
- const void *ptr, GLuint size, GLuint align,
+ const void *ptr, unsigned size, unsigned align,
drm_intel_bo **return_bo,
- GLuint *return_offset);
+ unsigned *return_offset);
void *intel_upload_map(struct brw_context *brw,
- GLuint size, GLuint align);
+ unsigned size, unsigned align);
void intel_upload_unmap(struct brw_context *brw,
- const void *ptr, GLuint size, GLuint align,
+ const void *ptr, unsigned size, unsigned align,
drm_intel_bo **return_bo,
- GLuint *return_offset);
+ unsigned *return_offset);
void intel_upload_finish(struct brw_context *brw);
diff --git a/src/mesa/drivers/dri/i965/intel_upload.c b/src/mesa/drivers/dri/i965/intel_upload.c
index c767b7d..f6342c9 100644
--- a/src/mesa/drivers/dri/i965/intel_upload.c
+++ b/src/mesa/drivers/dri/i965/intel_upload.c
@@ -96,7 +96,7 @@ intel_upload_finish(struct brw_context *brw)
* data, and allocate a new BO.
*/
static void
-wrap_buffers(struct brw_context *brw, GLuint size)
+wrap_buffers(struct brw_context *brw, unsigned size)
{
intel_upload_finish(brw);
@@ -123,11 +123,11 @@ wrap_buffers(struct brw_context *brw, GLuint size)
*/
void
intel_upload_data(struct brw_context *brw,
- const void *ptr, GLuint size, GLuint align,
+ const void *ptr, unsigned size, unsigned align,
drm_intel_bo **return_bo,
- GLuint *return_offset)
+ unsigned *return_offset)
{
- GLuint base, delta;
+ unsigned base, delta;
/* Make sure the BO has enough space for this data. */
base = ALIGN_NPOT(brw->upload.offset, align);
@@ -200,9 +200,9 @@ intel_upload_data(struct brw_context *brw,
* It is an (unchecked) error to mismatch calls to map/unmap.
*/
void *
-intel_upload_map(struct brw_context *brw, GLuint size, GLuint align)
+intel_upload_map(struct brw_context *brw, unsigned size, unsigned align)
{
- GLuint base, delta;
+ unsigned base, delta;
char *ptr;
/* Make sure the BO has enough space for this data. */
@@ -262,11 +262,11 @@ intel_upload_map(struct brw_context *brw, GLuint size, GLuint align)
*/
void
intel_upload_unmap(struct brw_context *brw,
- const void *ptr, GLuint size, GLuint align,
+ const void *ptr, unsigned size, unsigned align,
drm_intel_bo **return_bo,
- GLuint *return_offset)
+ unsigned *return_offset)
{
- GLuint base;
+ unsigned base;
base = ALIGN_NPOT(brw->upload.offset, align);
if (size > sizeof(brw->upload.buffer)) {
--
1.9.0
More information about the mesa-dev
mailing list