Skip to content

Commit

Permalink
Texture tracing log contains its pixel format
Browse files Browse the repository at this point in the history
  • Loading branch information
Martin Valigursky committed Dec 10, 2024
1 parent c26ecf6 commit 57d47c6
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/platform/graphics/texture.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ import {
isIntegerPixelFormat, FILTER_NEAREST, TEXTURELOCK_NONE, TEXTURELOCK_READ,
TEXPROPERTY_MIN_FILTER, TEXPROPERTY_MAG_FILTER, TEXPROPERTY_ADDRESS_U, TEXPROPERTY_ADDRESS_V,
TEXPROPERTY_ADDRESS_W, TEXPROPERTY_COMPARE_ON_READ, TEXPROPERTY_COMPARE_FUNC, TEXPROPERTY_ANISOTROPY,
TEXPROPERTY_ALL, requiresManualGamma
TEXPROPERTY_ALL, requiresManualGamma,
pixelFormatInfo

} from './constants.js';
import { TextureUtils } from './texture-utils.js';
Expand Down Expand Up @@ -295,7 +296,7 @@ class Texture {
// track the texture
graphicsDevice.textures.push(this);

Debug.trace(TRACEID_TEXTURE_ALLOC, `Alloc: Id ${this.id} ${this.name}: ${this.width}x${this.height} ` +
Debug.trace(TRACEID_TEXTURE_ALLOC, `Alloc: Id ${this.id} ${this.name}: ${this.width}x${this.height} [${pixelFormatInfo.get(this.format)?.name}]` +
`${this.cubemap ? '[Cubemap]' : ''}` +
`${this.volume ? '[Volume]' : ''}` +
`${this.array ? '[Array]' : ''}` +
Expand Down

0 comments on commit 57d47c6

Please sign in to comment.