diff options
author | Brian <[email protected]> | 2007-09-17 15:44:59 -0600 |
---|---|---|
committer | Brian <[email protected]> | 2007-09-17 15:44:59 -0600 |
commit | ffacb1c12a77d71613e8171e31ffc348959881e4 (patch) | |
tree | 323bcc897c2c349d0f5a49b6311e6351d1da7deb | |
parent | b4bacd1fca336f043d1ee3c3a346fbd42a3b02eb (diff) |
Replace GL_TEXTURE_* tokens with PIPE_TEXTURE_*
Must have missed this a while back. This fixes cube mapping.
-rw-r--r-- | src/mesa/state_tracker/st_mipmap_tree.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/mesa/state_tracker/st_mipmap_tree.c b/src/mesa/state_tracker/st_mipmap_tree.c index 535004c892f..1764bc61f3f 100644 --- a/src/mesa/state_tracker/st_mipmap_tree.c +++ b/src/mesa/state_tracker/st_mipmap_tree.c @@ -180,18 +180,22 @@ st_miptree_depth_offsets(struct pipe_mipmap_tree *mt, GLuint level) { static const GLuint zero = 0; - if (mt->target != GL_TEXTURE_3D || mt->level[level].nr_images == 1) + if (mt->target != PIPE_TEXTURE_3D || mt->level[level].nr_images == 1) return &zero; else return mt->level[level].image_offset; } +/** + * Return the offset to the given mipmap texture image within the + * texture memory buffer, in bytes. + */ GLuint st_miptree_image_offset(const struct pipe_mipmap_tree * mt, GLuint face, GLuint level) { - if (mt->target == GL_TEXTURE_CUBE_MAP_ARB) + if (mt->target == PIPE_TEXTURE_CUBE) return (mt->level[level].level_offset + mt->level[level].image_offset[face] * mt->cpp); else |