import { CompareFunction, CompareFunctionOption } from './../enums'; import { BlendStateParams } from './BlendState'; /** * Options to be converted into {@link IDepthState} via {@link DepthState.convert} * * @public */ export interface DepthStateOptions { enable?: boolean; depthFunction?: CompareFunctionOption; depthWriteEnable?: boolean; } /** * An object with all depth state parameters * * @public */ export interface IDepthState { enable: boolean; depthFunction: CompareFunction; depthWriteEnable: boolean; } /** * Represents a sub set of {@link IDepthState} * * @public */ export declare type DepthStateParams = Partial; /** * @public */ export declare class DepthState implements IDepthState { /** * A default state with depth buffer read and write enabled */ static Default: Readonly; /** * A state with depth buffer read and write both disabled */ static None: Readonly; /** * A state with depth buffer enabled for read only */ static DepthRead: Readonly; /** * Converts a state name or options into {@link IDepthState} * * @param state - The state name or state options to convert */ static convert(state: string | DepthStateOptions): BlendStateParams; protected $enable: boolean; protected $depthFunction: number; protected $depthWriteEnable: boolean; protected $hasChanged: boolean; protected $changes: DepthStateParams; /** * Indicates whether the state has changes which are not committed to the GPU */ get isDirty(): boolean; /** * Enables or disables the depth buffer */ get enable(): boolean; set enable(value: boolean); /** * Enables or disables write to depth buffer */ get depthWriteEnable(): boolean; set depthWriteEnable(value: boolean); /** * Gets and sets the depth function */ get depthFunction(): number; set depthFunction(value: number); /** * Gets the readable name of the depth function */ get depthFunctionName(): string; /** * Assigns multiple parameters to the current state */ assign(state: DepthStateParams): this; /** * Uploads all changes to the GPU * * @param state - State changes to be assigned before committing */ commit(state?: DepthStateParams): this; /** * Creates a copy of this state state */ copy(): IDepthState; /** * Creates a copy of this state and writes it into the target object * * @param target - Where the state should be written to */ copy(target: T): T & IDepthState; protected commitChanges(changes: Partial): void; protected clearChanges(): void; } //# sourceMappingURL=DepthState.d.ts.map