| 1 | /* $Id: teximage.h,v 1.1 2000-02-29 00:48:39 sandervl Exp $ */ | 
|---|
| 2 |  | 
|---|
| 3 | /* | 
|---|
| 4 | * Mesa 3-D graphics library | 
|---|
| 5 | * Version:  3.1 | 
|---|
| 6 | * | 
|---|
| 7 | * Copyright (C) 1999  Brian Paul   All Rights Reserved. | 
|---|
| 8 | * | 
|---|
| 9 | * Permission is hereby granted, free of charge, to any person obtaining a | 
|---|
| 10 | * copy of this software and associated documentation files (the "Software"), | 
|---|
| 11 | * to deal in the Software without restriction, including without limitation | 
|---|
| 12 | * the rights to use, copy, modify, merge, publish, distribute, sublicense, | 
|---|
| 13 | * and/or sell copies of the Software, and to permit persons to whom the | 
|---|
| 14 | * Software is furnished to do so, subject to the following conditions: | 
|---|
| 15 | * | 
|---|
| 16 | * The above copyright notice and this permission notice shall be included | 
|---|
| 17 | * in all copies or substantial portions of the Software. | 
|---|
| 18 | * | 
|---|
| 19 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS | 
|---|
| 20 | * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | 
|---|
| 21 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL | 
|---|
| 22 | * BRIAN PAUL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN | 
|---|
| 23 | * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN | 
|---|
| 24 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | 
|---|
| 25 | */ | 
|---|
| 26 |  | 
|---|
| 27 |  | 
|---|
| 28 | #ifndef TEXIMAGE_H | 
|---|
| 29 | #define TEXIMAGE_H | 
|---|
| 30 |  | 
|---|
| 31 |  | 
|---|
| 32 | #include "types.h" | 
|---|
| 33 |  | 
|---|
| 34 |  | 
|---|
| 35 | /*** Internal functions ***/ | 
|---|
| 36 |  | 
|---|
| 37 |  | 
|---|
| 38 | extern struct gl_texture_image *gl_alloc_texture_image( void ); | 
|---|
| 39 |  | 
|---|
| 40 |  | 
|---|
| 41 | extern void gl_free_texture_image( struct gl_texture_image *teximage ); | 
|---|
| 42 |  | 
|---|
| 43 |  | 
|---|
| 44 |  | 
|---|
| 45 |  | 
|---|
| 46 | /*** API entry points ***/ | 
|---|
| 47 |  | 
|---|
| 48 |  | 
|---|
| 49 | extern void gl_TexImage1D( GLcontext *ctx, | 
|---|
| 50 | GLenum target, GLint level, GLint internalformat, | 
|---|
| 51 | GLsizei width, GLint border, GLenum format, | 
|---|
| 52 | GLenum type, const GLvoid *pixels ); | 
|---|
| 53 |  | 
|---|
| 54 |  | 
|---|
| 55 | extern void gl_TexImage2D( GLcontext *ctx, | 
|---|
| 56 | GLenum target, GLint level, GLint internalformat, | 
|---|
| 57 | GLsizei width, GLsizei height, GLint border, | 
|---|
| 58 | GLenum format, GLenum type, | 
|---|
| 59 | const GLvoid *pixels ); | 
|---|
| 60 |  | 
|---|
| 61 |  | 
|---|
| 62 | extern void gl_TexImage3D( GLcontext *ctx, | 
|---|
| 63 | GLenum target, GLint level, GLint internalformat, | 
|---|
| 64 | GLsizei width, GLsizei height, GLsizei depth, | 
|---|
| 65 | GLint border, GLenum format, GLenum type, | 
|---|
| 66 | const GLvoid *pixels ); | 
|---|
| 67 |  | 
|---|
| 68 |  | 
|---|
| 69 | extern void gl_GetTexImage( GLcontext *ctx, GLenum target, GLint level, | 
|---|
| 70 | GLenum format, GLenum type, GLvoid *pixels ); | 
|---|
| 71 |  | 
|---|
| 72 |  | 
|---|
| 73 |  | 
|---|
| 74 | extern void gl_TexSubImage1D( GLcontext *ctx, | 
|---|
| 75 | GLenum target, GLint level, GLint xoffset, | 
|---|
| 76 | GLsizei width, GLenum format, GLenum type, | 
|---|
| 77 | const GLvoid *pixels ); | 
|---|
| 78 |  | 
|---|
| 79 |  | 
|---|
| 80 | extern void gl_TexSubImage2D( GLcontext *ctx, | 
|---|
| 81 | GLenum target, GLint level, | 
|---|
| 82 | GLint xoffset, GLint yoffset, | 
|---|
| 83 | GLsizei width, GLsizei height, | 
|---|
| 84 | GLenum format, GLenum type, | 
|---|
| 85 | const GLvoid *pixels ); | 
|---|
| 86 |  | 
|---|
| 87 |  | 
|---|
| 88 | extern void gl_TexSubImage3D( GLcontext *ctx, | 
|---|
| 89 | GLenum target, GLint level, | 
|---|
| 90 | GLint xoffset, GLint yoffset, GLint zoffset, | 
|---|
| 91 | GLsizei width, GLsizei height, GLsizei depth, | 
|---|
| 92 | GLenum format, GLenum type, | 
|---|
| 93 | const GLvoid *pixels ); | 
|---|
| 94 |  | 
|---|
| 95 |  | 
|---|
| 96 | extern void gl_CopyTexImage1D( GLcontext *ctx, | 
|---|
| 97 | GLenum target, GLint level, | 
|---|
| 98 | GLenum internalformat, | 
|---|
| 99 | GLint x, GLint y, | 
|---|
| 100 | GLsizei width, GLint border ); | 
|---|
| 101 |  | 
|---|
| 102 |  | 
|---|
| 103 | extern void gl_CopyTexImage2D( GLcontext *ctx, | 
|---|
| 104 | GLenum target, GLint level, | 
|---|
| 105 | GLenum internalformat, GLint x, GLint y, | 
|---|
| 106 | GLsizei width, GLsizei height, | 
|---|
| 107 | GLint border ); | 
|---|
| 108 |  | 
|---|
| 109 |  | 
|---|
| 110 | extern void gl_CopyTexSubImage1D( GLcontext *ctx, | 
|---|
| 111 | GLenum target, GLint level, | 
|---|
| 112 | GLint xoffset, GLint x, GLint y, | 
|---|
| 113 | GLsizei width ); | 
|---|
| 114 |  | 
|---|
| 115 |  | 
|---|
| 116 | extern void gl_CopyTexSubImage2D( GLcontext *ctx, | 
|---|
| 117 | GLenum target, GLint level, | 
|---|
| 118 | GLint xoffset, GLint yoffset, | 
|---|
| 119 | GLint x, GLint y, | 
|---|
| 120 | GLsizei width, GLsizei height ); | 
|---|
| 121 |  | 
|---|
| 122 |  | 
|---|
| 123 | extern void gl_CopyTexSubImage3D( GLcontext *ctx, | 
|---|
| 124 | GLenum target, GLint level, | 
|---|
| 125 | GLint xoffset, GLint yoffset, | 
|---|
| 126 | GLint zoffset, | 
|---|
| 127 | GLint x, GLint y, | 
|---|
| 128 | GLsizei width, GLsizei height ); | 
|---|
| 129 |  | 
|---|
| 130 | #endif | 
|---|
| 131 |  | 
|---|