/*---------------------------------------------------------------------------------------------
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
* See LICENSE.md in the project root for license terms and full copyright notice.
*--------------------------------------------------------------------------------------------*/
/** @packageDocumentation
 * @module WebGL
 */
import { dispose } from "@itwin/core-bentley";
import { Matrix4d } from "@itwin/core-geometry";
export class TextureDrape {
    constructor() {
        this._projectionMatrix = Matrix4d.createIdentity();
    }
    get texture() { return this._texture; }
    get projectionMatrix() { return this._projectionMatrix; }
    get isReady() { return this._texture !== undefined; }
    collectStatistics(stats) {
        if (undefined !== this._texture)
            stats.addPlanarClassifier(this._texture.bytesUsed);
    }
    get isDisposed() { return undefined === this.texture; }
    dispose() {
        this._texture = dispose(this._texture);
    }
    getParams(params) {
        params[0] = 5.0; // Inside, pure texture.
        params[1] = 0.0; // Outside, off.
    }
}
//# sourceMappingURL=TextureDrape.js.map