diff options
author | Brian Paul <[email protected]> | 2011-09-17 14:50:48 -0600 |
---|---|---|
committer | Brian Paul <[email protected]> | 2011-09-17 14:57:40 -0600 |
commit | abdfa0b4f1e5ae0bd3d71ae7099b6bb7c2bfae71 (patch) | |
tree | 1bfcea659414a7aca20c0a8d36e9687ad9d002e4 /src/mesa/drivers/dri/radeon/radeon_mipmap_tree.c | |
parent | fa2c886863492cc3eeee6d2059ae24edc1cb2bff (diff) |
radeon: make radeon_texture_image a subclass of swrast_texture_image
Diffstat (limited to 'src/mesa/drivers/dri/radeon/radeon_mipmap_tree.c')
-rw-r--r-- | src/mesa/drivers/dri/radeon/radeon_mipmap_tree.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/src/mesa/drivers/dri/radeon/radeon_mipmap_tree.c b/src/mesa/drivers/dri/radeon/radeon_mipmap_tree.c index 03d9b264367..f1febd36ef0 100644 --- a/src/mesa/drivers/dri/radeon/radeon_mipmap_tree.c +++ b/src/mesa/drivers/dri/radeon/radeon_mipmap_tree.c @@ -448,9 +448,9 @@ static void migrate_image_to_miptree(radeon_mipmap_tree *mt, assert(image->mt != mt); assert(dstlvl->valid); - assert(dstlvl->width == image->base.Width); - assert(dstlvl->height == image->base.Height); - assert(dstlvl->depth == image->base.Depth); + assert(dstlvl->width == image->base.Base.Width); + assert(dstlvl->height == image->base.Base.Height); + assert(dstlvl->depth == image->base.Base.Depth); radeon_print(RADEON_TEXTURE, RADEON_VERBOSE, "%s miptree %p, image %p, face %d, level %d.\n", @@ -464,7 +464,7 @@ static void migrate_image_to_miptree(radeon_mipmap_tree *mt, * In fact, that memcpy() could be done by the hardware in many * cases, provided that we have a proper memory manager. */ - assert(mt->mesaFormat == image->base.TexFormat); + assert(mt->mesaFormat == image->base.Base.TexFormat); radeon_mipmap_level *srclvl = &image->mt->levels[image->mtlevel]; @@ -480,27 +480,27 @@ static void migrate_image_to_miptree(radeon_mipmap_tree *mt, radeon_bo_unmap(image->mt->bo); radeon_miptree_unreference(&image->mt); - } else if (image->base.Data) { + } else if (image->base.Base.Data) { /* This condition should be removed, it's here to workaround * a segfault when mapping textures during software fallbacks. */ radeon_print(RADEON_FALLBACKS, RADEON_IMPORTANT, "%s Trying to map texture in sowftware fallback.\n", __func__); - const uint32_t srcrowstride = _mesa_format_row_stride(image->base.TexFormat, image->base.Width); - uint32_t rows = image->base.Height * image->base.Depth; + const uint32_t srcrowstride = _mesa_format_row_stride(image->base.Base.TexFormat, image->base.Base.Width); + uint32_t rows = image->base.Base.Height * image->base.Base.Depth; - if (_mesa_is_format_compressed(image->base.TexFormat)) { + if (_mesa_is_format_compressed(image->base.Base.TexFormat)) { uint32_t blockWidth, blockHeight; - _mesa_get_format_block_size(image->base.TexFormat, &blockWidth, &blockHeight); + _mesa_get_format_block_size(image->base.Base.TexFormat, &blockWidth, &blockHeight); rows = (rows + blockHeight - 1) / blockHeight; } - copy_rows(dest, dstlvl->rowstride, image->base.Data, srcrowstride, + copy_rows(dest, dstlvl->rowstride, image->base.Base.Data, srcrowstride, rows, srcrowstride); - _mesa_free_texmemory(image->base.Data); - image->base.Data = 0; + _mesa_free_texmemory(image->base.Base.Data); + image->base.Base.Data = 0; } radeon_bo_unmap(mt->bo); |