From: Carl Worth Date: Fri, 17 Aug 2012 03:32:32 +0000 (-0700) Subject: trim: Never trim any textures bound within a display list. X-Git-Url: https://git.cworth.org/git?a=commitdiff_plain;ds=sidebyside;h=6338d4c26c8ba7afad886404921bf1988ced3822;p=apitrace trim: Never trim any textures bound within a display list. This is conservative. The more efficient approach would create a resource link from the display list to the texture, but that will wait for when we actually have display-list resources. --- diff --git a/cli/cli_trim.cpp b/cli/cli_trim.cpp index 6820b00..3302dff 100644 --- a/cli/cli_trim.cpp +++ b/cli/cli_trim.cpp @@ -401,6 +401,15 @@ class TraceAnalyzer { * lists. */ if (insideNewEndList != 0) { provide("state", call->no); + + /* Also, any texture bound inside a display list is + * conservatively considered required. */ + if (strcmp(name, "glBindTexture") == 0) { + GLuint texture = call->arg(1).toUInt(); + + linkf("state", "texture-", texture); + } + return; }