deleteTexture method

void deleteTexture(
  1. Texture texture
)

Implementation

void deleteTexture(Texture texture) {
  final textureProperties = properties.get(texture);
  _gl.deleteTexture(textureProperties["__webglTexture"]);

  final source = texture.source;
  Map webglTextures = _sources.get(source);
  webglTextures.remove(textureProperties["__cacheKey"]);

  info.memory["textures"] = info.memory["textures"]! - 1;
}