summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/trace/tr_screen.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/drivers/trace/tr_screen.c')
-rw-r--r--src/gallium/drivers/trace/tr_screen.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/gallium/drivers/trace/tr_screen.c b/src/gallium/drivers/trace/tr_screen.c
index 7da9bd3866b..f69f7da000d 100644
--- a/src/gallium/drivers/trace/tr_screen.c
+++ b/src/gallium/drivers/trace/tr_screen.c
@@ -35,6 +35,7 @@
#include "tr_screen.h"
#include "pipe/p_inlines.h"
+#include "pipe/p_format.h"
static boolean trace = FALSE;
@@ -424,7 +425,7 @@ trace_screen_transfer_unmap(struct pipe_screen *_screen,
struct pipe_transfer *transfer = tr_trans->transfer;
if(tr_trans->map) {
- size_t size = transfer->nblocksy * transfer->stride;
+ size_t size = pf_get_nblocksy(transfer->texture->format, transfer->width) * transfer->stride;
trace_dump_call_begin("pipe_screen", "transfer_write");