import '../../../assert/js/assert.js';
import '../../../globals.js';
/**
 * RenderProgram for a classic linear gradient
 *
 * @author Jonathan Olson <jonathan.olson@colorado.edu>
 */
import Matrix3 from '../../../dot/js/Matrix3.js';
import Vector2 from '../../../dot/js/Vector2.js';
import Vector4 from '../../../dot/js/Vector4.js';
import { ByteEncoder, RenderableFace, RenderEvaluationContext, RenderExecutionStack, RenderExecutor, RenderExtend, RenderGradientStop, RenderInstruction, RenderInstructionLocation, RenderProgram, RenderRadialGradientLogic, SerializedRenderGradientStop } from '../imports.js';
export declare enum RenderLinearGradientAccuracy {
    SplitAccurate = 0,
    SplitPixelCenter = 1,
    UnsplitCentroid = 2,
    UnsplitPixelCenter = 3
}
export default class RenderLinearGradient extends RenderProgram {
    readonly transform: Matrix3;
    readonly start: Vector2;
    readonly end: Vector2;
    readonly stops: RenderGradientStop[];
    readonly extend: RenderExtend;
    readonly accuracy: RenderLinearGradientAccuracy;
    readonly logic: RenderLinearGradientLogic;
    constructor(transform: Matrix3, start: Vector2, end: Vector2, stops: RenderGradientStop[], // should be sorted!!
    extend: RenderExtend, accuracy: RenderLinearGradientAccuracy, logic?: RenderLinearGradientLogic);
    getName(): string;
    withChildren(children: RenderProgram[]): RenderLinearGradient;
    isSplittable(): boolean;
    transformed(transform: Matrix3): RenderProgram;
    protected equalsTyped(other: this): boolean;
    protected getSimplified(children: RenderProgram[]): RenderProgram | null;
    evaluate(context: RenderEvaluationContext): Vector4;
    writeInstructions(instructions: RenderInstruction[]): void;
    split(face: RenderableFace): RenderableFace[];
    serialize(): SerializedRenderLinearGradient;
    static deserialize(obj: SerializedRenderLinearGradient): RenderLinearGradient;
}
export declare class RenderLinearGradientLogic {
    readonly inverseTransform: Matrix3;
    readonly start: Vector2;
    readonly gradDelta: Vector2;
    readonly ratios: number[];
    readonly extend: RenderExtend;
    readonly accuracy: RenderLinearGradientAccuracy;
    private readonly isIdentity;
    constructor(inverseTransform: Matrix3, start: Vector2, gradDelta: Vector2, ratios: number[], extend: RenderExtend, accuracy: RenderLinearGradientAccuracy);
    static from(transform: Matrix3, start: Vector2, end: Vector2, ratios: number[], extend: RenderExtend, accuracy: RenderLinearGradientAccuracy): RenderLinearGradientLogic;
    equals(other: RenderLinearGradientLogic): boolean;
    computeLinearValue(context: RenderEvaluationContext): number;
}
export declare class RenderInstructionComputeGradientRatio extends RenderInstruction {
    readonly logic: RenderLinearGradientLogic | RenderRadialGradientLogic;
    readonly stopLocations: RenderInstructionLocation[];
    readonly blendLocation: RenderInstructionLocation;
    constructor(logic: RenderLinearGradientLogic | RenderRadialGradientLogic, stopLocations: RenderInstructionLocation[], blendLocation: RenderInstructionLocation);
    toString(): string;
    equals(other: RenderInstruction, areLocationsEqual: (a: RenderInstructionLocation, b: RenderInstructionLocation) => boolean): boolean;
    execute(stack: RenderExecutionStack, context: RenderEvaluationContext, executor: RenderExecutor): void;
    static readonly GRADIENT_BEFORE_RATIO_COUNT_BITS = 16;
    writeBinary(encoder: ByteEncoder, getOffset: (location: RenderInstructionLocation) => number): void;
    static fromBinary(encoder: ByteEncoder, offset: number, getLocation: (offset: number) => RenderInstructionLocation): RenderInstructionComputeGradientRatio;
    getBinaryLength(): number;
}
export type SerializedRenderLinearGradient = {
    type: 'RenderLinearGradient';
    transform: number[];
    start: number[];
    end: number[];
    stops: SerializedRenderGradientStop[];
    extend: RenderExtend;
    accuracy: RenderLinearGradientAccuracy;
};
//# sourceMappingURL=RenderLinearGradient.d.ts.map