export class Sampler {
    minFilter;
    magFilter;
    addressU;
    addressV;
    maxAnisotropy;
    constructor(descriptor = {}) {
        this.minFilter = descriptor.minFilter ?? "linear";
        this.magFilter = descriptor.magFilter ?? "linear";
        this.addressU = descriptor.addressU ?? "clamp-to-edge";
        this.addressV = descriptor.addressV ?? "clamp-to-edge";
        const maxAnisotropy = descriptor.maxAnisotropy ?? 1;
        if (!Number.isFinite(maxAnisotropy) || maxAnisotropy < 1) {
            throw new RangeError("Sampler maxAnisotropy must be finite and at least 1");
        }
        this.maxAnisotropy = maxAnisotropy;
    }
}
//# sourceMappingURL=Sampler.js.map