X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;f=src%2Fmesa%2Fmain%2Ftexstore.c;h=615ba63362efe3012adc9a9fb58fc553652d4c20;hb=9f93afb9a5586cb90e127ba7d63de3b416d08821;hp=48f60867088a8b9569652b78079b7fcc34b89f8a;hpb=696d8ff5a1f477aa0d7a9b9a2c6d6959e0d101df;p=mesa.git diff --git a/src/mesa/main/texstore.c b/src/mesa/main/texstore.c index 48f60867088..615ba63362e 100644 --- a/src/mesa/main/texstore.c +++ b/src/mesa/main/texstore.c @@ -73,8 +73,8 @@ #include "enums.h" #include "glformats.h" #include "pixeltransfer.h" -#include "../../gallium/auxiliary/util/u_format_rgb9e5.h" -#include "../../gallium/auxiliary/util/u_format_r11g11b10f.h" +#include "util/format_rgb9e5.h" +#include "util/format_r11g11b10f.h" enum { @@ -1267,16 +1267,16 @@ _mesa_compute_compressed_pixelstore(GLuint dims, mesa_format texFormat, const struct gl_pixelstore_attrib *packing, struct compressed_pixelstore *store) { - GLuint bw, bh; + GLuint bw, bh, bd; - _mesa_get_format_block_size(texFormat, &bw, &bh); + _mesa_get_format_block_size_3d(texFormat, &bw, &bh, &bd); store->SkipBytes = 0; store->TotalBytesPerRow = store->CopyBytesPerRow = _mesa_format_row_stride(texFormat, width); store->TotalRowsPerSlice = store->CopyRowsPerSlice = (height + bh - 1) / bh; - store->CopySlices = depth; + store->CopySlices = (depth + bd - 1) / bd; if (packing->CompressedBlockWidth && packing->CompressedBlockSize) {